KK4.4.3 build failed at gcc check

cancel
Showing results for 
Search instead for 
Did you mean: 

KK4.4.3 build failed at gcc check

Jump to solution
1,744 Views
torus1000
Contributor V

Hi,

I tried to build Android KK4.4.3 image on my 32bit ubuntu14.04 host but error occured at lunch command.

It seemed x86_64 gcc(64b) used instead of i686 gcc(32b).

Can anybody help me to fix gcc selection as i686?

Thanks.

---
[Commands]
...
$ cd ~/myandroid
$ source build/envsetup.sh
$ lunch sabresd_6dq-user
$ make PRODUCT-sabresd_6dq-user 2>&1 | tee build_sabresd_6dq_android.log

[lunch error message]
  /bin/bash: prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7/bin/arm-linux-androideabi-gcc: cannot execute binary file: Exec format error

[make error massages]
  prebuilts/tools/gcc-sdk/../../gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6/bin/x86_64-linux-ar only run on 64-bit linux
  ...

[Misc]
$ uname -sm
  Linux i686

$ file prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7/bin/arm-linux-androideabi-gcc
  prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7/bin/arm-linux-androideabi-gcc:
  ELF 64-bit LSB  executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.8, stripped

Labels (2)
1 Solution
142 Views
SergioSolis
NXP Employee
NXP Employee

Hello,

In order to build android you need your host to be a 64 bit OS, that is why it's forcing you to use x86_64 gcc.

Also, I have never tried to build android with Ubuntu 14.04, it is recommended to use 12.04 as the latest.


Have a great day,
Sergio

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

View solution in original post

0 Kudos
3 Replies
143 Views
SergioSolis
NXP Employee
NXP Employee

Hello,

In order to build android you need your host to be a 64 bit OS, that is why it's forcing you to use x86_64 gcc.

Also, I have never tried to build android with Ubuntu 14.04, it is recommended to use 12.04 as the latest.


Have a great day,
Sergio

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

View solution in original post

0 Kudos
142 Views
torus1000
Contributor V

Dear Sergio,

Thank you for your answer.

Finally I successfuly built KK4.4.3 images with 64bit ubuntu14.04.

P.S.
In my case, I added following package...

     # http://source.android.com/source/initializing.html
     $ sudo apt-get install bison g++-multilib git gperf libxml2-utils
     # misc
     $ sudo apt-get install gksu lib32z1 flex

and modified BoardConfig.mk to re-build boot.img for sdcard.

     # $ make bootimage BUILD_TARGET_DEVICE=sd    <== nothing changed!
     $ vi device/fsl/sabresd_6dq/BoardConfig.mk
     # <<del 13,18-23 lines>>

Have a nice day.

142 Views
SergioSolis
NXP Employee
NXP Employee

Thank you for giving us those details to set Android from Ubuntu 14.04!

0 Kudos