summaryrefslogtreecommitdiff
path: root/ConfigureChecks.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'ConfigureChecks.cmake')
-rw-r--r--ConfigureChecks.cmake17
1 files changed, 14 insertions, 3 deletions
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake
index 07b0e80b11..1b453e46e2 100644
--- a/ConfigureChecks.cmake
+++ b/ConfigureChecks.cmake
@@ -76,7 +76,18 @@ check_function_exists("mkdtemp" HAVE_MKDTEMP)
check_function_exists("mkstemp" HAVE_MKSTEMP)
check_function_exists("sysconf" HAVE_SYSCONF)
-#Symbols
-include(CheckSymbolExists)
-check_symbol_exists(NL80211_CMD_SET_CHANNEL "linux/nl80211.h" HAVE_NL80211_CMD_SET_CHANNEL)
+#Symbols but NOT enums or types
+#include(CheckSymbolExists)
+#check_symbol_exists(NL80211_CMD_SET_CHANNEL "linux/nl80211.h" HAVE_NL80211_CMD_SET_CHANNEL)
+
+# Check for stuff that isn't testable via the tests above
+#include(CheckCSourceCompiles)
+check_c_source_compiles(
+ "#include <linux/nl80211.h>
+ int main() {
+ enum nl80211_commands x = NL80211_CMD_SET_CHANNEL;
+ }"
+ HAVE_NL80211_CMD_SET_CHANNEL
+)
+