Problem installing ppgplot

Enno Middelberg emiddelb at mpifr-bonn.mpg.de
Wed Aug 20 08:07:06 EDT 2003


Hi,

I want to install pgplot but I can't really get it to work. Here is
what I did; pgplot libraries are installed in ~/pgplot

-downloaded ppgplot-1.1.tar.gz from
http://www.astro.rug.nl/~breddels/python/ppgplot/

-PGPLOT_DIR was set correctly, so I tried python setup.py install, but
that stopped saying

-------------------------------------------------------------
gcc -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC
-I/homes/emiddelb/local2/include/python2.2/Numeric
-I/homes/emiddelb/local2/include/python2.2 -c ppgplot.c -o
build/temp.linux-i686-2.2/ppgplot.o

ppgplot.c:21: cpgplot.h: No such file or directory
-------------------------------------------------------------

-I found a website describing that error
(http://www.astro.rub.de/laboca/download/help_install_all_for_boa.html). I
copied cpgplot.h to my local include dir as I don't have root
permissions and re-ran the install script. Apparently, the gcc command
now worked, but another one now crashed:

------------------------------------------------------------- 
gcc -shared build/temp.linux-i686-2.2/ppgplot.o -L/usr/X11R6/lib/
-L/homes/emiddelb/pgplot -L/usr/X11R6/lib/ -lcpgplot -lpgplot -lX11
-lm -lg2c -o build/lib.linux-i686-2.2/ppgplot.so

/usr/i486-linux/bin/ld: cannot open -lcpgplot: No such file or
directory 
collect2: ld returned 1 exit status
-------------------------------------------------------------

I had the suspicion that the "-lcpgplot" was not correct, as the
pgplot distribution does not contain any other files named cpgplot.*
except for cpgplot.h and a cpgplot.c demonstration file. 

I therefore tried to run the gcc command without "-lcpgplot" and got a
file called "ppgplot.so" in the "build/lib.linux-i686-2.2/"
subdirectory. I copied that file to
~/lib/python2.2/site-packages/ppgplot/ppgplot.so, i.e., to a directory
similar to all the other local packages, but now when I try to use it,
I get an error saying "ImportError: No module named ppgplot".

I still suspect that the installation is incomplete because all the
other packages have at least some python files.

Can someone give me a hint on how to fix this? I'm not a great
programmer and I do not know much of libraries and those things, I
just want to _use_ ppgplot :-/


Cheers,

Enno




More information about the Python-list mailing list