[cups-devel] [UNKN] STR #4387: cups-1.7.1 fails to (cross) compile on MIPS architecture

vincent.riera at imgtec.com vincent.riera at imgtec.com
Mon Mar 10 04:07:00 PDT 2014


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

DO NOT REPLY TO THIS MESSAGE.  INSTEAD, POST ANY RESPONSES TO THE LINK BELOW.

[STR New]

Due to the last bug has been closed before waiting for confirmation, and
due to there is no option to reopen it, I have decided to report the same
bug again.

Please, don't close bugs before confirmation to be sure if the proposed
solution works.

Former bug: https://www.cups.org/str.php?L4381

The proposed solution (using --with-optim option) doesn't work. This is my
last message in the former bug:

- ----------------------------------

Hello Michael,

I have used --with-optim="-fPIC", but the problem is that -fPIC is only
passed to LDFLAGS, not to CFLAGS, so I still having the same failure.
Please, take a look to this:

./configure --target=mips64-buildroot-linux-uclibc
- --host=mips64-buildroot-linux-uclibc --build=x86_64-unknown-linux-gnu
- --prefix=/usr --exec-prefix=/usr --sysconfdir=/etc --program-prefix=""
- --disable-gtk-doc --disable-doc --disable-docs --disable-documentation
- --with-xmlto=no --with-fop=no   --enable-ipv6 --enable-static
- --disable-shared  --without-perl --without-java --without-php
- --disable-gnutls --disable-gssapi --with-optim=-fPIC --libdir=/usr/lib
- --disable-dbus --without-python --disable-pdftops

As you can see, the -fPIC option is present. Now, take a look to this:

make[1]: Entering directory
`/home/ldap/vriera/work/mips-buildroots/mips32_be_sf/output/build/cups-1.7.1'
Using ARCHFLAGS=
Using ALL_CFLAGS=-I.. -D_CUPS_SOURCE -D_LARGEFILE_SOURCE
- -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
- -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -pipe -Os  
- -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_THREAD_SAFE -D_REENTRANT
Using ALL_CXXFLAGS=-I.. -D_CUPS_SOURCE -D_LARGEFILE_SOURCE
- -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
- -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -pipe -Os  
- -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_THREAD_SAFE -D_REENTRANT
Using
CC=/home/ldap/vriera/work/mips-buildroots/mips32_be_sf/output/host/usr/bin/mips64-buildroot-linux-uclibc-gcc
Using
CXX=/home/ldap/vriera/work/mips-buildroots/mips32_be_sf/output/host/usr/bin/mips64-buildroot-linux-uclibc-gcc
Using DSOFLAGS=-L../cups
Using LDFLAGS=-L../cgi-bin -L../cups -L../filter -L../ppdc -L../scheduler
- --static  -fPIE -pie -fPIC  -D_GNU_SOURCE
Using LIBS=../cups/libcups.a    -lz -lpthread -lm -lcrypt   -lz
Making all in cups...

As you can see, the -fPIC option is only present on LDFLAGS, not in
ALL_CFLAGS, so I still having the same failure:

Making all in test...
make[2]: Entering directory
`/home/ldap/vriera/work/mips-buildroots/mips32_be_sf/output/build/cups-1.7.1/test'
Compiling ippserver.c...
Compiling ipptool.c...
Linking ippserver...
/home/ldap/vriera/work/mips-buildroots/mips32_be_sf/output/host/usr/lib/gcc/mips64-buildroot-linux-uclibc/4.7.3/../../../../mips64-buildroot-linux-uclibc/bin/ld:
/home/ldap/vriera/work/mips-buildroots/mips32_be_sf/output/host/usr/lib/gcc/mips64-buildroot-linux-uclibc/4.7.3/crtbeginT.o:
relocation R_MIPS_HI16 against `a local symbol' can not be used when making
a shared object; recompile with -fPIC
/home/ldap/vriera/work/mips-buildroots/mips32_be_sf/output/host/usr/lib/gcc/mips64-buildroot-linux-uclibc/4.7.3/crtbeginT.o:
could not read symbols: Bad value
collect2: error: ld returned 1 exit status
make[2]: *** [ippserver] Error 1

Link: https://www.cups.org/str.php?L4387
Version: 1.7.1
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (GNU/Linux)
Comment: GPGTools - https://gpgtools.org

iQIcBAEBCgAGBQJTHZzUAAoJENujp6sI12Ij2iwQAJ5uCvoXYZzDIYm2pl661Mql
UZn12veN/sQhHl7g/kcapjmvy6X+49d+8o7Vn0TYCPvgpNhG0ryxmNaGQv4F4sPf
brlKMhwDkMI+HM52rMMDHyhLSKw3wNNHVXkVWeD8nHqillHNlHXXD7sTia+azN4k
RW1nQpvon/BoNW7BhK7yKkS2thvtVcNKYEUVEn2XuITUAkGJUSF4dhsmOkOKWm+b
l5XSwgcAQgCThd+bHHQCkt/KMWp6AAdG7V2ajiHW/xn6eEQPyn7/Tv7U+Ihdh4Au
GNFT3i99md7RGX/FNBxu9IU15ggNOgVU7m7OS9NMjr/U+GvvaSiN27RJA+6ZxJVI
XMDSukBLAjp8sBw6u6XSrwO/6/vYhgS8wuIg1CaztqHDLSY1Rzy4prV+tcj1aRUB
PQqs7o2FzoH1TfPvzP0ljGJ7Q6HdtkoPIZIx2rgDLQJha03OU2HPJX5z/41GaWzU
YWuHJ2JGjs1pQR5R8f8MP1bSRp31ZHxsftUa8cUK6FpCXgtT1p3qJY2KnsbSnL3/
WTZgHW/vddWuBxVHc6McU17H0lpNq1ofZgb8wC5z4GkIhaSHIkmTd7EVW9uMPchi
23rEycJvnq1yu2uMbqIwinwDe0napUvWx/eI1+LOdYMvdKGIfBtVsP1x064g/JT2
+RM18Vg4S1sqWIeCJT32
=7Gwx
-----END PGP SIGNATURE-----




More information about the cups mailing list