RE: [xml] Compilation problem on gjobread

Date view Thread view Subject view Author view

From: Alfred Reibenschuh (alfred.reibenschu@chello.at)
Date: Fri Jun 30 2000 - 15:37:03 EDT


hi!

if you have the /usr/local/lib in /etc/ld.so.conf
you need to run "ldconfig" to make the changes known
to the system :)

-- Alfred Reibenschuh

+----------------------------------------------------+
| linux geek, perl monger, roleplayer & sf-fanatic |
+----------------------------------------------------+
| Sometimes I hear voices in my head |
| telling me to do strange things, but |
| I always wonder if that's just me thinking |
| about things I really want to do anyway. |
| |
| Why do the voices never say, |
| "Your dosage needs adjustment"? |
+----------------------------------------------------+
| look @ http://penguin.at0.net/~fredo/ |
+----------------------------------------------------+

> -----Original Message-----
> From: xml-request@rufus.w3.org [mailto:xml-request@rufus.w3.org]On
> Behalf Of Marc Billaud
> Sent: Friday, June 30, 2000 6:09 PM
> To: Xml List
> Subject: [xml] Compilation problem on gjobread
>
>
>
> Hello
>
> Thanks Daniel for the help.
> I ve installed libxml-2.1.0 on a distrib Suse62 and all seems to happen
> well. During the make install, I got the message:
>
> >Libraries have been installed in:
> > /usr/local/lib
> >
> >If you ever happen to want to link against installed libraries
> >specify the full pathname of the library, or use `-LLIBDIR'
> >flag during linking and do at least one of the following:
> > - add LIBDIR to the `LD_LIBRARY_PATH' environment variable
> > during execution
> > - add LIBDIR to the `LD_RUN_PATH' environment variable
> > during linking
> > - use the `-Wl,--rpath -Wl,LIBDIR' linker flag
> > - have your system administrator add LIBDIR to `/etc/ld.so.conf'
> >
> >See any operating system documentation about shared libraries for
> >more information, such as the ld(1) and ld.so(8) manual pages.
>
> I didn't take care about it because "/usr/local/lib" was included
> correctly in my file "/etc/ld.so.conf".
>
> So I did the compilation of the examples with Daniel's Makefile and the
> compilation seems also to happen well.
>
> >Makefile used:
> >
> >CC=gcc
> >CFLAGS=`xml-config --cflags`
> >LDFLAGS=`xml-config --libs`
> >
> >all: gjobread
> >
> >clean:
> > @(rm -f gjobread gjobread.o)
> >
> >gjobread.o : gjobread.c
> > $(CC) $(CFLAGS) -c gjobread.c
> >
> >gjobread: gjobread.o
> > $(CC) -o gjobread gjobread.o $(LDFLAGS)
> >
> >test: gjobread
> > ./gjobread gjobs.xml
>
> But during the execution I got the following message:
>
> cyrix150:~/xml/libxml2-2.1.0/example # gjobread gjobs.xml
> gjobread: error in loading shared libraries: libxml.so.2: cannot open
> shared object file: No such file or directory
>
> I have checked if all these libraries were installed and I have found
> them in "/usr/local/lib". I haven't found libxml.so.2 in "usr/lib".
>
> I ve tried to compile with a manual cde but the compilation fell also
> because the system seems to use the libxml.a localised in "/usr/lib/"
> instead of "/usr/local/lib". I don't know how to force the system use
> the "/usr/local/lib".
>
> gcc -o gjobread gjobread.c -I/root/xml/libxml2-2.1.0 -lxml
> ->
> /tmp/ccE5nqHP.o: In function `main':
> /tmp/ccE5nqHP.o(.text+0x8cc): undefined reference to `xmlCheckVersion'
> /usr/lib/libxml.a(tree.o): In function `xmlSaveFile':
> tree.o(.text+0x3d1e): undefined reference to `gzdopen'
> tree.o(.text+0x3d2a): undefined reference to `gzopen'
> tree.o(.text+0x3d69): undefined reference to `gzwrite'
> tree.o(.text+0x3d71): undefined reference to `gzclose'
> /usr/lib/libxml.a(xmlIO.o): In function `xmlFreeParserInputBuffer':
> xmlIO.o(.text+0xb7): undefined reference to `gzclose'
> /usr/lib/libxml.a(xmlIO.o): In function
> `xmlParserInputBufferCreateFilename':
> xmlIO.o(.text+0x1a7): undefined reference to `gzdopen'
> xmlIO.o(.text+0x1b7): undefined reference to `gzopen'
> /usr/lib/libxml.a(xmlIO.o): In function `xmlParserInputBufferGrow':
> xmlIO.o(.text+0x3dd): undefined reference to `gzread'
> collect2: ld returned 1 exit status
>
> I will try to install "libxml-2.1.0" on a distrib Rdhat62 to check if
> the pb is similar.
>
> Pb not easy. Thanks for the help.
> Bye
> ----
> Message from the list xml@xmlsoft.org
> Archived at : http://xmlsoft.org/messages/
> to unsubscribe: echo "unsubscribe xml" | mail majordomo@xmlsoft.org
>

----
Message from the list xml@xmlsoft.org
Archived at : http://xmlsoft.org/messages/
to unsubscribe: echo "unsubscribe xml" | mail  majordomo@xmlsoft.org


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Wed Aug 02 2000 - 12:30:18 EDT