Bug #2021
closedprint/cups compilation fails with gcc4.4 on w86_64
0%
Description
Trying to build print/cups, I get the following error:
libtool: link: cc -Wl,-R/usr/pkg/lib -pie -fPIE -Wall -Wno-format-y2k -fPIC -Os
-g -fstack-protector -o .libs/bannertops bannertops.o pstext.o common.o
-L/usr/obj/pkgsrc/print/cups/work/cups-1.4.4/cups/.libs
-L/usr/obj/pkgsrc/print/cups/work/cups-1.4.4/cgi-bin
-L/usr/obj/pkgsrc/print/cups/work/cups-1.4.4/cups
-L/usr/obj/pkgsrc/print/cups/work/cups-1.4.4/filter
-L/usr/obj/pkgsrc/print/cups/work/cups-1.4.4/ppdc
-L/usr/obj/pkgsrc/print/cups/work/cups-1.4.4/scheduler
-L/usr/obj/pkgsrc/print/cups/work/.buildlink/lib ../filter/.libs/libcupsimage.so
/usr/obj/pkgsrc/print/cups/work/.buildlink/lib/libtiff.so
/usr/obj/pkgsrc/print/cups/work/.buildlink/lib/libpng14.so
/usr/obj/pkgsrc/print/cups/work/.buildlink/lib/libjpeg.so
/usr/obj/pkgsrc/print/cups/work/cups-1.4.4/cups/.libs/libcups.so
../cups/.libs/libcups.so -lz -lssl -lcrypto -ldns_sd -lm -lcrypt -Wl,-rpath
-Wl,/usr/pkg/lib -Wl,-rpath -Wl,/usr/obj/pkgsrc/print/cups/work/.buildlink/lib
/usr/libexec/binutils217/elf/ld: /usr/lib/crt1.o: relocation R_X86_64_32 against
`_DYNAMIC' can not be used when making a shared object; recompile with -fPIC
/usr/lib/crt1.o: could not read symbols: Bad value
The attached patch from Sascha Wildner builds some internal gcc 4.4 components
with -fPIC and eliminate this error
Files
Updated by ftigeot over 13 years ago
A variation of the attached patch has been integrated to properly support PIE
executables.
Cups now build without any trouble.