summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2017-08-14 19:39:05 +0200
committerStanislaw Halik <sthalik@misaki.pl>2017-08-14 19:39:05 +0200
commitf2236891202f70b3b964b851ba98890fd7ca7a91 (patch)
tree7ee222358da431874f98992ba62d24d1b964789e
parent40e1fdd1331f93f2e69c01f3acf901fead48f143 (diff)
cmake: drop executable bit from installed normal files
-rw-r--r--cmake/opentrack-boilerplate.cmake10
-rw-r--r--cmake/opentrack-install.cmake17
-rw-r--r--tracker-hydra/CMakeLists.txt4
-rw-r--r--tracker-rs/CMakeLists.txt4
-rw-r--r--tracker-tobii-eyex/CMakeLists.txt6
5 files changed, 22 insertions, 19 deletions
diff --git a/cmake/opentrack-boilerplate.cmake b/cmake/opentrack-boilerplate.cmake
index 555e686d..70ded904 100644
--- a/cmake/opentrack-boilerplate.cmake
+++ b/cmake/opentrack-boilerplate.cmake
@@ -1,4 +1,6 @@
-set(opentrack-perms PERMISSIONS WORLD_READ WORLD_EXECUTE OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE)
+set(opentrack-perms-file WORLD_READ OWNER_WRITE OWNER_READ GROUP_READ)
+set(opentrack-perms-dir WORLD_READ WORLD_EXECUTE OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE)
+set(opentrack-perms-exec "${opentrack-perms-dir}")
set(new-hier-path "#pragma once
#ifndef OPENTRACK_NO_QT_PATH
@@ -104,7 +106,7 @@ include(CMakeParseArguments)
function(otr_install_pdb_current_project target)
if(MSVC)
- install(FILES "$<TARGET_PDB_FILE:${target}>" DESTINATION "${opentrack-hier-debug}" ${opentrack-perms})
+ install(FILES "$<TARGET_PDB_FILE:${target}>" DESTINATION "${opentrack-hier-debug}" PERMISSIONS ${opentrack-perms-file})
endif()
endfunction()
@@ -197,9 +199,9 @@ function(otr_module n_)
if(NOT arg_NO-INSTALL)
if(arg_BIN AND WIN32)
- install(TARGETS "${n}" RUNTIME DESTINATION . ${opentrack-perms})
+ install(TARGETS "${n}" RUNTIME DESTINATION . PERMISSIONS ${opentrack-perms-exec})
else()
- install(TARGETS "${n}" ${opentrack-hier-str} ${opentrack-perms})
+ install(TARGETS "${n}" ${opentrack-hier-str} PERMISSIONS ${opentrack-perms-exec})
endif()
set(opentrack_install-debug-info FALSE CACHE BOOL "Whether to build and install debug info at install time")
if(opentrack_install-debug-info)
diff --git a/cmake/opentrack-install.cmake b/cmake/opentrack-install.cmake
index 46649820..62de340d 100644
--- a/cmake/opentrack-install.cmake
+++ b/cmake/opentrack-install.cmake
@@ -1,15 +1,16 @@
-set(opentrack-perms_ WORLD_READ WORLD_EXECUTE OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE)
-set(opentrack-perms PERMISSIONS ${opentrack-perms_})
-
macro(otr_inst2 path)
- install(${ARGN} DESTINATION "${path}" ${opentrack-perms})
+ install(${ARGN} DESTINATION "${path}" PERMISSIONS ${opentrack-perms-file})
+endmacro()
+
+macro(otr_inst_exec path)
+ install(${ARGN} DESTINATION "${path}" PERMISSIONS ${opentrack-perms-file})
endmacro()
macro(otr_inst_dir path)
install(
DIRECTORY ${ARGN} DESTINATION "${path}"
- FILE_PERMISSIONS ${opentrack-perms_}
- DIRECTORY_PERMISSIONS ${opentrack-perms_}
+ FILE_PERMISSIONS ${opentrack-perms-file}
+ DIRECTORY_PERMISSIONS ${opentrack-perms-dir}
)
endmacro()
@@ -34,8 +35,8 @@ endif()
otr_inst2("${opentrack-doc-pfx}" FILES ${CMAKE_SOURCE_DIR}/README.md)
-otr_inst2("${opentrack-hier-pfx}" FILES "${CMAKE_SOURCE_DIR}/bin/freetrackclient.dll")
-otr_inst2("${opentrack-hier-pfx}" FILES
+otr_inst_exec("${opentrack-hier-pfx}" FILES "${CMAKE_SOURCE_DIR}/bin/freetrackclient.dll")
+otr_inst_exec("${opentrack-hier-pfx}" FILES
"${CMAKE_SOURCE_DIR}/bin/NPClient.dll"
"${CMAKE_SOURCE_DIR}/bin/NPClient64.dll"
"${CMAKE_SOURCE_DIR}/bin/TrackIR.exe")
diff --git a/tracker-hydra/CMakeLists.txt b/tracker-hydra/CMakeLists.txt
index afac8d89..af44135f 100644
--- a/tracker-hydra/CMakeLists.txt
+++ b/tracker-hydra/CMakeLists.txt
@@ -18,7 +18,7 @@ if(SDK_HYDRA)
set(under_dll _dll)
set(soext dll)
target_link_libraries(opentrack-tracker-hydra "${SDK_HYDRA}/${dir}/win32/release_dll/sixense.${ext}")
- install(FILES "${SDK_HYDRA}/bin/win32/release_dll/sixense.dll" DESTINATION ${opentrack-hier-pfx} ${opentrack-perms})
+ install(FILES "${SDK_HYDRA}/bin/win32/release_dll/sixense.dll" DESTINATION ${opentrack-hier-pfx} PERMISSIONS ${opentrack-perms-exec})
else()
if(APPLE)
set(dest .)
@@ -32,6 +32,6 @@ if(SDK_HYDRA)
set(plat linux)
endif()
target_link_libraries(opentrack-tracker-hydra "${SDK_HYDRA}/lib/${plat}${six4}/release${under-dll}/libsixense${six4}.${soext}")
- install(FILES "${SDK_HYDRA}/lib/${plat}${six4}/release${under-dll}/libsixense${six4}.${soext}" DESTINATION ${opentrack-hier-pfx} ${opentrack-perms})
+ install(FILES "${SDK_HYDRA}/lib/${plat}${six4}/release${under-dll}/libsixense${six4}.${soext}" DESTINATION ${opentrack-hier-pfx} PERMISSIONS ${opentrack-perms-exec})
endif()
endif()
diff --git a/tracker-rs/CMakeLists.txt b/tracker-rs/CMakeLists.txt
index e0e4d674..fc8eb75b 100644
--- a/tracker-rs/CMakeLists.txt
+++ b/tracker-rs/CMakeLists.txt
@@ -5,8 +5,8 @@ if(WIN32 AND SDK_REALSENSE)
add_definitions(-fpermissive -Wno-error) # for SDK headers
endif()
otr_module(tracker-rs)
- install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/intel_rs_sdk_runtime_websetup_10.0.26.0396.exe" DESTINATION ${opentrack-contrib-pfx} ${opentrack-perms})
- install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/RS_EULA.rtf" DESTINATION ${opentrack-contrib-pfx} ${opentrack-perms})
+ install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/intel_rs_sdk_runtime_websetup_10.0.26.0396.exe" DESTINATION ${opentrack-contrib-pfx} PERMISSIONS ${opentrack-perms-exec})
+ install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/RS_EULA.rtf" DESTINATION ${opentrack-contrib-pfx} PERMISSIONS ${opentrack-perms-file})
add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/rs_impl")
target_link_libraries(opentrack-tracker-rs opentrack-tracker-rs-impl)
endif()
diff --git a/tracker-tobii-eyex/CMakeLists.txt b/tracker-tobii-eyex/CMakeLists.txt
index 0e8d141c..6d133f1d 100644
--- a/tracker-tobii-eyex/CMakeLists.txt
+++ b/tracker-tobii-eyex/CMakeLists.txt
@@ -18,7 +18,7 @@ if(WIN32)
target_include_directories(opentrack-tracker-tobii-eyex SYSTEM PUBLIC ${tobii-incdir})
if(NOT "!${porked}" STREQUAL "!NO-INSTALL")
- install(FILES ${tobii-dll} DESTINATION ${opentrack-hier-pfx} ${opentrack-perms})
+ install(FILES ${tobii-dll} DESTINATION ${opentrack-hier-pfx} ${opentrack-perms-exec})
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows")
file(TO_CMAKE_PATH "$ENV{SystemRoot}" sysroot)
if (IS_DIRECTORY "${sysroot}/SysWOW64")
@@ -26,8 +26,8 @@ if(WIN32)
else()
set(src "${sysroot}/System32")
endif()
- install(FILES "${src}/msvcp110.dll" DESTINATION ${opentrack-hier-pfx} ${opentrack-perms})
- install(FILES "${src}/msvcr110.dll" DESTINATION ${opentrack-hier-pfx} ${opentrack-perms})
+ install(FILES "${src}/msvcp110.dll" DESTINATION ${opentrack-hier-pfx} PERMISSIONS ${opentrack-perms-exec})
+ install(FILES "${src}/msvcr110.dll" DESTINATION ${opentrack-hier-pfx} PERMISSIONS ${opentrack-perms-exec})
endif()
endif()
endif()