0

I am currently tryong to compile gcc's source code by following those couple of steps on my Ubunt machine. The only difference is that I took the official gcc code from github and didn't do a wget. The endgoal is to be able to run gcc on another machine which is 32 bit x86 and runs a Unix variant.

Generating the makefile using the config script provided by gcc works perfectly fine. Yet, when trying to build I get this error: /bin/bash: i386-unixware-elf-ar: command not found which makes my build fail:

$../gcc-master/configure -v --build=x86_64-linux-gnu --host=i386-unixware-elf --target=i386-unixware-elf --prefix=/usr/local/gccPort     --enable-checking=release --enable-languages=c,c++ --disable-multilib --program-suffix=-Port
...
$make -j

...
mkdir -p -- .deps
rm -f libdecnumber.a
i386-unixware-elf-ar cru libdecnumber.a decNumber.o decContext.o decimal32.o decimal64.o decimal128.o 
/bin/bash: i386-unixware-elf-ar: command not found
Makefile:88: recipe for target 'libdecnumber.a' failed
make[2]: *** [libdecnumber.a] Error 127
make[2]: Leaving directory '/home/John/Desktop/gdbport/gccbuild/libdecnumber'
Makefile:8666: recipe for target 'all-libdecnumber' failed
make[1]: *** [all-libdecnumber] Error 2
yes
checking for strtod... yes

...

config.status: linking ../../gcc-master/gmp/mpn/generic/gmp-mparam.h to gmp-mparam.h
config.status: executing libtool commands
configure: summary of build options:

  Version:           GNU MP 6.1.0
  Host type:         none-unixware-elf
  ABI:               standard
  Install prefix:    /usr/local/gccPort
  Compiler:          gcc
  Static libraries:  yes
  Shared libraries:  no

make[1]: Leaving directory '/home/John/Desktop/gdbport/gccbuild'
Makefile:948: recipe for target 'all' failed
make: *** [all] Error 2

I tried changing the parameters to the config script as follows (removing elf in host and target):

$../gcc-master/configure -v --build=x86_64-linux-gnu --host=i386-unixware --target=i386-unixware
--prefix=/usr/local/gccPort     --enable-checking=release --enable-languages=c,c++ 

--disable-multilib --program-suffix=-Port

But that almost gave the same error: /bin/bash: i386-unixware-ar: command not found

Could somebody explain what the issue is?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.