Bug #6245
build failed with edonr_test
0%
Description
after merges to latest illumos - https://github.com/illumos/illumos-gate/commit/79c28b707e05fa6746e9e9f99cad98db6b963592 - my build failed with:
+ /usr/gcc/4.8/bin/gcc -fident -finline -fno-inline-functions -fno-builtin -fno-asm -fdiagnostics-show-option -nodefaultlibs -D__sun -I /myshare/builds/ssd02/builds/dilos-illumos.lx/usr/src/uts/common -D_KERNEL -ffreestanding -DTEXT_DOMAIN="SUNW_OST_OSCMD" -D_TS_ERRNO -I/myshare/builds/ssd02/builds/dilos-illumos.lx/proto/root_i386/usr/include -Wl,-Bdirect -Wl,-M/myshare/builds/ssd02/builds /dilos-illumos.lx/usr/src/common/mapfiles/common/map.noexstk -Wl,-M/myshare/builds/ssd02/builds/dilos-illumos.lx/usr/src/common/mapfiles/common/map.pagealign -Wl,-M/myshare/builds/ssd02/builds/dilos-illumos.lx/usr/src/common/mapfiles/common/map.noexdata -o edonr_test ../edonr_test.c -L/myshare /builds/ssd02/builds/dilos-illumos.lx/proto/root_i386/lib -L/myshare/builds/ssd02/builds/dilos-illumos.lx/proto/root_i386/usr/lib -lmd -lc Undefined first referenced symbol in file EdonRFinal /tmp/nightly.tmpdir.15985/cctgamIz.o EdonRInit /tmp/nightly.tmpdir.15985/cctgamIz.o EdonRUpdate /tmp/nightly.tmpdir.15985/cctgamIz.o ld: fatal: symbol referencing errors. No output written to edonr_test collect2: error: ld returned 1 exit status *** Error code 1 dmake: Fatal error: Command failed for target `edonr_test'
Updated by Igor Kozhukhov over 5 years ago
it is failed with build by 64bit gcc48.
problem is: we try to use gcc as LD without 32/64 bits definitions.
Resolution: need provide -m32/-m64 to build line directly for reduce issues with default bootstrap of gcc or others compilers.
we have more places where we try to use gcc based on default bootstrap without -m32/-m64 and it is problem if we try to use gcc based on 64bit bootstrap.
Updated by Gary Mills over 5 years ago
Does adding the missing `-m32' options in Makefile.master fix this problem?
$ grep _XARCH= usr/src/Makefile.master sparc_XARCH= -m32 sparcv9_XARCH= -m64 i386_XARCH= amd64_XARCH= -m64 -Ui386 -U__i386 sparc_AS_XARCH= -xarch=v8plus sparcv9_AS_XARCH= -xarch=v9 i386_AS_XARCH= amd64_AS_XARCH= -xarch=amd64 -P -Ui386 -U__i386
Updated by Igor Kozhukhov over 5 years ago
Gary Mills wrote:
Does adding the missing `-m32' options in Makefile.master fix this problem?
[...]
nope, it will not fix this problem.
you can find more updates on my dilos-illumos tree, with this change too, for fixing more issues if you try to use gcc with 64bit bootstrap