Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/index.php/Reporting_Bug_Guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#2963 - makepkg.conf setting for CFLAGS breaks libjpeg build

Attached to Project: Arch Linux
Opened by Alexander Baldeck (kth5) - Friday, 15 July 2005, 10:06 GMT
Last edited by arjan timmerman (blaasvis) - Friday, 15 July 2005, 10:37 GMT
Task Type Bug Report
Category System
Status Closed
Assigned To Judd Vinet (judd)
Architecture not specified
Severity High
Priority Normal
Reported Version 0.7 Wombat
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 0
Private No

Details

the linker flag (-Wl,O1) set for CFLAGS is problematic with some packages.
for example libjpeg does not build shared objects of itself when -Wl,O1 is enabled. exactly the same happens for a couple of other packages as well. in case of libjpeg, KDE will not be able to display images anymore.
This task depends upon

Closed by  Judd Vinet (judd)
Friday, 15 July 2005, 17:42 GMT
Reason for closing:  Fixed
Comment by Alexander Baldeck (kth5) - Friday, 15 July 2005, 10:42 GMT
further examples:

configure output with -Wl,O1 enabled:

checking for gcc... gcc
checking whether the C compiler (gcc -march=i686 -O2 -pipe -Wl,-O1 ) works... yes
checking whether the C compiler (gcc -march=i686 -O2 -pipe -Wl,-O1 ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking how to run the C preprocessor... gcc -E
checking for function prototypes... yes
checking for stddef.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for size_t... yes
checking for type unsigned char... yes
checking for type unsigned short... yes
checking for type void... yes
checking for working const... yes
checking for inline... __inline__
checking for broken incomplete types... ok
checking for short external names... ok
checking to see if char is signed... yes
checking to see if right shift is signed... yes
checking to see if fopen accepts b spec... yes
checking for a BSD compatible install... /bin/install -c
checking for ranlib... ranlib
checking host system type... i686-pc-linux-gnu
checking for ranlib... ranlib
checking for gcc... gcc
checking whether we are using GNU C... yes
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... no
checking if gcc static flag -static works... -static
checking whether ln -s works... yes
checking for ld used by GCC... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking whether the linker (/usr/bin/ld) supports shared libraries... yes
checking for BSD-compatible nm... /usr/bin/nm -B
checking command to parse /usr/bin/nm -B output... yes
checking how to hardcode library paths into programs... immediate
checking for /usr/bin/ld option to reload object files... -r
checking dynamic linker characteristics... Linux ld.so
checking if libtool supports shared libraries... no
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for objdir... .libs
creating libtool
checking libjpeg version number... 62
creating ./config.status
creating Makefile
creating jconfig.h

list of file in $startdir/pkg/usr/lib:

total 160
-rw-r--r-- 1 kth5 users 159460 2005-07-15 12:39 libjpeg.a
-rwxr-xr-x 1 kth5 users 427 2005-07-15 12:39 libjpeg.la


configure output with -Wl,O1 DISABLED:

checking for gcc... gcc
checking whether the C compiler (gcc -march=i686 -O2 -pipe ) works... yes
checking whether the C compiler (gcc -march=i686 -O2 -pipe ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking how to run the C preprocessor... gcc -E
checking for function prototypes... yes
checking for stddef.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for size_t... yes
checking for type unsigned char... yes
checking for type unsigned short... yes
checking for type void... yes
checking for working const... yes
checking for inline... __inline__
checking for broken incomplete types... ok
checking for short external names... ok
checking to see if char is signed... yes
checking to see if right shift is signed... yes
checking to see if fopen accepts b spec... yes
checking for a BSD compatible install... /bin/install -c
checking for ranlib... ranlib
checking host system type... i686-pc-linux-gnu
checking for ranlib... ranlib
checking for gcc... gcc
checking whether we are using GNU C... yes
checking for gcc option to produce PIC... -fPIC
checking if gcc PIC flag -fPIC works... yes
checking if gcc static flag -static works... -static
checking whether ln -s works... yes
checking for ld used by GCC... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking whether the linker (/usr/bin/ld) supports shared libraries... yes
checking for BSD-compatible nm... /usr/bin/nm -B
checking command to parse /usr/bin/nm -B output... yes
checking how to hardcode library paths into programs... immediate
checking for /usr/bin/ld option to reload object files... -r
checking dynamic linker characteristics... Linux ld.so
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for objdir... .libs
creating libtool
checking libjpeg version number... 62
creating ./config.status
creating Makefile
creating jconfig.h

list of file in $startdir/pkg/usr/lib:

total 296
-rw-r--r-- 1 kth5 users 159460 2005-07-15 12:42 libjpeg.a
-rwxr-xr-x 1 kth5 users 469 2005-07-15 12:42 libjpeg.la
lrwxrwxrwx 1 kth5 users 17 2005-07-15 12:42 libjpeg.so -> libjpeg.so.62.0.0
lrwxrwxrwx 1 kth5 users 17 2005-07-15 12:42 libjpeg.so.62 -> libjpeg.so.62.0.0
-rwxr-xr-x 1 kth5 users 135922 2005-07-15 12:42 libjpeg.so.62.0.0
Comment by Alexander Baldeck (kth5) - Friday, 15 July 2005, 11:23 GMT
also happens for zlib 1.2.2-2
Comment by Jan de Groot (JGC) - Friday, 15 July 2005, 16:39 GMT
What about configuring with --enable-shared? I have fixed quite some libs to include this option on configure, otherwise it would compile static libs only.
Comment by Judd Vinet (judd) - Friday, 15 July 2005, 17:42 GMT
This is fixed in pacman's CVS. The linker optimization flag will be removed from CFLAGS for the next pacman release.

Loading...