Skip to content

Commit

Permalink
make the dll_copy generated file a PRIVATE target_source
Browse files Browse the repository at this point in the history
This file is creating an error when trying to install as explained here https://stackoverflow.com/questions/60736689/cmake-target-sources-and-install.
  • Loading branch information
miguelibero authored Jun 12, 2024
1 parent c40a726 commit d951400
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions build-utils/cmake/shared_library.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,6 @@ function(target_copy_shared_libraries _TARGET)
VERBATIM)

# This allows to create a dependency with the command above, so command is executed again when target is built AND a DLL changed
target_sources(${_TARGET} PUBLIC "${CMAKE_CURRENT_BINARY_DIR}/${_TARGET}_dll_copy")
target_sources(${_TARGET} PRIVATE "${CMAKE_CURRENT_BINARY_DIR}/${_TARGET}_dll_copy")
endif()
endfunction()
endfunction()

0 comments on commit d951400

Please sign in to comment.