Screenshot instructions:
Windows
Mac
Red Hat Linux
Ubuntu
Click URL instructions:
Right-click on ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)
From: <jcard@fe...> - 2003-10-15 16:29:28
|
On Wednesday 15 October 2003 15:37, Herng-Jeng Jou wrote: | 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/libcsiroc |sa.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. I kind-of confirm this with current CVS and x01c.c. Of course we don't expect users to do what Herng-Jeng Jou did, but users migh want to generate a static executable to, say, sent id to a friend? And this raises another shared/static question: if plplot_libtool or pkg_config don't support both kinds of linking, we should disable static if shared is allowed. Or I'm missing something? Joao |