Currently working on some random things on the Android OS source - which of course if I can get my little, “additions”, to work properly I’ll be releasing them. Though I was having a few problems getting the code to compile - so I figured I’d throw together this post just in case anyone else is having similar trouble.
Essentially in the post I was originally reading here, stated the following;
1 2 3
At the time of writing, the Android Dream build was broken. I needed to do the following to make it work: * Several (relatively minor) changes in the Dream audio driver code to fix compilation issues. * Copied libOmxCore.so to mydroid/out/target/product/dream/system/lib (this was a missing step in the Building for Dream documentation, and something that should be in the HTC provided script)
Well that wasn’t the problem I was getting though – the error I had been getting was actually:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
In file included from frameworks/base/libs/audioflinger/AudioResamplerCubic.cpp:20: system/core/include/cutils/log.h:68:1: warning: this is the location of the previous definition target thumb C++: libaudioflinger <= frameworks/base/libs/audioflinger/AudioFlinger.cpp make: *** No rule to make target out/target/product/dream/obj/lib/libaudio.so’, needed by out/target/product/dream/obj/SHARED_LIBRARIES/libaudioflinger_intermediates/LINKED/libaudioflinger.so’. Stop. … make: *** No rule to make target /tmp/dream/target/product/dream/obj/lib/libcamera.so', needed by /tmp/dream/target/product/dream/obj/SHARED_LIBRARIES/libcameraservice_intermediates/LINKED/libcameraservice.so’. Stop. … make: *** No rule to make target /tmp/dream/target/product/dream/obj/lib/libOmxCore.so', needed by /tmp/dream/target/product/dream/obj/SHARED_LIBRARIES/libopencorecommon_intermediates/LINKED/libopencorecommon.so’. Stop. … /media/other-storage/mydroid/prebuilt/linux-x86/toolchain/arm-eabi-4.2.1/bin/../lib/gcc/arm-eabi/4.2.1/../../../../arm-eabi/bin/ld: warning: librpc.so, needed by /tmp/dream/target/product/dream/obj/lib/libaudio.so, not found (try using -rpath or -rpath-link) … make: *** No rule to make target /tmp/dream/target/product/dream/system/lib/libaudio.so', needed by /tmp/dream/target/product/dream/system/lib/libaudioflinger.so’. Stop. … make: *** No rule to make target /tmp/dream/target/product/dream/system/lib/libcamera.so', needed by /tmp/dream/target/product/dream/system/lib/libcameraservice.so’. Stop. … make: *** No rule to make target /tmp/dream/target/product/dream/system/lib/libOmxCore.so', needed by /tmp/dream/target/product/dream/system/lib/libopencorecommon.so’. Stop.
(This list was compiled over multiple re-runs of make)
The simple fix was essentially what was stated in the original post, though it just took me a few minutes to figure this out. After running the locate command like a mad man and not finding anything on my developer machine, I finally reread everything and checked the device for the file – and there it was!
I just ended up throwing this into my extract-files.sh;
libaudio.so, libcameraservice.so, libcamera.so, libOmxCore.so, librpc.so then needed to be copied over to TARGET/dream/target/product/dream/obj/lib/ and also to the locked folder TARGET/dream/target/product/dream/system/lib/
Ta-da! After approximately 10 runs, it finally compiled for me… Hopefully this helps anyone who ran into the same problems as me.