This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC] patch LD_LIBRARY_PATH_64 for sparc solaris testing


Andreas Tobler wrote:

Ok, I have something like this in mind.

ChangeLog missing at the moment.

And here the ChangeLogs:


gcc/testsuite/ChangeLog:

2004-01-10 Andreas Tobler <a.tobler@schweiz.ch>

	* g++.dg/compat/compat.exp: Add LD_LIBRARY_PATH_32/64 for solaris.
	* lib/g77.exp: Likewise.
	* lib/objc.exp: Likewise.
	* lib/g++.exp: Likewise.

libjava/testsuite/ChangeLog:

2004-01-10 Andreas Tobler <a.tobler@schweiz.ch>

	* lib/libjava.exp: Add LD_LIBRARY_PATH_32/64 to get proper
	path setting for solaris 32/64 bit testing.
	Reorganize LD_LIBRARY_PATH setting.

libstdc++-v3/ChangeLog:

2004-01-10 Andreas Tobler <a.tobler@schweiz.ch>

	* testsuite/lib/libstdc++.exp: Set LD_LIBRARY_PATH_32 for
	solaris.

libffi/ChangeLog:

2004-01-10 Andreas Tobler <a.tobler@schweiz.ch>

	* testsuite/lib/libffi-dg.exp: Set LD_LIBRARY_PATH_32 for
	solaris.



Still testing. Will take at least another 20 hours to check against a full build on solaris with test :)

Ok, here are the results for sol9:


http://gcc.gnu.org/ml/gcc-testresults/2004-01/msg00461.html

Andreas


------------------------------------------------------------------------


Index: gcc/testsuite/lib/g++.exp
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/lib/g++.exp,v
retrieving revision 1.35
diff -u -r1.35 g++.exp
--- gcc/testsuite/lib/g++.exp 18 Dec 2003 19:39:57 -0000 1.35
+++ gcc/testsuite/lib/g++.exp 10 Jan 2004 16:56:02 -0000
@@ -170,14 +170,18 @@
# called LD_LIBRARYN32_PATH (for the N32 ABI) and LD_LIBRARY64_PATH
# (for the 64-bit ABI). The right way to do this would be to modify
# unix.exp -- but that's not an option since it's part of DejaGNU
- # proper, so we do it here. We really only need to do - # this on IRIX, but it shouldn't hurt to do it anywhere else.
+ # proper, so we do it here.
+ # The same applies to darwin (DYLD_LIBRARY_PATH), solaris 32 bit
+ # (LD_LIBRARY_PATH_32), solaris 64 bit (LD_LIBRARY_PATH_64), and HP-UX
+ # (SHLIB_PATH).
# Doing this does cause trouble when testing cross-compilers.
if {![is_remote target]} {
setenv LD_LIBRARY_PATH $ld_library_path
setenv SHLIB_PATH $ld_library_path
setenv LD_LIBRARYN32_PATH $ld_library_path
setenv LD_LIBRARY64_PATH $ld_library_path
+ setenv LD_LIBRARY_PATH_32 $ld_library_path
+ setenv LD_LIBRARY_PATH_64 $ld_library_path
setenv DYLD_LIBRARY_PATH $ld_library_path
}
Index: gcc/testsuite/lib/g77.exp
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/lib/g77.exp,v
retrieving revision 1.17
diff -u -r1.17 g77.exp
--- gcc/testsuite/lib/g77.exp 10 Dec 2003 20:36:02 -0000 1.17
+++ gcc/testsuite/lib/g77.exp 10 Jan 2004 16:56:02 -0000
@@ -114,12 +114,16 @@
# called LD_LIBRARYN32_PATH (for the N32 ABI) and LD_LIBRARY64_PATH
# (for the 64-bit ABI). The right way to do this would be to modify
# unix.exp -- but that's not an option since it's part of DejaGNU
- # proper, so we do it here. We really only need to do - # this on IRIX, but it shouldn't hurt to do it anywhere else.
+ # proper, so we do it here.
+ # The same applies to darwin (DYLD_LIBRARY_PATH), solaris 32 bit
+ # (LD_LIBRARY_PATH_32), solaris 64 bit (LD_LIBRARY_PATH_64), and HP-UX
+ # (SHLIB_PATH).
setenv LD_LIBRARY_PATH $ld_library_path
setenv SHLIB_PATH $ld_library_path
setenv LD_LIBRARYN32_PATH $ld_library_path
setenv LD_LIBRARY64_PATH $ld_library_path
+ setenv LD_LIBRARY_PATH_32 $ld_library_path
+ setenv LD_LIBRARY_PATH_64 $ld_library_path
setenv DYLD_LIBRARY_PATH $ld_library_path
return "$flags"
Index: gcc/testsuite/lib/objc.exp
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/lib/objc.exp,v
retrieving revision 1.20
diff -u -r1.20 objc.exp
--- gcc/testsuite/lib/objc.exp 10 Dec 2003 20:36:02 -0000 1.20
+++ gcc/testsuite/lib/objc.exp 10 Jan 2004 16:56:02 -0000
@@ -188,13 +188,17 @@
# called LD_LIBRARYN32_PATH (for the N32 ABI) and LD_LIBRARY64_PATH
# (for the 64-bit ABI). The right way to do this would be to modify
# unix.exp -- but that's not an option since it's part of DejaGNU
- # proper, so we do it here. We really only need to do - # this on IRIX, but it shouldn't hurt to do it anywhere else.
+ # proper, so we do it here.
+ # The same applies to darwin (DYLD_LIBRARY_PATH), solaris 32 bit
+ # (LD_LIBRARY_PATH_32), solaris 64 bit (LD_LIBRARY_PATH_64), and HP-UX
+ # (SHLIB_PATH).
setenv LD_LIBRARY_PATH $ld_library_path
setenv SHLIB_PATH $ld_library_path
setenv LD_LIBRARYN32_PATH $ld_library_path
setenv LD_LIBRARY64_PATH $ld_library_path
- setenv DYLD_LIBRARY_PATH $ld_library_path + setenv LD_LIBRARY_PATH_32 $ld_library_path
+ setenv LD_LIBRARY_PATH_64 $ld_library_path
+ setenv DYLD_LIBRARY_PATH $ld_library_path
return [target_compile $source $dest $type $options]
}
Index: gcc/testsuite/g++.dg/compat/compat.exp
===================================================================
RCS file: /cvs/gcc/gcc/gcc/testsuite/g++.dg/compat/compat.exp,v
retrieving revision 1.4
diff -u -r1.4 compat.exp
--- gcc/testsuite/g++.dg/compat/compat.exp 18 Dec 2003 19:39:57 -0000 1.4
+++ gcc/testsuite/g++.dg/compat/compat.exp 10 Jan 2004 16:56:02 -0000
@@ -49,6 +49,9 @@
setenv SHLIB_PATH $ld_library_path
setenv LD_LIBRARYN32_PATH $ld_library_path
setenv LD_LIBRARY64_PATH $ld_library_path
+ setenv LD_LIBRARY_PATH_32 $ld_library_path
+ setenv LD_LIBRARY_PATH_64 $ld_library_path
+ setenv DYLD_LIBRARY_PATH $ld_library_path
}
}
Index: libstdc++-v3/testsuite/lib/libstdc++.exp
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/testsuite/lib/libstdc++.exp,v
retrieving revision 1.14
diff -u -r1.14 libstdc++.exp
--- libstdc++-v3/testsuite/lib/libstdc++.exp 11 Dec 2003 01:08:14 -0000 1.14
+++ libstdc++-v3/testsuite/lib/libstdc++.exp 10 Jan 2004 16:56:03 -0000
@@ -65,16 +65,20 @@
# Find the existing LD_LIBRARY_PATH.
if [info exists env(LD_LIBRARY_PATH)] {
set original_ld_library_path $env(LD_LIBRARY_PATH)
+ # For HP-UX
+ } elseif [info exists env(SHLIB_PATH)] {
+ set original_ld_library_path $env(SHLIB_PATH)
+ # For Darwin:
+ } elseif [info exists env(DYLD_LIBRARY_PATH)] {
+ set original_ld_library_path $env(DYLD_LIBRARY_PATH)
+ # For Solaris 32 bit:
+ } elseif [info exists env(LD_LIBRARY_PATH_32)] {
+ set original_ld_library_path $env(LD_LIBRARY_PATH_32)
+ # For Solaris 64 bit:
+ } elseif [info exists env(LD_LIBRARY_PATH_64)] {
+ set original_ld_library_path $env(LD_LIBRARY_PATH_64)
} else {
- if [info exists env(SHLIB_PATH)] {
- set original_ld_library_path $env(SHLIB_PATH)
- } else {
- if [info exists env(DYLD_LIBRARY_PATH)] {
- set original_ld_library_path $env(DYLD_LIBRARY_PATH)
- } else {
- set original_ld_library_path ""
- }
- }
+ set original_ld_library_path ""
}
# Locate libgcc.a so we don't need to account for different values of
@@ -107,13 +111,16 @@
# called LD_LIBRARYN32_PATH (for the N32 ABI) and LD_LIBRARY64_PATH
# (for the 64-bit ABI). The right way to do this would be to modify
# unix.exp -- but that's not an option since it's part of DejaGNU
- # proper, so we do it here. We really only need to do - # this on IRIX, but it shouldn't hurt to do it anywhere else.
+ # proper, so we do it here.
+ # The same applies to darwin (DYLD_LIBRARY_PATH), solaris 32 bit
+ # (LD_LIBRARY_PATH_32), solaris 64 bit (LD_LIBRARY_PATH_64), and HP-UX
+ # (SHLIB_PATH).
setenv LD_LIBRARY_PATH "$ld_library_path:$original_ld_library_path"
setenv SHLIB_PATH "$ld_library_path:$original_ld_library_path"
setenv LD_LIBRARYN32_PATH "$ld_library_path:$original_ld_library_path"
setenv LD_LIBRARY64_PATH "$ld_library_path:$original_ld_library_path"
setenv LD_RUN_PATH "$ld_library_path:$original_ld_library_path"
+ setenv LD_LIBRARY_PATH_32 "$ld_library_path:$original_ld_library_path"
setenv LD_LIBRARY_PATH_64 "$ld_library_path:$original_ld_library_path"
setenv DYLD_LIBRARY_PATH "$ld_library_path:$original_ld_library_path"
verbose -log "LD_LIBRARY_PATH = $env(LD_LIBRARY_PATH)"
Index: libjava/testsuite/lib/libjava.exp
===================================================================
RCS file: /cvs/gcc/gcc/libjava/testsuite/lib/libjava.exp,v
retrieving revision 1.56
diff -u -r1.56 libjava.exp
--- libjava/testsuite/lib/libjava.exp 9 Jan 2004 17:27:37 -0000 1.56
+++ libjava/testsuite/lib/libjava.exp 10 Jan 2004 16:56:03 -0000
@@ -175,16 +175,20 @@
if [info exists env(LD_LIBRARY_PATH)] {
set original_ld_library_path $env(LD_LIBRARY_PATH)
+ # For HP-UX.
+ } elseif [info exists env(SHLIB_PATH)] {
+ set original_ld_library_path $env(SHLIB_PATH)
+ # For Darwin.
+ } elseif [info exists env(DYLD_LIBRARY_PATH)] {
+ set original_ld_library_path $env(DYLD_LIBRARY_PATH)
+ # For Solaris 32 bit.
+ } elseif [info exists env(LD_LIBRARY_PATH_32)] {
+ set original_ld_library_path $env(LD_LIBRARY_PATH_32)
+ # For Solaris 64 bit.
+ } elseif [info exists env(LD_LIBRARY_PATH_64)] {
+ set original_ld_library_path $env(LD_LIBRARY_PATH_64)
} else {
- if [info exists env(SHLIB_PATH)] {
- set original_ld_library_path $env(SHLIB_PATH)
- } else {
- if [info exists env(DYLD_LIBRARY_PATH)] {
- set original_ld_library_path $env(DYLD_LIBRARY_PATH)
- } else {
- set original_ld_library_path ""
- }
- }
+ set original_ld_library_path ""
}
set wrapper_file "";
@@ -363,8 +367,6 @@
# Set variables the dynamic linker looks at.
global original_ld_library_path
setenv LD_LIBRARY_PATH "$ld_library_path:$original_ld_library_path"
- setenv SHLIB_PATH "$ld_library_path:$original_ld_library_path"
- setenv DYLD_LIBRARY_PATH "$ld_library_path:$original_ld_library_path"
verbose "LD_LIBRARY_PATH = $env(LD_LIBRARY_PATH)"
@@ -460,8 +462,6 @@
append newval :$lib_path
setenv LD_LIBRARY_PATH $newval
- setenv SHLIB_PATH $newval
- setenv DYLD_LIBRARY_PATH $newval
verbose "LD_LIBRARY_PATH=$env(LD_LIBRARY_PATH)"
@@ -471,8 +471,6 @@
# Restore setting
setenv LD_LIBRARY_PATH $lib_path
- setenv SHLIB_PATH $lib_path
- setenv DYLD_LIBRAY_PATH $lib_path
if {$status != "pass"} {
verbose "got $output"
@@ -909,12 +907,17 @@
# called LD_LIBRARYN32_PATH (for the N32 ABI) and LD_LIBRARY64_PATH
# (for the 64-bit ABI). The right way to do this would be to modify
# unix.exp -- but that's not an option since it's part of DejaGNU
-# proper, so we do it here, by trickery. We really only need to do -# this on IRIX, but it shouldn't hurt to do it anywhere else.
-
+# proper, so we do it here, by trickery.
+# The same applies to darwin (DYLD_LIBRARY_PATH), solaris 32 bit
+# (LD_LIBRARY_PATH_32), solaris 64 bit (LD_LIBRARY_PATH_64), and HP-UX
+# (SHLIB_PATH).
proc ${tool}_set_ld_library_path { name element op } {
setenv LD_LIBRARYN32_PATH [getenv LD_LIBRARY_PATH]
setenv LD_LIBRARY64_PATH [getenv LD_LIBRARY_PATH]
+ setenv SHLIB_PATH [getenv LD_LIBRARY_PATH]
+ setenv DYLD_LIBRARY_PATH [getenv LD_LIBRARY_PATH]
+ setenv LD_LIBRARY_PATH_32 [getenv LD_LIBRARY_PATH]
+ setenv LD_LIBRARY_PATH_64 [getenv LD_LIBRARY_PATH]
}
trace variable env(LD_LIBRARY_PATH) w ${tool}_set_ld_library_path
Index: libffi/testsuite/lib/libffi-dg.exp
===================================================================
RCS file: /cvs/gcc/gcc/libffi/testsuite/lib/libffi-dg.exp,v
retrieving revision 1.6
diff -u -r1.6 libffi-dg.exp
--- libffi/testsuite/lib/libffi-dg.exp 21 Nov 2003 11:24:09 -0000 1.6
+++ libffi/testsuite/lib/libffi-dg.exp 10 Jan 2004 16:56:03 -0000
@@ -129,12 +129,15 @@
# called LD_LIBRARYN32_PATH (for the N32 ABI) and LD_LIBRARY64_PATH
# (for the 64-bit ABI). The right way to do this would be to modify
# unix.exp -- but that's not an option since it's part of DejaGNU
- # proper, so we do it here. We really only need to do
- # this on IRIX, but it shouldn't hurt to do it anywhere else.
+ # proper, so we do it here.
+ # The same applies to darwin (DYLD_LIBRARY_PATH), solaris 32 bit
+ # (LD_LIBRARY_PATH_32), solaris 64 bit (LD_LIBRARY_PATH_64), and HP-UX
+ # (SHLIB_PATH).
setenv LD_LIBRARY_PATH $ld_library_path
setenv SHLIB_PATH $ld_library_path
setenv LD_LIBRARYN32_PATH $ld_library_path
setenv LD_LIBRARY64_PATH $ld_library_path
+ setenv LD_LIBRARY_PATH_32 $ld_library_path
setenv LD_LIBRARY_PATH_64 $ld_library_path
setenv DYLD_LIBRARY_PATH $ld_library_path
}



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]