Hi,

With the C++ tests, I'm seeing this link error on Solaris, with Sun C and Sun 
C++:

  CC -O    -L/home/haible/prefix-x86/lib -Wl,-z,ignore  -o test-langinfo-c++ 
test-langinfo-c++.o ../gllib/libgnu.a -lm -lm -lm -lm -lm -lm -lm -lm -lm -lm 
-lm 
  CC: Warning: Option -Wl,-z,ignore passed to ld, if ld is invoked, ignored 
otherwise
  ld: fatal: option -z has illegal argument `,ignore'
  ld: fatal: Flags processing errors
  *** Error code 1

The reason is that the flag -Wl,-z,ignore is accepted by the C compiler (cc), 
but
leads to an error with the C++ compiler (CC).

Can someone please look at this? I'm applying this crude workaround below. But
this will not fix the error the next time someone tries to build coreutils with
Solaris tools.


2010-03-07  Bruno Haible  <br...@clisp.org>

        * gnulib-tool (func_create_testdir): Don't use 'lib-ignore' module
        among default module list.

--- gnulib-tool.orig    Sun Mar  7 22:11:17 2010
+++ gnulib-tool Sun Mar  7 22:11:14 2010
@@ -4410,8 +4410,9 @@
     # All modules together.
     # Except config-h, which breaks all modules which use HAVE_CONFIG_H.
     # Except ftruncate, mountlist, which abort the configuration on mingw. 
FIXME.
+    # Except lib-ignore, which leads to link errors when Sun C++ is used. 
FIXME.
     modules=`func_all_modules`
-    modules=`for m in $modules; do case $m in config-h | ftruncate | 
mountlist) ;; *) echo $m;; esac; done`
+    modules=`for m in $modules; do case $m in config-h | ftruncate | mountlist 
| lib-ignore) ;; *) echo $m;; esac; done`
   fi
   modules=`for m in $modules; do echo $m; done | LC_ALL=C sort -u`
 


Reply via email to