Skip to content

Commit bbc983f

Browse files
committed
[win] Fix installation of root-config.bat and thisroot.ps1
1 parent 1446a30 commit bbc983f

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

cmake/modules/RootConfiguration.cmake

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -864,6 +864,7 @@ if(xproofd AND xrootd AND ssl AND XROOTD_NOMAIN)
864864
endif()
865865
if(WIN32)
866866
set(thisrootbat ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.bat)
867+
set(thisrootps1 ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.ps1)
867868
configure_file(${CMAKE_SOURCE_DIR}/config/thisroot.bat ${thisrootbat} @ONLY)
868869
configure_file(${CMAKE_SOURCE_DIR}/config/thisroot.ps1 ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.ps1 @ONLY)
869870
configure_file(${CMAKE_SOURCE_DIR}/config/root.rc.in ${CMAKE_BINARY_DIR}/etc/root.rc @ONLY)
@@ -883,6 +884,11 @@ set(mandir $ROOTSYS/man)
883884
configure_file(${CMAKE_SOURCE_DIR}/config/root-config.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root-config @ONLY NEWLINE_STYLE UNIX)
884885
if(MSVC)
885886
configure_file(${CMAKE_SOURCE_DIR}/config/root-config.bat.in ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root-config.bat @ONLY)
887+
install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/root-config.bat
888+
PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ
889+
GROUP_EXECUTE GROUP_READ
890+
WORLD_EXECUTE WORLD_READ
891+
DESTINATION ${CMAKE_INSTALL_BINDIR})
886892
endif()
887893

888894
install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.sh
@@ -891,6 +897,7 @@ install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/thisroot.sh
891897
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/setxrd.csh
892898
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/setxrd.sh
893899
${thisrootbat}
900+
${thisrootps1}
894901
PERMISSIONS OWNER_WRITE OWNER_READ
895902
GROUP_READ
896903
WORLD_READ

0 commit comments

Comments
 (0)