aboutsummaryrefslogtreecommitdiffstats
path: root/Samples/OculusWorldDemo/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'Samples/OculusWorldDemo/CMakeLists.txt')
-rw-r--r--Samples/OculusWorldDemo/CMakeLists.txt42
1 files changed, 42 insertions, 0 deletions
diff --git a/Samples/OculusWorldDemo/CMakeLists.txt b/Samples/OculusWorldDemo/CMakeLists.txt
new file mode 100644
index 0000000..9d8c6b1
--- /dev/null
+++ b/Samples/OculusWorldDemo/CMakeLists.txt
@@ -0,0 +1,42 @@
+project(OculusWorldDemo)
+
+set(EXTRA_LIBS
+ OculusVR
+ CommonSrc
+ TinyXML2
+)
+
+set(SOURCE_FILES
+ OculusWorldDemo.cpp
+ Player.cpp
+)
+
+file(GLOB_RECURSE ASSET_FILES Assets/Tuscany/*)
+
+if (WIN32)
+
+ add_executable(OculusWorldDemo WIN32 ${SOURCE_FILES})
+
+ add_custom_command(TARGET OculusWorldDemo POST_BUILD
+ COMMAND ${CMAKE_COMMAND} -E copy_directory
+ ${CMAKE_CURRENT_SOURCE_DIR}/Assets ${CMAKE_CURRENT_BINARY_DIR}/Assets)
+
+elseif (APPLE)
+
+ list(APPEND SOURCE_FILES ${ASSET_FILES})
+
+ set_source_files_properties(${ASSET_FILES} PROPERTIES MACOSX_PACKAGE_LOCATION Resources/Assets/Tuscany)
+
+ add_executable(OculusWorldDemo MACOSX_BUNDLE ${SOURCE_FILES})
+
+else()
+
+ add_executable(OculusWorldDemo ${SOURCE_FILES})
+
+ add_custom_command(TARGET OculusWorldDemo POST_BUILD
+ COMMAND ${CMAKE_COMMAND} -E copy_directory
+ ${CMAKE_CURRENT_SOURCE_DIR}/Assets ${CMAKE_CURRENT_BINARY_DIR}/Assets)
+
+endif()
+
+target_link_libraries(OculusWorldDemo ${EXTRA_LIBS})