diff options
author | Andreas Schneider <asn@cryptomilk.org> | 2018-11-02 16:42:06 +0100 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2018-11-02 16:42:06 +0100 |
commit | 86dabfe7e424609719500a51b4bd4c1bc038bcf7 (patch) | |
tree | e8226f882d2deb5bcb886bc105bb717011ceb80d | |
parent | 1650d8178e482b2824a3e0eff9b6bba837f45749 (diff) | |
download | libssh-86dabfe7e424609719500a51b4bd4c1bc038bcf7.tar.gz libssh-86dabfe7e424609719500a51b4bd4c1bc038bcf7.tar.xz libssh-86dabfe7e424609719500a51b4bd4c1bc038bcf7.zip |
cmake: Only check for bounded attribute on OpenBSD
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
-rw-r--r-- | ConfigureChecks.cmake | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index 913cebd7..3530b579 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -370,6 +370,8 @@ int main(void) { return 0; }" HAVE_COMPILER__FUNCTION__) +# This is only available with OpenBSD's gcc implementation */ +if (OPENBSD) check_c_source_compiles(" #define ARRAY_LEN 16 void test_attr(const unsigned char *k) @@ -378,6 +380,7 @@ void test_attr(const unsigned char *k) int main(void) { return 0; }" HAVE_GCC_BOUNDED_ATTRIBUTE) +endif(OPENBSD) # Stop treating warnings as errors unset(CMAKE_REQUIRED_FLAGS) |