Resync
[CMakeLuaTailorHgBridge.git] / CMakeLua / Tests / BundleTest / BundleSubDir / CMakeLists.txt
blob322b2a7d2fa513570c14e84930372e9a7c6c9b82
1 ADD_CUSTOM_COMMAND(
2   OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/randomResourceFile.plist"
3   COMMAND /bin/cp
4   ARGS "${BundleTest_SOURCE_DIR}/randomResourceFile.plist.in"
5   "${CMAKE_CURRENT_BINARY_DIR}/randomResourceFile.plist")
7 SET_SOURCE_FILES_PROPERTIES(
8   "${CMAKE_CURRENT_BINARY_DIR}/randomResourceFile.plist"
9   PROPERTIES
10   MACOSX_PACKAGE_LOCATION Resources
11   )
13 SET_SOURCE_FILES_PROPERTIES(
14   "${BundleTest_SOURCE_DIR}/SomeRandomFile.txt"
15   "${BundleTest_SOURCE_DIR}/../../ChangeLog.txt"
16   PROPERTIES
17   MACOSX_PACKAGE_LOCATION MacOS
18   )
20 ADD_EXECUTABLE(SecondBundle
21   MACOSX_BUNDLE
22   "${BundleTest_SOURCE_DIR}/BundleTest.cxx"
23   "${BundleTest_SOURCE_DIR}/SomeRandomFile.txt"
24   "${BundleTest_SOURCE_DIR}/../../ChangeLog.txt"
25   "${CMAKE_CURRENT_BINARY_DIR}/randomResourceFile.plist"
26   )
27 TARGET_LINK_LIBRARIES(SecondBundle BundleTestLib)
29 # Test bundle installation.
30 INSTALL(TARGETS SecondBundle DESTINATION Applications)
32 # Test whether bundles respect the output name.  Since the library is
33 # installed into a location that uses this output name this will fail if the
34 # bundle does not respect the name.  Also the executable will not be found by
35 # the test driver if this does not work.
36 SET_TARGET_PROPERTIES(SecondBundle PROPERTIES OUTPUT_NAME SecondBundleExe)