-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathCMakeLists.txt
24 lines (18 loc) · 970 Bytes
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
CMAKE_MINIMUM_REQUIRED(VERSION 2.6 FATAL_ERROR)
PROJECT(wifi_scanner)
SET (CMAKE_MODULE_PATH "/usr/share/cmake/Modules")
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_SOURCE_DIR}/lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${PROJECT_SOURCE_DIR}/lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_SOURCE_DIR}/bin)
SET(CMAKE_BUILD_TYPE Release)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -Wall -std=gnu++0x -Os -fPIC")
FIND_LIBRARY( LIBIW_LIBRARY iw )
FIND_PATH(LIBIW_INCLUDE_DIR NAMES iwlib.h)
#SET( LIBIW_INCLUDE_DIR ${PROJECT_INCLUDE_DIR}/../wireless_tools )
#FIND_LIBRARY( LIBIW_LIBRARY iw ${LIBIW_SOURCE_DIR})
INCLUDE_DIRECTORIES( ${PROJECT_SOURCE_DIR}/include ${LIBIW_INCLUDE_DIR})
# General
ADD_LIBRARY(wifi_scanner SHARED ${PROJECT_SOURCE_DIR}/src/wifi_scanner.cpp)
TARGET_LINK_LIBRARIES( wifi_scanner ${LIBIW_LIBRARY} )
ADD_EXECUTABLE( test_wifi_scanner ${PROJECT_SOURCE_DIR}/src/test_wifi_scanner.cpp )
TARGET_LINK_LIBRARIES( test_wifi_scanner wifi_scanner)