Fix bad configure tests (#42756)
authorJan Vorlicek <janvorli@microsoft.com>
Tue, 29 Sep 2020 10:31:44 +0000 (12:31 +0200)
committerGitHub <noreply@github.com>
Tue, 29 Sep 2020 10:31:44 +0000 (12:31 +0200)
commit3d5351d690c06b70d5cad6bdf851d3f5a0c753a3
treea228e334cc8d6481e6cbdcdadd5a6045b717594d
parent855e2961ba70d3ed8b094d230aaf655adac2b76e
Fix bad configure tests (#42756)

There was an extra -c in the CMAKE_REQUIRED_FLAGS set for testing
HAVE_UNW_GET_ACCESSORS and HAVE_UNW_GET_SAVE_LOC that was breaking
build of coreclr under homebrew. The option was somehow making
these checks behave on ARM Linux, eveb though it is not clear to
me why, as it was just causing this option to be passed to the
compiler twice at different positions of the command line of
the cmake tests.
This change fixes it by using check_symbol_exists instead of
check_c_source_compiles, since just removing the duplicite -c
was resulting in the check failing on ARM / ARM64 Linux due
to a missing symbol from libunwind during linking.
src/coreclr/src/pal/src/configure.cmake