[Expat-bugs] [ expat-Bugs-1196180 ] Error durring Make under Solaris 9

SourceForge.net noreply at sourceforge.net
Thu Jun 30 22:01:10 CEST 2005


Bugs item #1196180, was opened at 2005-05-05 13:26
Message generated for change (Comment added) made by nobody
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=1196180&group_id=10127

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Fred L. Drake, Jr. (fdrake)
Summary: Error durring Make under Solaris 9

Initial Comment:
I am getting the following error during the make. I am 
running SOlaris 9 with gcc ver 3.1

bash-2.05# make
/bin/bash ./libtool --silent --mode=link gcc -g -O2 -Wall -
Wmissing-prototypes -Wstrict-prototypes -fexceptions -
DHAVE_EXPAT_CONFIG_H   -I./lib -I. -no-undefined -
version-info 5:0:5 -rpath /usr/local/lib  -o libexpat.la 
lib/xmlparse.lo lib/xmltok.lo lib/xmlrole.lo
Undefined                       first referenced
 symbol                             in file
__eprintf                           lib/xmlparse.lo
ld: fatal: Symbol referencing errors. No output written 
to .libs/libexpat.so.0.5.0
make: *** [libexpat.la] Error 1

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

Comment By: Nobody/Anonymous (nobody)
Date: 2005-06-30 13:01

Message:
Logged In: NO 

I am getting something similar:

root at f2sys1
(2133)[/home/ken/expat/expat-1.95.8]# make all 
        /bin/sh ./libtool --silent --mode=compile gcc -g -O2
-Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions
-DHAVE_EXPAT_CONF
IG_H   -I./lib -I. -o lib/xmlparse.lo -c lib/xmlparse.c
        /bin/sh ./libtool --silent --mode=compile gcc -g -O2
-Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions
-DHAVE_EXPAT_CONF
IG_H   -I./lib -I. -o lib/xmltok.lo -c lib/xmltok.c
        /bin/sh ./libtool --silent --mode=compile gcc -g -O2
-Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions
-DHAVE_EXPAT_CONF
IG_H   -I./lib -I. -o lib/xmlrole.lo -c lib/xmlrole.c
        /bin/sh ./libtool --silent --mode=link gcc -g -O2
-Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions
-DHAVE_EXPAT_CONFIG_
H   -I./lib -I. -no-undefined -version-info 5:0:5 -rpath
/usr/local/lib  -o libexpat.la lib/xmlparse.lo lib/xmltok.lo
lib/xmlrole.lo
ld: 0711-415 WARNING: Symbol _GLOBAL__F_XML_ParserCreate is
already exported.
ld: 0711-415 WARNING: Symbol _GLOBAL__F_XmlUtf8Encode is
already exported.
ld: 0711-415 WARNING: Symbol _GLOBAL__F_XmlPrologStateInit
is already exported.
        gcc -g -O2 -Wall -Wmissing-prototypes
-Wstrict-prototypes -fexceptions -DHAVE_EXPAT_CONFIG_H  
-I./lib -I. -o xmlwf/xmlwf.o -c xml
wf/xmlwf.c
        gcc -g -O2 -Wall -Wmissing-prototypes
-Wstrict-prototypes -fexceptions -DHAVE_EXPAT_CONFIG_H  
-I./lib -I. -o xmlwf/xmlfile.o -c x
mlwf/xmlfile.c
        gcc -g -O2 -Wall -Wmissing-prototypes
-Wstrict-prototypes -fexceptions -DHAVE_EXPAT_CONFIG_H  
-I./lib -I. -o xmlwf/codepage.o -c 
xmlwf/codepage.c
        gcc -g -O2 -Wall -Wmissing-prototypes
-Wstrict-prototypes -fexceptions -DHAVE_EXPAT_CONFIG_H  
-I./lib -I. -o xmlwf/readfilemap.o 
-c xmlwf/readfilemap.c
        /bin/sh ./libtool --silent --mode=link gcc -g -O2
-Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions
-DHAVE_EXPAT_CONFIG_
H   -I./lib -I.  -o xmlwf/xmlwf xmlwf/xmlwf.o
xmlwf/xmlfile.o xmlwf/codepage.o xmlwf/readfilemap.o libexpat.la
        gcc -g -O2 -Wall -Wmissing-prototypes
-Wstrict-prototypes -fexceptions -DHAVE_EXPAT_CONFIG_H  
-I./lib -I. -o examples/elements.o 
-c examples/elements.c
        /bin/sh ./libtool --silent --mode=link gcc -g -O2
-Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions
-DHAVE_EXPAT_CONFIG_
H   -I./lib -I.  -o examples/elements  libexpat.la
ld: 0711-317 ERROR: Undefined symbol: .main
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain
more information.
collect2: ld returned 8 exit status
make: 1254-004 The error code from the last command is 1.

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

Comment By: Karl Waclawek (kwaclaw)
Date: 2005-06-15 05:39

Message:
Logged In: YES 
user_id=290026

Fred,

what about the posted patch?

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

Comment By: SylikC (sylikc)
Date: 2005-05-24 17:13

Message:
Logged In: YES 
user_id=1060368

Hi,

I've found a quick-fix to this problem compiling on solaris
identified by configure as "sparc-sun-solaris2.8"

The reference to __eprintf from lib/xmlparse.c is somewhat
misleading.  It ends up that xmlparse.c has included the
system header assert.h, and it is there where the source of
the error lies.

I can't seem to find libgcc.a on my system, and I've read a
few things on the web that talk about needing that static
library in order to link to __eprintf().

Anyhow, the logical temporary fix (just so you could compile
and be on your way) was just to comment out the 2 references
to assert, both the include and the call, on lines 7 and
1739 in expat-1.95.8.  I'm assuming this should be harmless
in that assert() calls are just debug calls.

Here's the diff
-----------------------
7c7
< #include <assert.h>
---
> //#include <assert.h>
1739c1739
<   assert(status != NULL);
---
>   //assert(status != NULL);
-----------------------


/sylikc


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

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=1196180&group_id=10127


More information about the Expat-bugs mailing list