aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt14
1 files changed, 11 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9712cca..ba802f4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,13 +1,21 @@
cmake_minimum_required(VERSION 3.6)
-project(wifi_triangulator)
+include(CheckIncludeFiles)
+include(CheckLibraryExists)
+project(wifi-triangulator)
set(CMAKE_CXX_STANDARD 14)
+check_include_files("pcap.h" HAVE_PCAP_H)
+
+if(NOT HAVE_PCAP_H)
+ message(FATAL_ERROR "Missing pcap.h. You should probably install libpcap-dev or similar.")
+endif()
+
set(SOURCE_FILES main.cpp
third-party/radiotap-library/radiotap.c
third-party/radiotap-library/radiotap.h
third-party/radiotap-library/radiotap_iter.h
third-party/radiotap-library/platform.h)
-add_executable(wifi_triangulator ${SOURCE_FILES})
+add_executable(wifi-triangulator ${SOURCE_FILES})
-target_link_libraries(wifi_triangulator PUBLIC pcap)
+target_link_libraries(wifi-triangulator PUBLIC pcap)