I am new to Cmake and I am looking for some ideas (what to read, where
to search) on how to solve the following problem.


Our project has the following structure:

root/applications (Applications by different users)
     applications/app1
     applications/app2
     applications/...

root/kernel (common kernel source files)

root/libraries (external libraries)


Each application has some source files and uses the common source files
from the kernel directory which is *not* a subdirectory. In a first
attempt, I wrote one CMakeLists.txt file on the kernel directory which
has a list of all kernel source files. Each application/appX directory
has its own CMakeLists.txt file which includes the kernel sources via:

ADD_SUBDIRECTORY (${APPX_SOURCE_DIR}/../..
${CMAKE_CURRENT_BINARY_DIR}/kernel)

Unfortunately, the variables defined in the kernel's CMakeLists.txt file
are not available from within the application's CMakeLists.txt file.


Any help on this problem will be appreciated.

Best regards,
Matthias Moeller

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to