[Mapserver-users] 4.0 pdf make error

Joe Smith joe at poconogis.com
Wed Aug 13 13:34:40 PDT 2003


Fixed the problem.  I had downloaded just the PDFlib file from
www.pdflib.com (which you need for the pdflib.h and libpdf.a files), but not
PDF Lite (which you need to compile/make the source).  I *think* you need
both files, since I didn't find pdflib.h with PDF Lite, and MapServer needs
that file to compile.  Does that sound right, or did I miss something?

After I installed PDF Lite, the mapserver4.0 Makefile worked without
erroring.  If I'm not the only person confused by that, and I didn't mess
something up, might wanna make a note on MapServerWiki.

I had added the extra line to the makefile just for something to try (and I
think it was used before 4.0), but it wasn't needed after I installed the
pdf lib correctly.

thanks for the help --Joe


-----Original Message-----
From: mapserver-users-admin at lists.gis.umn.edu
[mailto:mapserver-users-admin at lists.gis.umn.edu]On Behalf Of Daniel
Morissette
Sent: Wednesday, August 13, 2003 2:12 PM
To: Joe Smith
Cc: Mapserver-users at lists.gis.umn.edu
Subject: Re: [Mapserver-users] 4.0 pdf make error


Joe Smith wrote:

> The answer may have been posted, but I didn't catch it.  You can just
email
> me the solution if you want.  I configured like this:
>
>
./configure --with-gd=/home/joe/gd --with-php=/home/joe/php --enable-debug -
> -with-pdf=/home/joe/pdflib/bind/c/include
>
> I added a line to the Makefile:
>
> PDF_INC= -I/home/joe/pdflib/bind/c/include
> PDF_LIB= -L/home/joe/pdflib/bind/c/include/lib -lpdf
> PDF=     -DUSE_PDF
> PDF_OBJ= mappdf.o
>

Why did you have to edit the makefile?  Configure didn't detect your PDF
lib?  This is quite possible since the lib was probably not 'installed'.

You would save lots of trouble if you installed the lib (using 'make
install'), either in the default location (/usr/local) or even under
your home account if you specify --prefix=/home/joe/local for instance.
  Note that you'll also need LD_LIBRARY_PATH if pdflib is not installed
in the default system libs directory.


> Here's my error:
>
> /usr/bin/ld: cannot find -lpdf
> collect2: ld returned 1 exit status
> make: *** [shp2img] Error 1
>

The following line:

 > PDF_LIB= -L/home/joe/pdflib/bind/c/include/lib -lpdf

means:
  look for libpdf.so or libpdf.a in /home/joe/pdflib/bind/c/include/lib.

Make sure you specify the correct path to the lipdf.so/.a

--
------------------------------------------------------------
  Daniel Morissette               morissette at dmsolutions.ca
  DM Solutions Group              http://www.dmsolutions.ca/
------------------------------------------------------------

_______________________________________________
Mapserver-users mailing list
Mapserver-users at lists.gis.umn.edu
http://lists.gis.umn.edu/mailman/listinfo/mapserver-users




More information about the MapServer-users mailing list