Compiling micro-eec, parallel jobs

It's cool to have a build_all.sh script that supports so many cross-compilers. I've one more small request.

If run from a tool like CMake, the make tool does not pick up that multiple cores can be used. So, say we define an external target:

ADD_CUSTOM_TARGET(micro_eec
    COMMAND chmod u+x build_all.sh WORKING_DIRECTORY ${NRF5_DIR}/external/micro-ecc
    COMMAND ${CMAKE_COMMAND} -E env "GNU_INSTALL_ROOT=${WORKSPACE_DIR}/tools/gcc_arm_none_eabi/bin/" ./build_all.sh WORKING_DIRECTORY ${NRF5_DIR}/external/micro-ecc
    COMMENT "Build micro-eec
)

This will lead to the following error messages:

make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf51_armgcc/armgcc/micro_ecc_lib_nrf51.a
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf51_iar/armgcc/micro_ecc_lib_nrf51.a
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf51_keil/armgcc/micro_ecc_lib_nrf51.lib
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf52hf_armgcc/armgcc/micro_ecc_lib_nrf52.a
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf52hf_iar/armgcc/micro_ecc_lib_nrf52.a
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf52hf_keil/armgcc/micro_ecc_lib_nrf52.lib
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf52nf_armgcc/armgcc/micro_ecc_lib_nrf52.a
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf52nf_iar/armgcc/micro_ecc_lib_nrf52.a
Done
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make rule.
Creating library: ../../nrf52nf_keil/armgcc/micro_ecc_lib_nrf52.lib
Done

Note that it's of course just a warning and by setting MAKEFILE=-j1 as additional environment variable it is "solved" as well. Just informing though about breaking parallel builds when run from a parent make process!

Parents
No Data
Reply Children
No Data