mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-07 22:30:13 -06:00
Apple: also specify sysroot for linking
Otherwise the compiler/linker will default to the wrong C++ runtime library.
This commit is contained in:
@@ -24,7 +24,7 @@ main.o: clean main.cpp
|
||||
pngtest: main.o
|
||||
@$(CMAKE_FOO) -DMODE=LINK >$(tmp)
|
||||
@foo="`cat $(tmp)`"; \
|
||||
printf '"%s" %s %s -o pngtest main.o %s\n' $(CMAKE_CXX_COMPILER) "$(CMAKE_CXX_FLAGS)" "$(LDFLAGS)" "$$foo" >$(tmp)
|
||||
printf '"%s" %s %s %s -o pngtest main.o %s\n' $(CMAKE_CXX_COMPILER) "$(CMAKE_CXX_FLAGS)" "$(__EXTRA_OSX_SYSROOT_FLAGS)" "$(LDFLAGS)" "$$foo" >$(tmp)
|
||||
@cat $(tmp)
|
||||
@sh $(tmp)
|
||||
@rm -f $(tmp)
|
||||
|
||||
Reference in New Issue
Block a user