Skip to content

Commit 7e06ec2

Browse files
committed
The rt library does not exist on osx.
1 parent 485216a commit 7e06ec2

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

cmake/modules/AddRootBench.cmake

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,10 @@ function(RB_ADD_GBENCHMARK benchmark)
4343
# FIXME: For better coherence we could restrict the libraries the test suite could link
4444
# against. For example, tests in Core should link only against libCore. This could be tricky
4545
# to implement because some ROOT components create more than one library.
46-
target_link_libraries(${benchmark} PUBLIC ${ARG_LIBRARIES} gbenchmark RBSupport rt)
46+
target_link_libraries(${benchmark} PUBLIC ${ARG_LIBRARIES} gbenchmark RBSupport)
47+
if (NOT APPLE)
48+
target_link_libraries(${benchmark} PUBLIC rt)
49+
endif()
4750
#ROOT_PATH_TO_STRING(mangled_name ${benchmark} PATH_SEPARATOR_REPLACEMENT "-")
4851
#ROOT_ADD_TEST(gbench${mangled_name}
4952
# COMMAND ${benchmark}

0 commit comments

Comments
 (0)