Debian Codegraph @

third_party/getopt/CMakeLists.txt

raw
1 cmake_minimum_required(VERSION 3.10)
2 project(getopt)
3
4 set(TARGET getopt)
5 set(PUBLIC_HDR_DIR include)
6
7 # ==================================================================================================
8 # Sources and headers
9 # ==================================================================================================
10 set(PUBLIC_HDRS include/getopt/getopt.h)
11 set(PRIVATE_HDRS include/getopt/getopt.h)
12
13 set(SRCS
14 src/getopt.c
15 src/getopt_long.c)
16
17 # ==================================================================================================
18 # Include and target definitions
19 # ==================================================================================================
20 include_directories(${PUBLIC_HDR_DIR})
21
22 add_library(${TARGET} STATIC ${PRIVATE_HDRS} ${PUBLIC_HDRS} ${SRCS})
23 target_include_directories (${TARGET} PUBLIC ${PUBLIC_HDR_DIR})