Skip to content

Commit 6aa1f7e

Browse files
authored
Merge pull request #2376 from vgorloff/macos-to-android-crosscompile
Fixes Cmake error "file called with network path DESTINATION"
2 parents ac160ca + cc4a4a7 commit 6aa1f7e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

CoreFoundation/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -589,6 +589,11 @@ install(TARGETS
589589
CFURLSessionInterface
590590
DESTINATION
591591
"${CMAKE_INSTALL_FULL_LIBDIR}")
592+
593+
# Needed to avoid double slash "//" when CMAKE_INSTALL_PREFIX set to "/" and DESTDIR used to relocate whole installation.
594+
# Double slash raise CMake error "file called with network path DESTINATION //System/Library/Frameworks".
595+
string(REGEX REPLACE "/$" "" CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}")
596+
592597
install(DIRECTORY
593598
${CoreFoundation_FRAMEWORK_DIRECTORY}
594599
DESTINATION

0 commit comments

Comments
 (0)