nixpkgs-suyu/pkgs/development/libraries/libfido2/detect_apple_ld.patch
Artemis Tosini 099359afc7
libfido2: add macOS support
* pass IOKit to libfido2
* Add a patch so that cmake uses lld flags when linking
* Upgrade from 1.3.0 to 1.3.1 (based off #80781)
* Specify CMAKE_INSTALL_LIBDIR so that the demo binaries link
  correctly on macOS and libfido2.pc specifies correct arguments
2020-02-23 19:46:14 +00:00

11 lines
469 B
Diff

--- a/CMakeLists.txt 2020-02-19 17:21:59.000000000 +0000
+++ b/CMakeLists.txt 2020-02-23 15:57:34.241115306 +0000
@@ -296,7 +296,7 @@
endif()
# export list
-if(CMAKE_C_COMPILER_ID STREQUAL "AppleClang")
+if(APPLE AND CMAKE_C_COMPILER_ID STREQUAL "Clang" OR CMAKE_C_COMPILER_ID STREQUAL "AppleClang")
# clang + lld
string(CONCAT CMAKE_SHARED_LINKER_FLAGS ${CMAKE_SHARED_LINKER_FLAGS}
" -exported_symbols_list ${CMAKE_CURRENT_SOURCE_DIR}/src/export.llvm")