Skip to content

Commit cc6beaa

Browse files
authored
cmake: set CC flag on macOS only for depends build
1 parent 4b93636 commit cc6beaa

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,9 @@ endif()
6969
if(APPLE)
7070
if(DEFINED scala_BINARY_DIR AND NOT "${scala_BINARY_DIR}" STREQUAL "")
7171
if(DEFINED CMAKE_OSX_SYSROOT)
72-
set(CROSS_CC "CC=clang --target=${CLANG_TARGET} --sysroot=${CMAKE_OSX_SYSROOT}")
72+
if(DEPENDS)
73+
set(CROSS_CC "CC=clang --target=${CLANG_TARGET} --sysroot=${CMAKE_OSX_SYSROOT}")
74+
endif()
7375
endif()
7476
endif()
7577
endif()

0 commit comments

Comments
 (0)