mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-07-31 00:03:07 +03:00
cmake: Only check for bounded attribute on OpenBSD
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
@ -370,6 +370,8 @@ int main(void) {
|
|||||||
return 0;
|
return 0;
|
||||||
}" HAVE_COMPILER__FUNCTION__)
|
}" HAVE_COMPILER__FUNCTION__)
|
||||||
|
|
||||||
|
# This is only available with OpenBSD's gcc implementation */
|
||||||
|
if (OPENBSD)
|
||||||
check_c_source_compiles("
|
check_c_source_compiles("
|
||||||
#define ARRAY_LEN 16
|
#define ARRAY_LEN 16
|
||||||
void test_attr(const unsigned char *k)
|
void test_attr(const unsigned char *k)
|
||||||
@ -378,6 +380,7 @@ void test_attr(const unsigned char *k)
|
|||||||
int main(void) {
|
int main(void) {
|
||||||
return 0;
|
return 0;
|
||||||
}" HAVE_GCC_BOUNDED_ATTRIBUTE)
|
}" HAVE_GCC_BOUNDED_ATTRIBUTE)
|
||||||
|
endif(OPENBSD)
|
||||||
|
|
||||||
# Stop treating warnings as errors
|
# Stop treating warnings as errors
|
||||||
unset(CMAKE_REQUIRED_FLAGS)
|
unset(CMAKE_REQUIRED_FLAGS)
|
||||||
|
Reference in New Issue
Block a user