Building AOSP 5.1.51 with Ubuntu 14.04 - android

Im trying to build AOSP 5.1.51, I machine meets requirements
Following the instructions but the make -j4 never build succesfully.
Recently trying to lunch aosp_mips-eng terminates with
target C++: v8_tools_gyp_v8_base_gyp <= external/chromium_org/v8/src/mips/lithium-mips.cc
In file included from external/chromium_org/v8/src/mips/lithium-codegen-mips.h:11:0, from external/chromium_org/v8/src/mips/lithium-codegen-mips.cc:36:
external/chromium_org/v8/src/mips/lithium-mips.h: In member function 'bool v8::internal::LCodeGen::GeneratePrologue()':
external/chromium_org/v8/src/mips/lithium-mips.h:2718:7: internal compiler error: Segmentation fault
class LChunkBuilder FINAL : public LChunkBuilderBase {
^
Please submit a full bug report, with preprocessed source if appropriate.
See <http://source.android.com/source/report-bugs.html> for instructions.
make: *** [/home/userAndroid/Builds/AOSP/target/product/generic_mips/obj/STATIC_LIBRARIES/v8_tools_gyp_v8_base_gyp_intermediates/v8/src/mips/lithium-codegen-mips.o] Error 1
make: *** Waiting for unfinished jobs....
#### make failed to build some targets (21:29 (mm:ss)) ####
And it ends there :(

After so many tries, I ended up removing the entire source repo, fetch everything and build. Now everything works way better than before. I have not read everything to see if its the introduction of jackor things are better with the latest branch of android source.
If you are struggling with your build, this could be the way to go.

Related

Android build error (Slim7.1) because of ALSA

Totally new to ROM building! Trying to build slim for the LG K20 Plus TP260 (MSM8917)
I've downloaded LG's source and have tried to assimilate it into Slim's source (basically merging everything but the frameworks folder) and am now trying to build.
But this is the Ninja error I get:
ninja: Entering directory `.'
ninja: error: '/home/android/Desktop/cheap_android_love/out/target/product/generic_arm64/obj/KERNEL_OBJ/usr', needed by '/home/android/Desktop/cheap_android_love/out/target/product/generic_arm64/obj/SHARED_LIBRARIES/libtinyalsa_intermediates/mixer.o', missing and no known rule to make it
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
I've checked the directory, and the "obj" folder doesn't even exist, so this error seems impossible to me... What files do I need to look at?
After changes to BoardConfig.mk and Kernel.mk makefiles regarding target kernel config and target source, everything goes together fine!

Can't read proguard.ClassPathEntry unexpected EOF

I am trying to build cubieboard 4 AOSP source (version 4.4. I think it has nothing to do with Cubieboard). But I am getting errors related to proguard: Error: Can't read [proguard.ClassPathEntry#5f893efe] (unexpected EOF)
build/core/java.mk:435: recipe for target 'out/target/common/obj/APPS/Camera2_intermediates/proguard.classes.jar' failed
In fact I was able to build complete source without errors previously. But don't know all of a sudden how come this error started appearing.
I have gone through link Android Proguard java.io.IOException, though this is related to file not found and mine is unexpected EOF (End of file); and have already tried below things:
Deleting complete out folder and then doing $make -j4
sourcing envsetup.sh $. build/envsetup.sh
Replacing original proguard tool(4.7) with latest (5.3.1)
I can comment particular PRODUCT_PACKAGES from /build/target/product/sdk.mk etc for which proguard error was coming. But finally came across error for Camera2 which is absolutely needed for my application and cannot be commented.
Anybody came across this and found solution? Please Help!
DETAILED LOG with proguard 5.3.1:
Reading library jar [/home/osboxes/Project/Semapresence/cc-a80/android-fresh/out/target/common/obj/JAVA_LIBRARIES/android_stubs_current_intermediates/classes.jar]
Reading library jar [/home/osboxes/Project/Semapresence/cc-a80/android-fresh/out/target/common/obj/JAVA_LIBRARIES/android_stubs_current_intermediates/classes.jar]
Error: Can't read [/home/osboxes/Project/Semapresence/cc-a80/android-fresh/out/target/common/obj/JAVA_LIBRARIES/android_stubs_current_intermediates/classes.jar] (unexpected EOF)
Error: Can't read [/home/osboxes/Project/Semapresence/cc-a80/android-fresh/out/target/common/obj/JAVA_LIBRARIES/android_stubs_current_intermediates/classes.jar] (unexpected EOF)
build/core/java.mk:435: recipe for target 'out/target/common/obj/APPS/DeskClock_intermediates/proguard.classes.jar' failed
make: *** [out/target/common/obj/APPS/DeskClock_intermediates/proguard.classes.jar] Error 1
make: *** Waiting for unfinished jobs....
build/core/java.mk:435: recipe for target 'out/target/common/obj/APPS/Camera2_intermediates/proguard.classes.jar' failed
make: *** [out/target/common/obj/APPS/Camera2_intermediates/proguard.classes.jar] Error 1
Answering my own question. Hope it can help other who faced similar issue:
I could temporarily solve my problem by disabling proguard for particular module for which it was giving error.
To do this added below line to Android.mk
LOCAL_PROGUARD_ENABLED := disabled

Failing to build a simple hello world apk

I am running Windows 8.1 trying to start cocos2d-x. I've got version 3.4 on the system and every time I try building the hello world app the following shows up:
No rule to make target d:/android-ndk/sources/android/cpufeatures/cpu-features.c', needed by obj/local/armeabi/objs-debug/cpufeatures/cpu-features.o`
Waiting for unfinished jobs....
StaticLibrary : libcocos2dandroid.a
make: Leaving directory C:/android/cocos2d-x-3.4/NEW_PROJECTS_DIR/MyGame/proj.android
Ndk build failed
C:\android\cocos2d-x-3.4\NEW_PROJECTS_DIR\MyGame>`
I am using the ndk r9 for this and it's located at c:/android/adt/ndk.
I've tried ndk r10d as well but it brings up the following error instead:
collect2.exe: error: ld returned 1 exit status
make: *** [obj/local/armeabi/libcocos2dcpp.so] Error 1
make: Leaving directory `C:/android/cocos2d-x-3.4/tutorialV3CPPWindows/proj.andr
oid'
Ndk build failed
But I think that the problem is with the ndk. I am quite new to this and have been using tutorials and guides, so detail would be appreciated.
If you use eclipse,check your NDK_ROOT path
the error info
No rule to make target d:/android-ndk/sources/android/cpufeatures/cpu-features.c'
but your ndk r9 is atc:/android/adt/ndk
They are not the same.

SeAndroid Make - Compile Error‏ system/core/init/init.c: In function 'service_start'

I'm having compiling error while trying to build the SeAndroid 4.2 project.
I'm using Ubuntu 12.04 and gcc4.4
I followed the tutorial on SeAndroid Wiki and downloaded the whole source and after I tried to build a kernel.
seandroid-tegra3-grouper-3.1-jb-mr1.1 because I'm using a Asus TF700T device (with tegra chipset).
As mentioned on SeAndroid wiki page, I type
export PREFIX=/path/to/my/aospclone
cd $PREFIX/kernel/tegra
git checkout seandroid-tegra3-grouper-3.1-jb-mr1.1
make ARCH=arm tegra3_android_defconfig
make ARCH=arm CROSS_COMPILE=$PREFIX/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-
The build completes correctly.
Then I'm trying to build my seandroid like :
cd $PREFIX
source build/envsetup.sh
lunch full_grouper-userdebug
make -j8
Then after 20 or 30 minutes of compiling, I got an error
...
system/core/init/init.c: In function 'service_start':
system/core/init/init.c:283:80: error: 'scon' undeclared (first use in this function)
system/core/init/init.c:283:80: note: each undeclared identifier is reported only once for each function it appears in
make: *** [out/target/product/generic/obj/EXECUTABLES/init_intermediates/init.o] Error 1
make: *** Waiting for unfinished jobs....
...
What could be the problem? I tried searching but couldn't find anything useful.

Configuration error of the GMP library for the android platform

I'm trying to compile GMP for android (arm) but I'm received a very strange error. First, I set up a few things as described another SO question here:
export NDKROOT=/prod/ndk
$NDKROOT/build/tools/make-standalone-toolchain.sh --platform=android-9 -- install-dir=$NDKROOT/android_armeabi
export CC="$NDKROOT/android_armeabi/bin/arm-linux-androideabi-gcc --sysroot=$NDKROOT/android_armeabi/sysroot"
export CXX="$NDKROOT/android_armeabi/bin/arm-linux-androideabi-g++ --sysroot=$NDKROOT/android_armeabi/sysroot"
export AR="$NDKROOT/android_armeabi/bin/arm-linux-androideabi-ar"
export SYSROOT="$NDKROOT/android_armeabi/sysroot"
export PATH="$NDKROOT/android_armeabi/bin":$PATH
Then I simply run ./configure --enable-cxx --prefix=/local/to/where/i/want/to/install --host=arm-none-linux-gnueabi and configuration goes well, with the following being part of the output:
Version: GNU MP 5.1.1
Host type: arm-none-linux-gnueabi
ABI: standard
Install prefix: /location/to/where/i/want/to/install
Compiler: /prod/ndk/android_armeabi/bin/arm-linux-androideabi-gcc -- sysroot=/prod/ndk/android_armeabi/sysroot -std=gnu99
Static libraries: yes
Shared libraries: yes
Up to here it goes well, but when I run make, I receive the following error:
ismpf.cc: In function 'std::istream& operator>>(std::istream&, mpf_ptr)':
ismpf.cc:48:43: error: 'struct lconv' has no member named 'decimal_point'
make[2]: *** [ismpf.lo] Error 1
make[2]: Leaving directory `~/Downloads/gmp-5.1.1/cxx'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `~/Downloads/gmp-5.1.1'
make: *** [all] Error 2
So my first problem is there. Any ideas?
Just out of curiosity, I tried to rerun the same exact configure command as above but using sudo ahead of it. After a few seconds I receive the following:
configure: error: Oops, mp_limb_t is 64 bits, but the assembler code
in this configuration expects 32 bits.
There is the second (and really weird problem that arises).
Just out of curiosity again, I tried to reboot and clear all the variables we created, and simply run the command that the GMP manual recommends:
./configure --prefix=/location/ --enable-cxx --host=arm-linux-androideabi
The ./configure runs, the make goes well, but all 9/9 tests fail when I do make check. Can anybody point me in the right direction with these errors, or about how to try and correctly compile GMP for android? Any help is immensely appreciated.
Unsetting the CFLAGS env var solved the problem for me.

Categories

Resources