Package: gcc-4.9
Version: 4.9.1-16
Severity: important
Hello,
Found a FTBFS while trying to build unzip package in Debian/sid on armhf host.
gcc -c -g -O2 -fstack-protector-strong -Wall -D_FORTIFY_SOURCE=2 -I. -DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT -DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD -DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DIZ_HAVE_UXUIDGID -DNOMEMCPY -DNO_WORKING_ISPRINT inflate.c
gcc -c -g -O2 -fstack-protector-strong -Wall -D_FORTIFY_SOURCE=2 -I. -DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT -DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD -DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DIZ_HAVE_UXUIDGID -DNOMEMCPY -DNO_WORKING_ISPRINT list.c
gcc -c -g -O2 -fstack-protector-strong -Wall -D_FORTIFY_SOURCE=2 -I. -DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT -DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD -DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DIZ_HAVE_UXUIDGID -DNOMEMCPY -DNO_WORKING_ISPRINT match.c
gcc -c -g -O2 -fstack-protector-strong -Wall -D_FORTIFY_SOURCE=2 -I. -DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT -DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD -DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DIZ_HAVE_UXUIDGID -DNOMEMCPY -DNO_WORKING_ISPRINT process.c
process.c: In function 'wide_to_local_string':
process.c:2453:7: warning: variable 'state_dependent' set but not used [-Wunused-but-set-variable]
int state_dependent;
^
/tmp/cc0hC5mg.s: Assembler messages:
/tmp/cc0hC5mg.s:898: Error: offset out of range
/tmp/cc0hC5mg.s:899: Error: offset out of range
make[1]: *** [process.o] Error 1
unix/Makefile:234: recipe for target 'process.o' failed
make[1]: Leaving directory '/«PKGBUILDDIR»'
make: *** [build] Error 2
debian/rules:34: recipe for target 'build' failed
dpkg-buildpackage: error: debian/rules build gave error exit status 2
After trying different toolchain versions, for binutils and gcc-4.9, it builds with -O1, but fails with -O2. So, apparently the bug is on the GCC optimizer.
I was about to file a bug upstream for that one, but I was unable to reproduce with gcc-snapshot, therefore I file it here for now.
Find attached testcase: process.i
Compile line to be able to reproduce:
gcc -c -g -O2 -fstack-protector-strong -Wall -D_FORTIFY_SOURCE=2 -I. -DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT -DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD -DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DIZ_HAVE_UXUIDGID -DNOMEMCPY -DNO_WORKING_ISPRINT process.i
-- System Information:
Debian Release: jessie/sid
APT prefers unstable
APT policy: (900, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)
Foreign Architectures: armhf
Kernel: Linux 3.14-2-686-pae (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages gcc-4.9 depends on:
ii binutils 2.24.51.20141001-1
ii cpp-4.9 4.9.1-16
ii gcc-4.9-base 4.9.1-16
ii libc6 2.19-11
ii libcloog-isl4 0.18.2-1
ii libgcc-4.9-dev 4.9.1-16
ii libgmp10 2:6.0.0+dfsg-6
ii libisl10 0.12.2-2
ii libmpc3 1.0.2-1
ii libmpfr4 3.1.2-1
ii zlib1g 1:1.2.8.dfsg-2
Versions of packages gcc-4.9 recommends:
ii libc6-dev 2.19-11
Versions of packages gcc-4.9 suggests:
ii gcc-4.9-doc 4.9.1-2
pn gcc-4.9-locales <none>
ii gcc-4.9-multilib 4.9.1-16
pn libasan1-dbg <none>
pn libatomic1-dbg <none>
pn libcilkrts5-dbg <none>
pn libgcc1-dbg <none>
pn libgomp1-dbg <none>
pn libitm1-dbg <none>
pn liblsan0-dbg <none>
pn libquadmath0-dbg <none>
pn libtsan0-dbg <none>
pn libubsan0-dbg <none>
-- no debconf information
Attachment:
process.i.gz
Description: application/gzip