diff options
author | Andreas Schneider <asn@samba.org> | 2016-10-20 10:35:50 +0200 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2016-10-20 11:21:59 +0200 |
commit | c989bbc9f6afaad9e4b26501d57d7acb1297d1cb (patch) | |
tree | e49594f2e76f19831d4b96826942963989d5383b /ConfigureChecks.cmake | |
parent | f5cddcd300b779131662519d56ae90fcebe459e1 (diff) | |
download | socket_wrapper-c989bbc9f6afaad9e4b26501d57d7acb1297d1cb.tar.gz socket_wrapper-c989bbc9f6afaad9e4b26501d57d7acb1297d1cb.tar.xz socket_wrapper-c989bbc9f6afaad9e4b26501d57d7acb1297d1cb.zip |
cmake: Check for constructor attribute
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'ConfigureChecks.cmake')
-rw-r--r-- | ConfigureChecks.cmake | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index 48455ef..71b34ce 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -172,6 +172,18 @@ int main(void) { }" HAVE_SOCKADDR_STORAGE) check_c_source_compiles(" +void test_constructor_attribute(void) __attribute__ ((constructor)); + +void test_constructor_attribute(void) +{ + return; +} + +int main(void) { + return 0; +}" HAVE_CONSTRUCTOR_ATTRIBUTE) + +check_c_source_compiles(" void test_destructor_attribute(void) __attribute__ ((destructor)); void test_destructor_attribute(void) |