|
From: Herng-Jeng J. <hj...@qu...> - 2003-10-15 14:38:11
|
Thanks Andrew for your quick response.
Since I don't quite understand the build process, so it is very likely that
I screwed up.
This is how x01 was built with the supplied Makefile in examples/c++ directory:
$ make x01
/bin/sh ../../libtool --mode=link g++ -g -O2 -o x01 x01.o
../../bindings/c++/libplplotcxxd.la
$ g++ -g -O2 -o .libs/x01 x01.o ../../bindings/c++/.libs/libplplotcxxd.so
/afs/hjjou/archives/plplot-5.2.1.cvs.20031004/src/.libs/libplplotd.so
/usr/lib/libfreetype.so
/afs/hjjou/archives/plplot-5.2.1.cvs.20031004/lib/csa/.libs/libcsirocsa.so
-ldl -Wl,--rpath -Wl,/usr/local/plplot/lib
creating x01
and that makes a executable .libs/x01 and x01 script and it works fine.
After I install PLplot into "/usr/local/plplot" directory,
then I was trying to compile a standalone x01 without dynamic linkage at
all to PLplot, and
this is what I did:
$ g++ -I/usr/local/plplot/include/plplot -c x01.cc
$ g++ -g -O2 -o x01 x01.o /usr/local/plplot/lib/libplplotcxxd.a
/usr/local/plplot/lib/libplplotd.a /usr/lib/libfreetype.so
/usr/local/plplot/lib/libcsirocsa.a -ldl
$ ldd x01
libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0x40023000)
libdl.so.2 => /lib/libdl.so.2 (0x40063000)
libstdc++-libc6.2-2.so.3 => /usr/lib/libstdc++-libc6.2-2.so.3
(0x40066000)
libm.so.6 => /lib/i686/libm.so.6 (0x400a9000)
libc.so.6 => /lib/i686/libc.so.6 (0x42000000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
looks like this x01 executable has correct linkage. But when I run it, I
got a empty
page with it. Same problem as x02 if I try compiling this way.
All of these (lib,example source, etc) were done using CVS 20031004 snapshot.
The library was configured with --prefix==/usr/local/plplot --with-double flag.
Thanks for your help.
Jou
At 03:02 PM 10/15/2003 +0100, Andrew Ross wrote:
>Hi Jou,
>
>How exactly are you compiling the examples statically? Do you mean
>that you are compiling the whole library statically?
>
>There have been some API changes in the C++ bindings so you are now
>required to call plstream::init() explicitly. Is it possible that you
>are linking against an old version of the library which might explain
>your problem?
>
>Do you get the same problems with all the C++ examples?
>
>Cheers
>
>Andrew
>
>On Wed, Oct 15, 2003 at 08:38:54AM -0500, Herng-Jeng Jou wrote:
> > Hi,
> > I compiled PLplot CVS 20031004 ok on RedHat Linux 7.3 with gcc/g++ 2.96.
> > The x01.cc example works fine as compiled with dynamic linkage. When I
> tried
> > to link it statically, the executable runs with an empty plotting window
> > (black
> > background) and with no plot in it.
> > Jou
> >
> > =======================================
> > Herng-Jeng Jou
> > QuesTek Innovations, LLC
> > 1820 Ridge Avenue
> > Evanston, IL 60201
> > (Tel) 847.425.8221
> > (Fax) 847.328.5855
> > hj...@qu...
> >
> >
>
> > -------------------------------------------------------
> > This SF.net email is sponsored by: SF.net Giveback Program.
> > SourceForge.net hosts over 70,000 Open Source Projects.
> > See the people who have HELPED US provide better services:
> > Click here: http://sourceforge.net/supporters.php
> > _______________________________________________
> > Plplot-general mailing list
> > Plp...@li...
> > https://lists.sourceforge.net/lists/listinfo/plplot-general
>
>
>-------------------------------------------------------
>This SF.net email is sponsored by: SF.net Giveback Program.
>SourceForge.net hosts over 70,000 Open Source Projects.
>See the people who have HELPED US provide better services:
>Click here: http://sourceforge.net/supporters.php
>_______________________________________________
>Plplot-general mailing list
>Plp...@li...
>https://lists.sourceforge.net/lists/listinfo/plplot-general
=======================================
Herng-Jeng Jou
QuesTek Innovations, LLC
1820 Ridge Avenue
Evanston, IL 60201
(Tel) 847.425.8221
(Fax) 847.328.5855
hj...@qu...
|