1./usr/bin/ld:skipping incompatible/usr/lib/gcc/x86_64-linux-gnu/4.4.5/appears at compile time. /.. /.. /libz.so when searching For-lz
Platform_version_codename=aosp
Platform_version=aosp
Target_product=generic
Target_build_variant=eng
Target_simulator=
Target_build_type=release
target_build_apps=
Target_arch=arm
Target_arch_variant=armv5te
Host_arch=x86
Host_os=linux
Host_build_type=release
Build_id=openmaster
============================================
Host Executable:aapt (OUT/HOST/LINUX-X86/OBJ/EXECUTABLES/AAPT_INTERMEDIATES/AAPT)
/usr/bin/ld:skipping incompatible/usr/lib/gcc/x86_64-linux-gnu/4.4.5/. /.. /.. /libz.so when searching For-lz
/usr/bin/ld:skipping incompatible/usr/lib/gcc/x86_64-linux-gnu/4.4.5/. /.. /.. /LIBZ.A when searching For-lz
/usr/bin/ld:skipping incompatible//usr/lib/libz.so when searching For-lz
/usr/bin/ld:skipping incompatible//USR/LIB/LIBZ.A when searching For-lz
/usr/bin/ld:cannot Find-lz
Collect2:ld returned 1 exit status
Make: * * * [OUT/HOST/LINUX-X86/OBJ/EXECUTABLES/AAPT_INTERMEDIATES/AAPT] Error 1
Workaround: Missing Lib32z1-dev, installation: Apt-get install Lib32z1-dev
2. [Android] compile-time/usr/include/gnu/stubs.h:7: fatal error:gnu/stubs-32.h:no Such file or directory error message
Compile-time/usr/include/gnu/stubs.h:7: fatal error:gnu/stubs-32.h:no such file or directory
Platform_version_codename=aosp
Platform_version=aosp
Target_product=generic
Target_build_variant=eng
Target_simulator=
Target_build_type=release
target_build_apps=
Target_arch=arm
Target_arch_variant=armv5te
Host_arch=x86
Host_os=linux
Host_build_type=release
Build_id=openmaster
============================================
Host C:ACP <= build/tools/acp/acp.c
In file included from/usr/include/features.h:387,
FROM/USR/INCLUDE/STDLIB.H:25,
From Build/tools/acp/acp.c:11:
/usr/include/gnu/stubs.h:7: Fatal error:gnu/stubs-32.h:no such file or directory
Compilation terminated.
Make: * * * [OUT/HOST/LINUX-X86/OBJ/EXECUTABLES/ACP_INTERMEDIATES/ACP.O] Error 1
Workaround: Missing LIBC Development Package, Installation: Apt-get install libc6-dev-i386
3. Compile-time/usr/include/gnu/stubs.h:7: fatal error:gnu/stubs-32.h:no such file or directory
Platform_version_codename=aosp
Platform_version=aosp
Target_product=generic
Target_build_variant=eng
Target_simulator=
Target_build_type=release
target_build_apps=
Target_arch=arm
Target_arch_variant=armv5te
Host_arch=x86
Host_os=linux
Host_build_type=release
Build_id=openmaster
============================================
Host C:ACP <= build/tools/acp/acp.c
In file included from/usr/include/features.h:387,
FROM/USR/INCLUDE/STDLIB.H:25,
From Build/tools/acp/acp.c:11:
/usr/include/gnu/stubs.h:7: Fatal error:gnu/stubs-32.h:no such file or directory
Compilation terminated.
Make: * * * [OUT/HOST/LINUX-X86/OBJ/EXECUTABLES/ACP_INTERMEDIATES/ACP.O] Error 1
Workaround: Missing LIBC Development Package, Installation: Apt-get install libc6-dev-i386
4. [Android] "OSError: [Errno 2] No such file or directory" error when initializing code warehouse
OSError: [Errno 2] No such file or [email protected]:/home/android/src#.. /repo Init-u Git://android.git.kernel.org/platform/manifest.git
Traceback (most recent):
File ".. /repo ", line 595, in <module>
Main (sys.argv[1:])
File ".. /repo ", line 562, in main
_init (args)
File ".. /repo ", line 181, in _init
_checkgitversion ()
File ".. /repo ", line-in _checkgitversion
proc = subprocess. Popen (cmd, stdout=subprocess. PIPE)
File "/usr/lib/python2.6/subprocess.py", line 623, in __init__
Errread, Errwrite)
File "/usr/lib/python2.6/subprocess.py", line 1141, in _execute_child
Raise Child_exception
OSError: [Errno 2] No such file or directory
Workaround: This is due to the lack of git installed, install git on it. Supposedly the program should determine whether the system installed Git, do not know why no judgment. Apt-get Install git
5. It's not easy to finally see yourself compiling Android
Maybe I use the machine is slow, the virtual machine run a bit slow ah ....
It's not easy, I finally see the android I compiled--
The next step is to study how the system has been customized ....
Compile Android, encounter your version is:/bin/bash:java:command not found. Error resolution
Your version is:/bin/bash:java:command not found.============================================
Platform_version_codename=aosp
Platform_version=aosp
Target_product=generic
Target_build_variant=eng
Target_simulator=
Target_build_type=release
target_build_apps=
Target_arch=arm
Host_arch=x86
Host_os=linux
Host_build_type=release
Build_id=openmaster
============================================
/bin/bash:bison:command not found
Checking Build Tools Versions ...
************************************************************
You is attempting to build with the incorrect version
of Java.
Your version is:/bin/bash:java:command not found.
The correct version is:1.6.
Follow the machine setup instructions at
http://source.android.com/source/download.html
************************************************************
BUILD/CORE/MAIN.MK:114: * * * stop. Stop.
Workaround: This is due to no JDK installed, can be downloaded to sun.com after the JDK installation, it is recommended to install to the/USR/LIB/JVM directory, for example, I downloaded the installation file for Jdk-6u21-linux-i586.bin, after installation to generate a jdk1.6.0 _21 directory, and then use the ln-s jdk1.6.0_21 java-6-sun command to make a link so you can upgrade the Sun JDK later with just a few changes to the link.
6. Compile Android, encounter could not load ' Clearsilver-jni ' ERROR resolution
Could not load ' clearsilver-jni ' ===========================================
Platform_version_ CODENAME=AOSP
Platform_version=aosp
target_product=generic
Target_build_variant=eng
TARGET_ simulator=
Target_build_type=release
target_build_apps=
target_arch=arm
host_arch=x86
HOST_OS= Linux
host_build_type=release
build_id=openmaster
============================================
Docs droiddoc:out/target/common/docs/api-stubs
Could not load ' clearsilver-jni '
Java.library.path = out/host/l Inux-x86/lib
Make: * * * [Out/target/common/docs/api-stubs-timestamp] Error
Solutions found online:
Make clean
Make Update-api (tested, this may not be required)
Make
7. JDK storage location in Android compilation environment
Because Ubuntu 10.04 does not already have a sun JDK, this needs to be downloaded to the Sun website and installed manually. So the problem with this installation location is there. The beginning of the time did not notice, casually find a location, and set the java_home can be used normally. Later check build/envsetup.sh only found that if the java_home is not set, the compilation environment is automatically set to/usr/lib/jvm/java-6-sun, so it is recommended to install directly to this directory, but also save to set up.
There is a problem with the VMware Virtual Disk file ...
Dizzy dead, do not say anything else, download the Android source code for almost a day ah ...
There is an error in the VMware Virtual Disk File ...-
It seems that the power off the machine last night, did not expect to affect such a large ....
8. Android compilation encountered error/usr/bin/ld:cannot find-lstdc++ resolution
First found compiled version 2.2, gcc4.3 and gcc4.4 no difference.
/usr/bin/ld:cannot find-lstdc++
============================================
Platform_version_codename=aosp
Platform_version=aosp
Target_product=generic
Target_build_variant=eng
Target_simulator=
Target_build_type=release
target_build_apps=
Target_arch=arm
Host_arch=x86
Host_os=linux
Host_build_type=release
Build_id=openmaster
============================================
Host Sharedlib:libneo_util (out/host/linux-x86/obj/lib/libneo_util.so)
/usr/bin/ld:skipping incompatible/usr/lib/gcc/i486-linux-gnu/4.3.4/libstdc++.so when searching for-lstdc++
/usr/bin/ld:skipping INCOMPATIBLE/USR/LIB/GCC/I486-LINUX-GNU/4.3.4/LIBSTDC++.A when searching for-lstdc++
/usr/bin/ld:skipping incompatible/usr/lib/gcc/i486-linux-gnu/4.3.4/libstdc++.so when searching for-lstdc++
/usr/bin/ld:skipping INCOMPATIBLE/USR/LIB/GCC/I486-LINUX-GNU/4.3.4/LIBSTDC++.A when searching for-lstdc++
/usr/bin/ld:cannot find-lstdc++
Collect2:ld returned 1 exit status
Make: * * [out/host/linux-x86/obj/lib/libneo_util.so] Error 1
Workaround: Missing G++-multilib library, installation: Apt-get install G++-multilib
9. Android compilation encountered an error
Environment: VMware + Ubuntu 10.04
using gcc 4.3 or gcc 4.4 will give you an error message:
Host Sharedlib:libneo_util (out/host/linux-x86/obj/lib/libneo_util.so)
/usr/bin/ld:skipping incompatible/usr/lib/gcc/i486-linux-gnu/4.3.4/libstdc++.so when searching for-lstdc++
/usr/bin/ld:skipping INCOMPATIBLE/USR/LIB/GCC/I486-LINUX-GNU/4.3.4/LIBSTDC++.A when searching for-lstdc++
/usr/bin/ld:skipping incompatible/usr/lib/gcc/i486-linux-gnu/4.3.4/libstdc++.so when searching for-lstdc++
/usr/bin/ld:skipping INCOMPATIBLE/USR/LIB/GCC/I486-LINUX-GNU/4.3.4/LIBSTDC++.A when searching for-lstdc++
/usr/bin/ld:cannot find-lstdc++
Collect2:ld returned 1 exit status
Make: * * [out/host/linux-x86/obj/lib/libneo_util.so] Error 1
Now do not know how to solve, according to http://www.ways2u.com/?post=163 write the use of GCC 4.3 will not have this problem, but my side still appear this error ....
Android compilation Environment
Android all source code in http://android.git.kernel.org/
If you can only use git to download a project for a project under Windows, if you are able to download all the code directly using repo in Linux
For all downloads under Linux see http://source.android.com/source/git-repo.html
gcc 4.3 must be installed, for example, I use the Ubuntu 10.04 default is 4.4, the compilation will be wrong.
After installing Eclipse & SDK, you need to install some software to build Android:
Apt-get Install Bison
Apt-get Install g++
Apt-get Install LIBC6-DEV-AMD64
To the source code directory execution
Make
Can
[Go] compile Android source code common error Resolution