Skip to content

Commit

Permalink
Simplify logic for Apple HAVE_SYSCTLBYNAME
Browse files Browse the repository at this point in the history
  • Loading branch information
gchatelet authored and arkivm committed Aug 27, 2023
1 parent 4b40565 commit 8b637b0
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,9 @@ target_link_libraries(cpu_features PUBLIC ${CMAKE_DL_LIBS})
target_include_directories(cpu_features
PUBLIC $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}/cpu_features>
)
if(PROCESSOR_IS_X86 OR PROCESSOR_IS_AARCH64)
if(APPLE)
target_compile_definitions(cpu_features PRIVATE HAVE_SYSCTLBYNAME)
endif()

if(APPLE)
target_compile_definitions(cpu_features PRIVATE HAVE_SYSCTLBYNAME)
endif()
add_library(CpuFeature::cpu_features ALIAS cpu_features)

Expand Down

0 comments on commit 8b637b0

Please sign in to comment.