[Bug target/22073] --with-cpu=default32 for x86_64

marek dot rouchal at infineon dot com gcc-bugzilla@gcc.gnu.org
Thu Jul 2 13:52:00 GMT 2009



------- Comment #9 from marek dot rouchal at infineon dot com  2009-07-02 13:52 -------
(In reply to comment #8)
> For a 32-bit-default compiler that can also build 64-bit code, configure
> for i686-pc-linux-gnu with --enable-targets=all.  (Set CC="gcc -m32"
> and CC_FOR_BUILD="gcc -m32" in your environment and configure
> --enable-targets=all --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu
> --target=i686-pc-linux-gnu.)  This is implemented in 4.3 and later.

I tried this - and it does not work here. I even added STAGE1_CFLAGS="-m32 -g"
as suggested in an earlier comment. The build of gcc-4.3.2 bails out at this
point:

gmake[7]: Leaving directory
`/var/vob/relman/admin/vob/devenv/Gcc/linux40_64/gcc-4.3.2/gcc'
mkdir -p -- i686-pc-linux-gnu/libgcc
Checking multilib configuration for libgcc...
Configuring stage 1 in i686-pc-linux-gnu/libgcc
configure: creating cache ./config.cache
checking for --enable-version-specific-runtime-libs... no
checking for a BSD-compatible install... /usr/bin/install -c
checking for gawk... gawk
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking for i686-pc-linux-gnu-ar... ar
checking for i686-pc-linux-gnu-lipo... lipo
checking for i686-pc-linux-gnu-nm...
/var/vob/relman/admin/vob/devenv/Gcc/linux40_64/gcc-4.3.2/./gcc/nm
checking for i686-pc-linux-gnu-ranlib... ranlib
checking for i686-pc-linux-gnu-strip... strip
checking whether ln -s works... yes
checking for i686-pc-linux-gnu-gcc...
/var/vob/relman/admin/vob/devenv/Gcc/linux40_64/gcc-4.3.2/./gcc/xgcc
-B/var/vob/relman/admin/vob/devenv/Gcc/linux40_64/gcc-4.3.2/./gcc/
-B/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/bin/
-B/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/lib/ -isystem
/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/include -isystem
/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/sys-include
checking for suffix of object files... configure: error: cannot compute suffix
of object files: cannot compile
See `config.log' for more details.

The relevant portion of the gcc-4.3.2/i686-pc-linux-gnu/libgcc/config.log is:

configure:2398:
/var/vob/relman/admin/vob/devenv/Gcc/linux40_64/gcc-4.3.2/./gcc/xgcc
-B/var/vob/relman/admin/vob/devenv/Gcc/linux40_64/gcc-4.3.2/./gcc/
-B/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/bin/
-B/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/lib/ -isystem
/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/include -isystem
/opt/gcc_4.3.2/linux40_64/i686-pc-linux-gnu/sys-include -o conftest -g
-fkeep-inline-functions  -Wl,-rpath,/opt/gcc_4.3.2/linux40_64/ext/lib
conftest.c  >&5
/tmp/ccIIK43d.s: Assembler messages:
/tmp/ccIIK43d.s:19: Error: suffix or operands invalid for `push'
/tmp/ccIIK43d.s:21: Error: suffix or operands invalid for `push'
/tmp/ccIIK43d.s:25: Error: suffix or operands invalid for `push'
/tmp/ccIIK43d.s:30: Error: suffix or operands invalid for `pop'
/tmp/ccIIK43d.s:31: Error: suffix or operands invalid for `pop'

I assume that the -m32 option is not passed through correctly. I think that in
gcc-4.3.2/Makefile the HOST_EXPORTS macro does not contain the appropriate
CFLAGS. Or is this perhaps fixed in gcc-4.3.3?


-- 

marek dot rouchal at infineon dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
      Known to fail|                            |4.3.2
         Resolution|FIXED                       |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22073



More information about the Gcc-bugs mailing list