From: John B. <jrb...@co...> - 2015-01-26 00:58:03
|
Hi Arjen and Alan, After achieving apparent success several days ago compiling and linking my application code under plplot-5.10.0, for some reason things ceased to work. The make process could no longer find the required libraries. So I went to examples/f95 and imitated (I think) the makefile I found there (Makefile.examples). Here is the resulting makefile I am attempting to use: F95 = /usr/bin/gfortran.exe FFLAGS = -fdefault-real-8 -O3 PKG_CONFIG_ENV = PKG_CONFIG_PATH="/home/johnrb/plplot-5.10.0/build_dir/lib/pkgconfig" RPATHCMD = -Wl,-rpath -Wl,/home/johnrb/plplot-5.10.0/build_dir/lib sphplt : sphplt.o graphx.o $(F95) $(FFLAGS) $(RPATHCMD) -o sphplt \ `$(PKG_CONFIG_ENV) pkg-config --cflags --libs plplotd-f95` \ sphplt.o graphx.o -lplplotd -lplplotf95d -lplplotf95cd Here is what I get when I do the make: $ make -f makesph /usr/bin/gfortran.exe -fdefault-real-8 -O3 -Wl,-rpath -Wl,/home/johnrb/plplot-5.10.0/build_dir/lib -o sphplt \ `PKG_CONFIG_PATH="/home/johnrb/plplot-5.10.0/build_dir/lib/pkgconfig" pkg-config --cflags --libs plplotd-f95` \ sphplt.o graphx.o -lplplotd -lplplotf95d -lplplotf95cd /usr/lib/gcc/x86_64-pc-cygwin/4.8.3/../../../../x86_64-pc-cygwin/bin/ld: cannot find -lplplotf95d-11.0.0 /usr/lib/gcc/x86_64-pc-cygwin/4.8.3/../../../../x86_64-pc-cygwin/bin/ld: cannot find -lplplotf95cd-11.0.0 collect2: error: ld returned 1 exit status makesph:8: recipe for target 'sphplt' failed make: *** [sphplt] Error 1 Any ideas as to what I am doing wrong? Thanks for any help you can provide. John P.S. Here is the pkgconfig/plplotd-f95.pc file: libdir=/home/johnrb/plplot-5.10.0/build_dir/bin includedir=/home/johnrb/plplot-5.10.0/build_dir/include/plplot drvdir=/home/johnrb/plplot-5.10.0/build_dir/lib/plplot5.10.0/driversd Name: PLplot F95 Description: Scientific plotting library (F95 bindings, double precision) Requires: plplotd Version: 5.10.0 Libs: -L${libdir} -lplplotf95d-11.0.0 -lplplotf95cd-11.0.0 Cflags: -I${includedir} -I/home/johnrb/plplot-5.10.0/build_dir/lib/fortran/modules/plplot Question: Why is libdir set to /bin and not /lib? /bin does not have libplplotf95d-11.0.0 while /lib does. |