mirror of
https://github.com/cuberite/polarssl.git
synced 2025-09-29 16:32:32 -04:00
Merge pull request #6086 from paul-elliott-arm/fix_cmake_no_gen_files
Fix linking of generated files in cmake
This commit is contained in:
commit
ecc1031dbf
@ -131,7 +131,10 @@ function(link_to_source base_name)
|
|||||||
set(target "${CMAKE_CURRENT_SOURCE_DIR}/${base_name}")
|
set(target "${CMAKE_CURRENT_SOURCE_DIR}/${base_name}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT EXISTS ${link})
|
# Linking to non-existent file is not desirable. At best you will have a
|
||||||
|
# dangling link, but when building in tree, this can create a symbolic link
|
||||||
|
# to itself.
|
||||||
|
if (EXISTS ${target} AND NOT EXISTS ${link})
|
||||||
if (CMAKE_HOST_UNIX)
|
if (CMAKE_HOST_UNIX)
|
||||||
set(command ln -s ${target} ${link})
|
set(command ln -s ${target} ${link})
|
||||||
else()
|
else()
|
||||||
|
3
ChangeLog.d/fix_cmake_gen_files
Normal file
3
ChangeLog.d/fix_cmake_gen_files
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
Bugfix
|
||||||
|
* Fix an issue in releases with GEN_FILES turned off whereby missing
|
||||||
|
generated files could be turned into symlinks to themselves.
|
Loading…
x
Reference in New Issue
Block a user