New: Buildroot 2012.11: Additional GCC option "-msoft-float" breaks the build
https://bugs.busybox.net/show_bug.cgi?id=5810
Summary: Buildroot 2012.11: Additional GCC option
"-msoft-float" breaks the build
Product: buildroot
Version: unspecified
Platform: PC
OS/Version: Linux
Status: NEW
Severity: major
Priority: P5
Component: Other
AssignedTo: unassigned at buildroot.uclibc.org
ReportedBy: tbolsh at gmail.com
CC: buildroot at uclibc.org
Estimated Hours: 0.0
I need to build an embedded Linux for 486 without coprocessor. 2012.08 works for that reason, 2012.11 breaks.
Here is the error (meanwhile - why it applies arm related patches to x86?):
_____________________________________________________
Applying 810-arm-softfloat-libgcc.patch using patch:
patching file gcc/config/arm/linux-elf.h
patching file libgcc/config/arm/t-linux
Applying 830-arm_unbreak_armv4t.patch using patch:
patching file gcc/config/arm/linux-eabi.h
touch /root/buildroot-2012.11/output/toolchain/gcc-4.7.2/.patched mkdir -p /root/buildroot-2012.11/output/toolchain/gcc-4.7.2-initial (cd /root/buildroot-2012.11/output/toolchain/gcc-4.7.2-initial; rm -rf config.cache; \
PATH=/root/buildroot-2012.11/output/host/bin:/root/buildroot-2012.11/output/host/usr/bin:/usr/lib/git-core:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin AR="/usr/bin/ar" AS="/usr/bin/as" LD="/usr/bin/ld" NM="/usr/bin/nm"
CC="/root/buildroot-2012.11/output/host/usr/bin/ccache /usr/bin/gcc"
GCC="/root/buildroot-2012.11/output/host/usr/bin/ccache /usr/bin/gcc"
CXX="/root/buildroot-2012.11/output/host/usr/bin/ccache /usr/bin/g++"
CPP="/usr/bin/cpp" CPPFLAGS="-I/root/buildroot-2012.11/output/host/usr/include"
CFLAGS="-O2 -I/root/buildroot-2012.11/output/host/usr/include" CXXFLAGS="-O2
-I/root/buildroot-2012.11/output/host/usr/include"
LDFLAGS="-L/root/buildroot-2012.11/output/host/lib
-L/root/buildroot-2012.11/output/host/usr/lib
-Wl,-rpath,/root/buildroot-2012.11/output/host/usr/lib"
PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 PKG_CONFIG_ALLOW_SYSTEM_LIBS=1
PKG_CONFIG="/root/buildroot-2012.11/output/host/usr/bin/pkg-config"
PKG_CONFIG_SYSROOT_DIR="/" PKG_CONFIG_LIBDIR="/root/buildroot-2012.11/output/host/usr/lib/pkgconfig:/root/buildroot-2012.11/output/host/usr/share/pkgconfig" PERLLIB="/root/buildroot-2012.11/output/host/usr/lib/perl"
LD_LIBRARY_PATH="/root/buildroot-2012.11/output/host/usr/lib:" \
/root/buildroot-2012.11/output/toolchain/gcc-4.7.2/configure \
--prefix=/root/buildroot-2012.11/output/host/usr \
--build=i686-pc-linux-gnu \
--host=i686-pc-linux-gnu \
--target=i486-buildroot-linux-uclibc \
--enable-languages=c \--with-sysroot=/root/buildroot-2012.11/output/toolchain/uClibc_dev/ \
--disable-__cxa_atexit \
--enable-target-optspace \
\
--enable-libgomp \
--with-gnu-ld \
--disable-shared \
--disable-libssp \
--without-headers \
--with-newlib \
--disable-multilib \
--enable-tls \
--with-gmp=/root/buildroot-2012.11/output/host/usr \
--with-mpfr=/root/buildroot-2012.11/output/host/usr \
--with-mpc=/root/buildroot-2012.11/output/host/usr \
--disable-nls \
--enable-threads \
--disable-decimal-float \
\
--with-arch="i486" --with-tune="i486" \
--with-pkgversion="Buildroot 2012.11"
--with-bugurl="http://bugs.buildroot.net/" -msoft-float \
)configure: error: unrecognized option: `-msoft-float'
Try `/root/buildroot-2012.11/output/toolchain/gcc-4.7.2/configure --help' for more information.
make: *** [/root/buildroot-2012.11/output/toolchain/gcc-4.7.2-initial/.configured] Error 1
Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
[Buildroot] [Bug 5810] Buildroot 2012.11: Additional GCC option "-msoft-float" breaks the build
https://bugs.busybox.net/show_bug.cgi?id=5810
--- Comment #1 from Thomas Petazzoni <[email protected]> 2012-12-21 18:22:34 UTC --- Please post your Buildroot .config so we can reproduce the problem.
And for the "meanwhile - why it applies arm related patches to x86?" question, this is because we don't do architecture-specific patches. Those patches are always applied, regardless of which architecture you are building for, but in practice they only touch ARM-specific parts of gcc, so they are totally harmless if you build for x86, PowerPC or MIPS. Having a single stack of patches that are always applied regardless of the selected architecture is much better than having per-architecture patches.
Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
[Buildroot] [Bug 5810] Buildroot 2012.11: Additional GCC option "-msoft-float" breaks the build
In reply to bugzilla at busybox.nethttps://bugs.busybox.net/show_bug.cgi?id=5810
--- Comment #2 from Timofei Bolshakov <[email protected]> 2012-12-21 18:42:55 UTC --- (In reply to comment #1)
Quoted 9 lines
Please post your Buildroot .config so we can reproduce the problem.
And for the "meanwhile - why it applies arm related patches to x86?" question, this is because we don't do architecture-specific patches. Those patches are always applied, regardless of which architecture you are building for, but in practice they only touch ARM-specific parts of gcc, so they are totally harmless if you build for x86, PowerPC or MIPS. Having a single stack of patches that are always applied regardless of the selected architecture is much better than having per-architecture patches.
OK.
Especially if it is harmless.
Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
[Buildroot] [Bug 5810] Buildroot 2012.11: Additional GCC option "-msoft-float" breaks the build
In reply to bugzilla at busybox.nethttps://bugs.busybox.net/show_bug.cgi?id=5810
--- Comment #3 from Timofei Bolshakov <[email protected]> 2012-12-21 18:52:40 UTC --- Created attachment 4706
--> https://bugs.busybox.net/attachment.cgi?id=4706
Zip file contains .config and kernel defconfig used in .config
Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
[Buildroot] [Bug 5810] Buildroot 2012.11: Additional GCC option "-msoft-float" breaks the build
In reply to bugzilla at busybox.nethttps://bugs.busybox.net/show_bug.cgi?id=5810
--- Comment #4 from Thomas Petazzoni <[email protected]> 2012-12-21 19:00:13 UTC --- So, you're explicitly passing:
BR2_EXTRA_GCC_CONFIG_OPTIONS="-msoft-float"
in your Buildroot configuration, and then you complain because GCC doesn't understand your special flag? If you pass a special flag, aren't you supposed to know what you're doing?
This seems like a curious bug report, isn't it ?
Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
[Buildroot] [Bug 5810] Buildroot 2012.11: Additional GCC option "-msoft-float" breaks the build
In reply to bugzilla at busybox.nethttps://bugs.busybox.net/show_bug.cgi?id=5810
--- Comment #5 from Timofei Bolshakov <[email protected]> 2012-12-21 20:44:10 UTC --- (In reply to comment #4)
Quoted 3 lines
So, you're explicitly passing:
BR2_EXTRA_GCC_CONFIG_OPTIONS="-msoft-float"
No, I am setting "Additional gcc options". That leads to BR2_EXTRA_GCC_CONFIG_OPTIONS="-msoft-float"
I surely was not understanding that it will lead to CONFIG option. My fault. But that is curious conversion from "Additional gcc options" to BR2_EXTRA_GCC_CONFIG_OPTIONS - it is not clear until one goes into the .config in text form. Meanwhile - using it in "Target optimizations" also leads to break.
And that was not breaking the build in 2012.8
So, where should I put my -msoft-float then? I want everything to be compiled with this flag.
Quoted 3 lines
in your Buildroot configuration, and then you complain because GCC doesn't understand your special flag?
What should I complain about then? Unclear language?
If one will change "Additional gcc options" to "Additional gcc config options" there will be no confusion. Or to use anything I should go and check the source code?
Quoted 4 lines
If you pass a special flag, aren't you supposed
to know what you're doing?This seems like a curious bug report, isn't it ?
That is clear enough:
-msoft-float
Use (do not use) the hardware floating-point instructions for
floating-point operations. When -msoft-float is specified, functions in libgcc.a will be used to perform floating-point operations. Unless they are replaced by routines that emulate the floating-point operations, or compiled in such a way as to call such emulations routines, these routines will issue floating-point operations. If you are compiling for an Alpha without floating-point operations, you must ensure that the library is built so as not to call them. Note that Alpha implementations without floating-point operations are required to have floating-point registers.
That is what I want - "functions in libgcc.a will be used to perform floating-point operations". I was wrong to use config option labelled as "additional" for that. Where can I put my "-msoft-float"?
Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
[Buildroot] [Bug 5810] Buildroot 2012.11: Additional GCC option "-msoft-float" breaks the build
In reply to bugzilla at busybox.nethttps://bugs.busybox.net/show_bug.cgi?id=5810
Thomas Petazzoni <[email protected]> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED--- Comment #6 from Thomas Petazzoni <[email protected]> 2014-01-07 07:37:43 UTC --- The ARM soft-float / hard-float support has been significantly improved in the 2013.08 release. There is now a clear way of choosing between soft-float,
hard-float with floating point arguments passed in integer registers (so-called softfp) and hard-float with floating point arguments passed in floating point registers (so called hardfp).
Therefore, I believe this bug can now be considered as fixed.
Signature · 3 lines
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.