In my cross-compile environment for an embedded platform, I need to set the
stack size for each executable. The linker flag to set the stack size is (for
example) "-Wl,-elf2flt='-s 20000'".
Is there an easy way to set this flag for every executable except one, for
which I set "-Wl,-elf2flt='-s 40000'"? Obviously I can call
Set_target_properties(<target> PROPERTIES LINK_FLAGS "-Wl,-elf2flt='-s
20000'")
on each target, but is there a mechanism to make this the default and then set
a different value on a single target?
If necessary, I suspect "-Wl,-elf2flt='-s 20000' -Wl,-elf2flt='-s 40000'" will
produce the correct result.
* can I avoid doing it like this?
* how can I be sure that the more specific option will follow the general one?
(Assume all the targets are added via add_subdirectory commands that are common
across multiple platforms, and that I'm adding platform-specific build rules in
the project CMakeLists.txt)
Thanks
--
Andrew
--
Powered by www.kitware.com
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Kitware offers various services to support the CMake community. For more
information on each offering, please visit:
CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake