> Sorry for these stupid errors, I should really have read that one > through one more time before posting. Attached is an updated version > with both errors corrected. OK?
That doesn't work for me on Solaris when there is no static glibc (e.g. 64-bit mode on Solaris 9): check_effective_target_static_libgfortran doesn't work because it doesn't compile with -static: /opt/build/eric/gcc-4_0-branch/gcc/xgcc Testing gfortran.dg/static_linking_1.f, -O0 check_effective_target_static_libgfortran: `' `unix' check_effective_target_static_libgfortran compiling testfile static25620.f options1: -static options2: -static options3: -static {compiler=/opt/build/eric/gcc-4_0-branch/gcc/testsuite/../gfortran -B/opt/build/eric/gcc-4_0-branch/gcc/testsuite/../} options4: {ldflags=-L/opt/build/eric/gcc-4_0-branch/sparc64-sun-solaris2.9/./libgfortran/.libs -L/opt/build/eric/gcc-4_0-branch/sparc64-sun-solaris2.9/./libiberty } -static {compiler=/opt/build/eric/gcc-4_0-branch/gcc/testsuite/../gfortran-B/opt/build/eric/gcc-4_0-branch/gcc/testsuite/../} doing compile Invoking the compiler as /opt/build/eric/gcc-4_0-branch/gcc/testsuite/../gfortran -B/opt/build/eric/gcc-4_0-branch/gcc/testsuite/../ static25620.f -L/opt/build/eric/gcc-4_0-branch/sparc64-sun-solaris2.9/./libgfortran/.libs -L/opt/build/eric/gcc-4_0-branch/sparc64-sun-solaris2.9/./libiberty -lm -o static25620.x Executing on host: /opt/build/eric/gcc-4_0-branch/gcc/testsuite/../gfortran -B/opt/build/eric/gcc-4_0-branch/gcc/testsuite/../ static25620.f -L/opt/build/eric/gcc-4_0-branch/sparc64-sun-solaris2.9/./libgfortran/.libs -L/opt/build/eric/gcc-4_0-branch/sparc64-sun-solaris2.9/./libiberty -lm -o static25620.x (timeout = 300) pid is 25755 -25755 waitres is 25755 exp9 0 0 output is Checking pattern "sparc-*-sunos*" with sparc64-sun-solaris2.9 Checking pattern "alpha*-*-*" with sparc64-sun-solaris2.9 Checking pattern "hppa*-*-hpux*" with sparc64-sun-solaris2.9 is-effective-target: static_libgfortran 1 with an instrumented gfortran_target_compile: proc gfortran_target_compile { source dest type options } { global tmpdir; global gluefile wrap_flags global ALWAYS_GFORTRANFLAGS; global GFORTRAN_UNDER_TEST; verbose "options1: $options" 2 if { [target_info needs_status_wrapper] != "" && [info exists gluefile] } { lappend options "libs=${gluefile}" lappend options "ldflags=${wrap_flags}" } verbose "options2: $options" 2 lappend options "compiler=$GFORTRAN_UNDER_TEST"; verbose "options3: $options" 2 set options [concat "$ALWAYS_GFORTRANFLAGS" $options]; set options [dg-additional-files-options $options $source] verbose "options4: $options" 2 return [target_compile $source $dest $type $options] } -- Eric Botcazou