I'm building the recent Android release - JB422_100 - for SabreSD platform on Ubuntu 12.04.
The build fails with:
/obj/EXECUTABLES/wpa_supplicant_intermediates/src/drivers/driver_nl80211.o: in function wpa_driver_nl80211_init:external/wpa_supplicant_6/wpa_supplicant/src/drivers/driver_nl80211.c:1510: error: undefined reference to 'nl_handle_destroy'
collect2: ld returned 1 exit status
make: *** [out/target/product/sabresd_6dq/obj/EXECUTABLES/wpa_supplicant_intermediates/LINKED/wpa_supplicant] Error 1
If I totally delete external/wpa_supplicant_6, this error disappears, but this one emerges:
make: *** No rule to make target `out/target/product/sabresd_6dq/obj/SHARED_LIBRARIES/libwpa_client_intermediates/export_includes', needed by `out/target/product/sabresd_6dq/obj/SHARED_LIBRARIES/libandroid_runtime_intermediates/import_includes'. Stop.
There are additional problems that I have, somehow, figured out the solution.
Previously I have successfully built Android 4.0.4 and I did not have half these problems.
Any help will be greatly appreciated !
Solved! Go to Solution.
I have eventually figured out how Android JellyBean can be built on Ubuntu 12.04.
It all boils down to 2.5 to 3 issues:
1. To compile correctly external/mtd-utils, I had to copy locally liblzo2, libuuid for i386, and add the path to LOCAL_LDFLAGS in external/mtd-utils/mkfs.ubifs/Android.mk
2. This part is tricky ...
SabreSD board is not equipped with Wi-Fi, however if one merely removes "BOARD_WLAN_VENDOR := ATHEROS" line in device/fsl/sabresd_6dq/BoardConfig.mk, the Android build system will attempt to compile wpa_supplicant_6, which is so outdated, that it simply cannot be compiled these days.
Put
"WPA_SUPPLICANT_VERSION := VER_0_8_X"
"BOARD_WPA_SUPPLICANT_DRIVER := WEXT"
"BOARD_HOSTAPD_DRIVER := WEXT"
to build wpa_supplicant with no specific hardware support.
2.5 When building the whole system use "make" (as opposed to "make -j<num-cpus>"), because there are some unclear dependencies that will be broken by parallel compilation, but this is something I can currently live with.
...
Kinda so ...
Andrey, have you got the issue fixed? If yes, please click Correct Answer.
Thanks,
Yixing
I have eventually figured out how Android JellyBean can be built on Ubuntu 12.04.
It all boils down to 2.5 to 3 issues:
1. To compile correctly external/mtd-utils, I had to copy locally liblzo2, libuuid for i386, and add the path to LOCAL_LDFLAGS in external/mtd-utils/mkfs.ubifs/Android.mk
2. This part is tricky ...
SabreSD board is not equipped with Wi-Fi, however if one merely removes "BOARD_WLAN_VENDOR := ATHEROS" line in device/fsl/sabresd_6dq/BoardConfig.mk, the Android build system will attempt to compile wpa_supplicant_6, which is so outdated, that it simply cannot be compiled these days.
Put
"WPA_SUPPLICANT_VERSION := VER_0_8_X"
"BOARD_WPA_SUPPLICANT_DRIVER := WEXT"
"BOARD_HOSTAPD_DRIVER := WEXT"
to build wpa_supplicant with no specific hardware support.
2.5 When building the whole system use "make" (as opposed to "make -j<num-cpus>"), because there are some unclear dependencies that will be broken by parallel compilation, but this is something I can currently live with.
...
Kinda so ...
Hi Andrey,
Did you follow section 2.1 "Set Up Your Computer" in the Android User Guide? Here are two steps you need to do correctly:
BR,
Jack
Try to build using an Ubuntu 10.04 box. Newer Ubuntu versions have not been fully tested.
No problem. I have built a 10.04 virtual machine. Now it fails with:
external/mtd-utils/mkfs.ubifs/mkfs.ubifs.c: In function ‘write_super’:
external/mtd-utils/mkfs.ubifs/mkfs.ubifs.c:1902: warning: implicit declaration of function ‘uuid_generate_random’
external/mtd-utils/mkfs.ubifs/mkfs.ubifs.c:1906: warning: implicit declaration of function ‘uuid_unparse_upper’
make: *** [out/host/linux-x86/obj/EXECUTABLES/mkfs.ubifs_intermediates/mkfs.ubifs.o] Error 1
Andrey,
Try adding these packages..
sudo apt-get install liblzo2-dev uuid-dev
Thanks, now it fails with
/mnt/host/Work/jb-4-imx6/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.6/bin/../lib/gcc/arm-linux-androideabi/4.6.x-google/../../../../arm-linux-androideabi/bin/ld: out/target/product/sabresd_6dq/obj/EXECUTABLES/wpa_supplicant_intermediates/src/drivers/driver_nl80211.o: in function wpa_driver_nl80211_init:external/wpa_supplicant_6/wpa_supplicant/src/drivers/driver_nl80211.c:1435: error: undefined reference to 'nl_handle_alloc_cb'
/mnt/host/Work/jb-4-imx6/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.6/bin/../lib/gcc/arm-linux-androideabi/4.6.x-google/../../../../arm-linux-androideabi/bin/ld: out/target/product/sabresd_6dq/obj/EXECUTABLES/wpa_supplicant_intermediates/src/drivers/driver_nl80211.o: in function wpa_driver_nl80211_init:external/wpa_supplicant_6/wpa_supplicant/src/drivers/driver_nl80211.c:1510: error: undefined reference to 'nl_handle_destroy'
collect2: ld returned 1 exit status
make: *** [out/target/product/sabresd_6dq/obj/EXECUTABLES/wpa_supplicant_intermediates/LINKED/wpa_supplicant] Error 1
(*)
Libnl is installed ...