Building dependency project as static lib and exe.

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Building dependency project as static lib and exe.

mike lojkovic
I have a project that uses lua. cmake is able to build lua statically
and shared, without issue. (shared for debug static for releases on
Windows) The only issue is when I'm doing a release build I need to
also build the lua.exe, so I can process and embed my lua scripts in
the exe.

add_custom_command looks like it could be used to build the lua
project twice, but seems like I'd have to be overly specific repeating
things already implied in the lua project. Is there a means of telling
a subproject to compile itself from the main CMakeLists.txt?

I add libraries with add_subdirectory.

Powered by

Please keep messages on-topic and check the CMake FAQ at:

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support:
CMake Consulting:
CMake Training Courses:

Visit other Kitware open-source projects at

Follow this link to subscribe/unsubscribe: