mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-05 21:31:08 -06:00
UseJava: Move helper scripts to subdirectory
Also, exclude them from the help module index.
This commit is contained in:
20
Modules/UseJava/Symlinks.cmake
Normal file
20
Modules/UseJava/Symlinks.cmake
Normal file
@@ -0,0 +1,20 @@
|
||||
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
|
||||
# file Copyright.txt or https://cmake.org/licensing for details.
|
||||
|
||||
# Helper script for UseJava.cmake
|
||||
|
||||
if (UNIX AND _JAVA_TARGET_OUTPUT_LINK)
|
||||
if (_JAVA_TARGET_OUTPUT_NAME)
|
||||
find_program(LN_EXECUTABLE
|
||||
NAMES
|
||||
ln
|
||||
)
|
||||
|
||||
execute_process(
|
||||
COMMAND ${LN_EXECUTABLE} -sf "${_JAVA_TARGET_OUTPUT_NAME}" "${_JAVA_TARGET_OUTPUT_LINK}"
|
||||
WORKING_DIRECTORY ${_JAVA_TARGET_DIR}
|
||||
)
|
||||
else ()
|
||||
message(SEND_ERROR "FATAL: Can't find _JAVA_TARGET_OUTPUT_NAME")
|
||||
endif ()
|
||||
endif ()
|
||||
Reference in New Issue
Block a user