blob: 3b2028cf7bdab317b4689a3b533728dbb82797f3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
execute_process(COMMAND ${CMAKE_NM} -D ${TEST_LIBRARY_PATH}
RESULT_VARIABLE RESULT
OUTPUT_VARIABLE OUTPUT
ERROR_VARIABLE ERROR
)
if(NOT "${RESULT}" STREQUAL "0")
message(FATAL_ERROR "nm failed [${RESULT}] [${OUTPUT}] [${ERROR}]")
endif()
if(${OUTPUT} MATCHES "(Foo[^\\n]*bar|hidden_function)")
message(FATAL_ERROR
"Found ${CMAKE_MATCH_1} which should have been hidden [${OUTPUT}]")
endif()
|