mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-08-11 07:35:47 +00:00
The sample app "static_lib" is very important to Zephyr user, which demonstrate how to build and link a static lib. ISSM team wanted to integrate this app in their IDE for quark platforms. However they find the in "static_lib/hello_world/Makefile" BOARD is hardcoded as qemu_x86. This patch supports other BOARD passed from build command. I have verified this app working fine @Arduino101. Signed-off-by: Sharron LIU <sharron.liu@intel.com> |
||
---|---|---|
.. | ||
hello_world | ||
mylib | ||
Makefile | ||
prj.conf | ||
README | ||
testcase.ini |
Linking with a static library ############################# This sample shows how to link a static library to a Zephyr application. A sample library is also included. Read mylib/Makefile to discover how to use the Zephyr's toolchain to build a static library. If the library's source code is available, perhaps it could be more easier to integrate that source code to your application than creating the static library. Build instructions ================== 1. It is assumed that ZEPHYR_GCC_VARIANT and ZEPHYR_SDK_INSTALL_DIR variables are already set. See: https://www.zephyrproject.org/doc/getting_started/getting_started.html 2. source $ZEPHYR/zephyr-env.sh Where $ZEPHYR points to the directory that contains the zephyr repository. 3. make 4. make run