aboutsummaryrefslogtreecommitdiff
path: root/ConfigureChecks.cmake
diff options
context:
space:
mode:
authorAndreas Schneider <asn@cryptomilk.org>2018-08-16 17:45:56 +0200
committerAndreas Schneider <asn@cryptomilk.org>2018-08-16 17:45:56 +0200
commit4104d2fb917d7d31d9c1ecb91fde1370e517c318 (patch)
tree89240ebb8fff2e8a3e9ddfb9f166a92aef212d2b /ConfigureChecks.cmake
parent86d00f438ce92e40f72dcbcd60738a66fa8d5ae8 (diff)
downloadlibssh-4104d2fb917d7d31d9c1ecb91fde1370e517c318.tar.gz
libssh-4104d2fb917d7d31d9c1ecb91fde1370e517c318.tar.xz
libssh-4104d2fb917d7d31d9c1ecb91fde1370e517c318.zip
cmake: Correctly detect support for __bounded__ attribute
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Diffstat (limited to 'ConfigureChecks.cmake')
-rw-r--r--ConfigureChecks.cmake6
1 files changed, 3 insertions, 3 deletions
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake
index 650119cb..3d6f5662 100644
--- a/ConfigureChecks.cmake
+++ b/ConfigureChecks.cmake
@@ -354,9 +354,6 @@ int main(void) {
return 0;
}" HAVE_COMPILER__FUNCTION__)
-# Stop treating warnings as errors
-unset(CMAKE_REQUIRED_FLAGS)
-
check_c_source_compiles("
#define ARRAY_LEN 16
void test_attr(const unsigned char *k)
@@ -366,6 +363,9 @@ int main(void) {
return 0;
}" HAVE_GCC_BOUNDED_ATTRIBUTE)
+# Stop treating warnings as errors
+unset(CMAKE_REQUIRED_FLAGS)
+
if (WITH_DEBUG_CRYPTO)
set(DEBUG_CRYPTO 1)
endif (WITH_DEBUG_CRYPTO)