[M3devel] Couple of CM3 build comments (Solaris/SPARC).

Stefan Sperling stsp at elego.de
Thu Aug 16 19:46:55 CEST 2007


On Mon, Aug 13, 2007 at 08:55:01PM -0700, Alex Bochannek wrote:
> Is it possible to configure it with --disable-nls? That's what we tend
> to do for our GCC builds as well. I just looked at the EZM3 install we
> have and it doesn't seem like it requires libiconv.

I'd favour listing libiconv as an explicit dependency of cm3.

I've looked into this, and --disable-nls is not sufficient to remove
gcc's dependency on libiconv. It unconditionally depends on libiconv
if it can find the library on the system, regardless of flags passed
to the configure script.

I've tried hacking iconv detection out of the build system.
There's a diff below against cm3-5.4 that removes cm3cg's
dependency on libiconv. But it is very ugly.

m3gdb also unconditionally depends on libiconv.
I have not looked into that.

I cannot deinstall libiconv on our Solaris box to prevent configure
from picking it up because I don't have root, and I don't really think
it's a good idea to begin with because removing the library would
probably break a lot of dependencies.

Alex, could you provide more details on what gcc backend you are using?
Does the ezm3 equivalent of the cm3cg executable depend on libiconv?


% ldd /usr/local/cm3/bin/cm3cg
        libiconv.so.2 =>         /usr/local/lib/libiconv.so.2
        libc.so.1 =>     /lib/libc.so.1
        libdl.so.1 =>    /lib/libdl.so.1
        /usr/platform/SUNW,Ultra-30/lib/libc_psr.so.1

With the patch below I get:

% ldd /usr/stsp/cm3/bin/cm3cg
        libc.so.1 =>     /lib/libc.so.1
        libdl.so.1 =>    /lib/libdl.so.1
        /usr/platform/SUNW,Ultra-30/lib/libc_psr.so.1


Index: src/m3makefile
===================================================================
RCS file: /usr/cvs/cm3/m3-sys/m3cc/src/m3makefile,v
retrieving revision 1.16.2.1
diff -u -r1.16.2.1 m3makefile
--- src/m3makefile	23 Aug 2006 14:24:27 -0000	1.16.2.1
+++ src/m3makefile	16 Aug 2007 17:27:18 -0000
@@ -126,7 +126,8 @@
   if stale(donep, donep)
     if equal (M3CC_HOST, M3CC_TARGET)
       if equal (M3CC_TARGET, "SOLgnu")
-        exec ("cd", build_dir, "; .." & SL & "gcc" & SL & "configure", 
+        exec ("cd", build_dir, "; env am_cv_lib_iconv=no .."
+	      & SL & "gcc" & SL & "configure", 
               M3CC_CONFIG,
               "--srcdir=.." & SL & "gcc",
               "--enable-languages=m3cg",
Index: gcc/gcc/Makefile.in
===================================================================
RCS file: /usr/cvs/cm3/m3-sys/m3cc/gcc/gcc/Makefile.in,v
retrieving revision 1.6
diff -u -r1.6 Makefile.in
--- gcc/gcc/Makefile.in	10 Aug 2006 00:29:50 -0000	1.6
+++ gcc/gcc/Makefile.in	16 Aug 2007 17:27:18 -0000
@@ -471,8 +471,8 @@
 LIBINTL_DEP = @LIBINTL_DEP@
 
 # Character encoding conversion library.
-LIBICONV = @LIBICONV@
-LIBICONV_DEP = @LIBICONV_DEP@
+#LIBICONV = @LIBICONV@
+#LIBICONV_DEP = @LIBICONV_DEP@
 
 # The GC method to be used on this system.
 GGC=@GGC at .o
@@ -718,7 +718,7 @@
 BUILD_LIBIBERTY = @FORBUILD@/libiberty/libiberty.a
 
 # Dependencies on the intl and portability libraries.
-LIBDEPS= $(LIBIBERTY) $(LIBINTL_DEP) $(LIBICONV_DEP)
+LIBDEPS= $(LIBIBERTY) $(LIBINTL_DEP) #$(LIBICONV_DEP)
 
 # Likewise, for use in the tools that must run on this machine
 # even if we are cross-building GCC.
@@ -726,7 +726,7 @@
 
 # How to link with both our special library facilities
 # and the system's installed libraries.
-LIBS = @LIBS@ $(LIBIBERTY) $(LIBINTL) $(LIBICONV)
+LIBS = @LIBS@ $(LIBIBERTY) $(LIBINTL) #$(LIBICONV)
 
 # Any system libraries needed just for GNAT.
 SYSLIBS = @GNAT_LIBEXC@

-- 
Stefan Sperling <stsp at elego.de>                 Software Developer
elego Software Solutions GmbH                            HRB 77719
Gustav-Meyer-Allee 25, Gebaeude 12        Tel:  +49 30 23 45 86 96 
13355 Berlin                              Fax:  +49 30 23 45 86 95
http://www.elego.de                 Geschaeftsfuehrer: Olaf Wagner
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20070816/5c4d1261/attachment-0004.sig>


More information about the M3devel mailing list