emulator: ERROR: You did not specify a virtual device name, and the system
directory could not be found.
If you are an Android SDK user, please use '@<name>' or '-avd <name>'
to start a given virtual device (see -help-avd for details).
Otherwise, follow the instructions in -help-disk-images to start the emulator
How to build Module for Platform
- It is only for modules are needed to using Android build system.
- Please check its own install information under its folder for other module.
[Step to build]
1. Get android open source.
: version info - Android 4.4
( Download site : http://source.android.com )
2. Copy module that you want to build - to original android open source
If same module exist in android open source, you should replace it. (no overwrite)
# It is possible to build all modules at once.
3. You should add module name to 'PRODUCT_PACKAGES' in 'build\target\product\core.mk' as following case.
case 1) e2fsprog : should add 'e2fsck' to PRODUCT_PACKAGES
case 2) blkid : should add 'libkeyutils' to PRODUCT_PACKAGES
case 3) libhyphenation : should add 'libkeyutils' to PRODUCT_PACKAGES
case 4) KeyUtils : should add 'libkeyutils' to PRODUCT_PACKAGES
case 5) libexifa : should add 'libexifa' to PRODUCT_PACKAGES
case 6) libjpega : should add 'libjpega' to PRODUCT_PACKAGES
ex.) [build\target\product\core.mk] - add all module name for case 1 ~ 5 at once
PRODUCT_PACKAGES += \
e2fsck \
blkid \
libhyphenation \
libkeyutils \
libexifa \
libjpega \
ebtables
4. excute build command
./build_platform.sh
Note :
to build SBrowser (vendor/samsung/packages/apps/SBrowser),
please refer to Buildme.txt at the folder mentioned above.
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/blkmap64_ba.o: In function `ba_find_first_zero':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/blkmap64_ba.c:339: undefined reference to `ext2fs_test_bit64'
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/blkmap64_ba.c:390: undefined reference to `ext2fs_test_bit64'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/blkmap64_ba.o: In function `ba_test_bmap':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/blkmap64_ba.c:186: undefined reference to `ext2fs_test_bit64'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/blkmap64_ba.o: In function `ba_test_clear_bmap_extent':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/blkmap64_ba.c:281: undefined reference to `ext2fs_mem_is_zero'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/blkmap64_ba.o: In function `ba_unmark_bmap':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/blkmap64_ba.c:178: undefined reference to `ext2fs_clear_bit64'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/blkmap64_ba.o: In function `ba_mark_bmap':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/blkmap64_ba.c:170: undefined reference to `ext2fs_set_bit64'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/blkmap64_ba.o: In function `ba_resize_bmap':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/blkmap64_ba.c:141: undefined reference to `ext2fs_clear_bit64'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/gen_bitmap64.o: In function `ext2fs_convert_subcluster_bitmap':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/gen_bitmap64.c:735: undefined reference to `ext2fs_get_bitmap_granularity'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/gen_bitmap64.o: In function `ext2fs_find_first_zero_generic_bmap':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/gen_bitmap64.c:790: undefined reference to `ext2fs_find_first_zero_generic_bitmap'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/mmp.o: In function `ext2fs_mmp_read':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/mmp.c:57: undefined reference to `ext2fs_get_dio_alignment'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/mmp.o: In function `ext2fs_mmp_init':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/mmp.c:213: undefined reference to `ext2fs_alloc_block2'
collect2: ld returned 1 exit status
make: *** [out/host/linux-x86/obj/lib/libext2fs_host.so] 错误 1
make: *** 正在等待未完成的任务....
1 warning generated.
external/openssl/ssl/s2_clnt.c:1027:38: warning: unused parameter 'type' [-Wunused-parameter]
int ssl2_set_certificate(SSL *s, int type, int len, const unsigned char *data)
^
1 warning generated.
external/openssl/ssl/s2_lib.c:385:38: warning: unused parameter 'larg' [-Wunused-parameter]
long ssl2_ctrl(SSL *s, int cmd, long larg, void *parg)
^
external/openssl/ssl/s2_lib.c:385:50: warning: unused parameter 'parg' [-Wunused-parameter]
long ssl2_ctrl(SSL *s, int cmd, long larg, void *parg)
^
external/openssl/ssl/s2_lib.c:400:30: warning: unused parameter 's' [-Wunused-parameter]
long ssl2_callback_ctrl(SSL *s, int cmd, void (*fp)(void))
^
external/openssl/ssl/s2_lib.c:400:37: warning: unused parameter 'cmd' [-Wunused-parameter]
long ssl2_callback_ctrl(SSL *s, int cmd, void (*fp)(void))
^
external/openssl/ssl/s2_lib.c:400:49: warning: unused parameter 'fp' [-Wunused-parameter]
long ssl2_callback_ctrl(SSL *s, int cmd, void (*fp)(void))
^
external/openssl/ssl/s2_lib.c:405:29: warning: unused parameter 'ctx' [-Wunused-parameter]
long ssl2_ctx_ctrl(SSL_CTX *ctx, int cmd, long larg, void *parg)
^
external/openssl/ssl/s2_lib.c:405:38: warning: unused parameter 'cmd' [-Wunused-parameter]
long ssl2_ctx_ctrl(SSL_CTX *ctx, int cmd, long larg, void *parg)
^
external/openssl/ssl/s2_lib.c:405:48: warning: unused parameter 'larg' [-Wunused-parameter]
long ssl2_ctx_ctrl(SSL_CTX *ctx, int cmd, long larg, void *parg)
^
external/openssl/ssl/s2_lib.c:405:60: warning: unused parameter 'parg' [-Wunused-parameter]
long ssl2_ctx_ctrl(SSL_CTX *ctx, int cmd, long larg, void *parg)
^
external/openssl/ssl/s2_lib.c:410:38: warning: unused parameter 'ctx' [-Wunused-parameter]
long ssl2_ctx_callback_ctrl(SSL_CTX *ctx, int cmd, void (*fp)(void))
^
external/openssl/ssl/s2_lib.c:410:47: warning: unused parameter 'cmd' [-Wunused-parameter]
long ssl2_ctx_callback_ctrl(SSL_CTX *ctx, int cmd, void (*fp)(void))
^
external/openssl/ssl/s2_lib.c:410:59: warning: unused parameter 'fp' [-Wunused-parameter]
long ssl2_ctx_callback_ctrl(SSL_CTX *ctx, int cmd, void (*fp)(void))
^
12 warnings generated.
1 warning generated.
make: *** wait: 没有子进程。 停止。
senrsl@senrsl-ubuntu:~/android/source/WORKING_DIRECTORY$
然后把之前的core.mk第二部分替换成README里的,报错
12345678
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/mmp.c:57: undefined reference to `ext2fs_get_dio_alignment'
out/host/linux-x86/obj/SHARED_LIBRARIES/libext2fs_host_intermediates/mmp.o: In function `ext2fs_mmp_init':
/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/mmp.c:213: undefined reference to `ext2fs_alloc_block2'
collect2: ld returned 1 exit status
make: *** [out/host/linux-x86/obj/lib/libext2fs_host.so] 错误 1
make: *** 正在等待未完成的任务....
Processing target/product/generic/dex_bootjars/system/framework/core.jar
Done!
然后把core.mk里第二部分全都删掉,报的错还是上面那个。
恢复下core.mk重来,
报1:报错external/webkit/Source/WebCore/make-hash-tools.pl line 23.,core.mk砍掉 libwebcore \ 代码砍掉external/webkit.
报2:/home/senrsl/android/source/WORKING_DIRECTORY/external/e2fsprogs/lib/ext2fs/mmp.c:213: undefined reference to `ext2fs_alloc_block2',external/e2fsprogs 代码换回原版。