[cmake-commits] david.cole committed CMakeLists.txt 1.6 1.7
cmake-commits at cmake.org
cmake-commits at cmake.org
Wed Oct 10 11:06:17 EDT 2007
Update of /cvsroot/CMake/CMake/Tests/Framework
In directory public:/mounts/ram/cvs-serv11766/Tests/Framework
Modified Files:
CMakeLists.txt
Log Message:
ENH: Finish up the Framework creation code restructuring. Frameworks build and install now. More work needed on the packaging step. See Tests/Framework for example use.
Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Tests/Framework/CMakeLists.txt,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- CMakeLists.txt 24 Aug 2007 17:30:41 -0000 1.6
+++ CMakeLists.txt 10 Oct 2007 15:06:15 -0000 1.7
@@ -10,26 +10,34 @@
fooBoth.h
test.lua
)
+
+set(foo_ver ver4)
+
set_target_properties(foo PROPERTIES
FRAMEWORK TRUE
- FRAMEWORK_VERSION ver3
-)
-# fooNeither.h is marked neither public nor private...
-# fooBoth.h is marked both public and private... (private wins...)
-set_source_files_properties(foo.h foo2.h fooPublic.h fooBoth.h PROPERTIES
- FRAMEWORK_PUBLIC_HEADER TRUE
-)
-set_source_files_properties(fooPrivate.h fooBoth.h PROPERTIES
- FRAMEWORK_PRIVATE_HEADER TRUE
-)
-set_source_files_properties(test.lua PROPERTIES
- FRAMEWORK_RESOURCE TRUE
+ FRAMEWORK_VERSION ${foo_ver}
+ PRIVATE_HEADER "fooPrivate.h;fooBoth.h"
+ PUBLIC_HEADER "foo.h;foo2.h;fooPublic.h;fooBoth.h"
+ RESOURCE "test.lua"
)
+# fooBoth.h is listed as both public and private... (private wins...)
+# fooNeither.h is listed as neither public nor private...
+
add_executable(bar bar.cxx)
target_link_libraries(bar foo)
install(TARGETS foo bar
- RUNTIME DESTINATION /Applications/CMakeTestsFramework/bin
- FRAMEWORK DESTINATION /Library/Frameworks
+ RUNTIME DESTINATION Applications/CMakeTestsFramework/bin
+ FRAMEWORK DESTINATION Library/Frameworks
+
+ # These are ignored on the Mac... and things are automatically placed in
+ # their appropriate Framework sub-folder at build time. (And then the built
+ # framework is copied recursively when it is installed.)
+ PRIVATE_HEADER DESTINATION share/foo-${foo_ver}/PrivateHeaders
+ PUBLIC_HEADER DESTINATION include/foo-${foo_ver}
+ RESOURCE DESTINATION share/foo-${foo_ver}/Resources
+ # But they are required to be present so that installing a framework on other
+ # other platforms will install the pieces of the framework without having to
+ # duplicate install rules for the pieces of the framework.
)
# Make a static library and apply the framework properties to it to verify
@@ -53,3 +61,5 @@
)
add_executable(barStatic bar.cxx)
target_link_libraries(barStatic fooStatic)
+
+include(CPack)
More information about the Cmake-commits
mailing list