Fixed Xcode generator.

This commit is contained in:
XMRig 2020-12-15 22:47:22 +07:00
parent 633a92bff0
commit a934ba3079
No known key found for this signature in database
GPG key ID: 446A53638BE94409
2 changed files with 6 additions and 2 deletions

View file

@ -216,6 +216,6 @@ if (WIN32)
add_custom_command(TARGET ${CMAKE_PROJECT_NAME} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_SOURCE_DIR}/scripts/solo_mine_example.cmd" $<TARGET_FILE_DIR:${CMAKE_PROJECT_NAME}>)
endif()
if (CMAKE_CXX_COMPILER_ID MATCHES Clang AND CMAKE_BUILD_TYPE STREQUAL Release)
if (CMAKE_CXX_COMPILER_ID MATCHES Clang AND CMAKE_BUILD_TYPE STREQUAL Release AND NOT CMAKE_GENERATOR STREQUAL Xcode)
add_custom_command(TARGET ${PROJECT_NAME} POST_BUILD COMMAND ${CMAKE_STRIP} ${CMAKE_PROJECT_NAME})
endif()

View file

@ -61,7 +61,11 @@ if (WITH_RANDOMX)
src/crypto/randomx/jit_compiler_a64.cpp
)
# cheat because cmake and ccache hate each other
if (CMAKE_GENERATOR STREQUAL Xcode)
set_property(SOURCE src/crypto/randomx/jit_compiler_a64_static.S PROPERTY LANGUAGE ASM)
else()
set_property(SOURCE src/crypto/randomx/jit_compiler_a64_static.S PROPERTY LANGUAGE C)
endif()
else()
list(APPEND SOURCES_CRYPTO
src/crypto/randomx/jit_compiler_fallback.cpp