[翻译]OpenCORE编译指导 http://blog.chinaunix.net/uid-20457792-id-1944515.html 翻译:lyi#0x55.cn (2010-06-03) Q. How to build OpenCORE outside of Android? A. As part of the OpenCORE release, PacketVideo also provides it's internal build system that can be used to build OpenCORE outside of Android with the native linux toolchain. The following are the steps involved: NOTE 1: Assume is the directory where you have downloaded the OpenCORE codebase NOTE 2: The setup scripts are meant to be used in with the bash shell. cd /build_config/opencore_dynamic source setup.sh make -j This will build all the required libraries in /build_config/opencore_dynamic/build/installed_lib/linux and the executables in /build_config/opencore_dynamic/build/bin/linux 【问】怎么在Android系统之外编译OpenCORE? 【答】作为OpenCORE的一部分,PacketVideo公司提供了在Android系统之外、使用本地Linux工具链编译OpenCORE的内部编译机制。 下面是涉及到的几个步骤: 注1:是OpenCORE代码目录 注2:配置脚本 $ cd /build_config/opencore_dynamic $ source setup.sh $ make -j 这一步会编译出所有依赖的库以及相关的可执行文件,其中库文件存放于目录: /build_config/opencore_dynamic/build/installed_lib/linux 可执行文件存放于: /build_config/opencore_dynamic/build/bin/linux ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Q. How to build OpenCORE unit tests for Android emulator/device? A. export BUILD_PV_TEST_APPS=1 before building the SDK. 【问】怎么为Android模拟器或设备编译OpenCORE单元测试程序? 【答】在编译SDK之前设置BUILD_PV_TEST_APPS变量: $ export BUILD_PV_TEST_APPS=1 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Q. How to run the pvplayer engine unit tests? A. On Android emulator/device: adb push /engines/player/test/data/ /sdcard adb shell "cd /sdcard; pvplayer_engine_test " On host PC: cd /build_config/opencore_dynamic make run_pe_test TEST_ARGS="" To see a list of valid : make run_pe_test TEST_ARGS="-help" 【问】怎么运行pvplayer引擎的单元测试程序? 【答】在Android模拟器或设备上: $ adb push /engines/player/test/data/ /sdcard $ adb shell "cd /sdcard; pvplayer_engine_test " 在本地主机上: $ cd /build_config/opencore_dynamic $ make run_pe_test TEST_ARGS="" 可运行下列命令查看可用的: $ make run_pe_test TEST_ARGS="-help" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Q. How to build 2way for Android emulator/device? A. export BUILD_PV_2WAY=1 before building the SDK. 【问】怎么给模拟器或设备编译支持视频电话功能(2way)? 【答】在编译SDK前设置好BUILD_PV_2WAY变量: $ export BUILD_PV_2WAY=1 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Q. How to run the 2way engine unit tests? A. On Android emulator/device: adb push /engines/2way/sample_app/data/ /sdcard adb shell "cd /sdcard; pv2way_engine_test " On host PC: cd /build_config/opencore_dynamic make run_2way_test TEST_ARGS="" To see a list of valid : make run_2way_test TEST_ARGS="-help" 【问】怎么运行2way引擎的单元测试程序? 【答】在android模拟器或设备上运行: $ adb push /engines/2way/sample_app/data/ /sdcard $ adb shell "cd /sdcard; pv2way_engine_test " 在本地主机上: $ cd /build_config/opencore_dynamic $ make run_2way_test TEST_ARGS="" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Q. How to run the pvauthor engine unit tests? A. On Android emulator/device: adb push /engines/author/test/test_input/ /sdcard adb shell "cd /sdcard;test_pvauthorengine " On host PC: cd /build_config/opencore_dynamic make run_ae_test TEST_ARGS="" To see a list of valid : make run_ae_test TEST_ARGS="-help" 【问】怎么运行pvauthor引擎的单元测试程序? 【答】在android模拟器或设备上: $ adb push /engines/author/test/test_input/ /sdcard $ adb shell "cd /sdcard; test_pvauthorengine " 在本地主机上: $ cd /build_config/opencore_dynamic $ make run_ae_test TEST_ARGS=""