pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: compiling



Russell McManus wrote:
> Compiling pkgsrc-2008Q3:print/ghostscript on linux x86_64 fails like
> so:
> 
> /bin/sh <./obj/../soobj/ldt.tr
> /usr/bin/ld: ./obj/../soobj/gp_unix.o: relocation R_X86_64_32 against `a 
> local symbol' can not be used when making a share
> d object; recompile with -fPIC
> ../obj/../soobj/gp_unix.o: could not read symbols: Bad value
> 
> 
> Googling for the issue suggests that added -fPIC to CFLAGS will get
> the package to compile.  How can I hack my local pkgsrc tree to try
> out this idea?
> 
> -russ
> 

Hi,

CFLAGS+= -fPIC to the Makefile in the package should do the job.  If
it's found to fix it then I'd image the proper fix would be to wrap it
in a .if ${OPSYS} and/or .if ${MACHINE_ARC} depending on where the fix
actually is needed.  Looking at it now there's already a line that adds
-fPIC for NetBSD so I'd just suggest changing that to include Linux.

adrian.


Home | Main Index | Thread Index | Old Index