-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
36 lines (29 loc) · 781 Bytes
/
CMakeLists.txt
File metadata and controls
36 lines (29 loc) · 781 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
cmake_minimum_required(VERSION 3.8)
project(simdjson)
add_compile_definitions(HAVE_SIMDJSON)
set(SOURCE_FILES
php_simdjson.h
simdjson.cpp
src/bindings.h
src/bindings.cpp
src/simdjson.h
src/simdjson.cpp
)
execute_process (
COMMAND php-config --include-dir
OUTPUT_VARIABLE PHP_SOURCE
)
string(REGEX REPLACE "\n$" "" PHP_SOURCE "${PHP_SOURCE}")
message("Using source directory: ${PHP_SOURCE}")
include_directories(
"${PHP_SOURCE}"
"${PHP_SOURCE}/main"
"${PHP_SOURCE}/Zend"
"${PHP_SOURCE}/TSRM"
"${PROJECT_SOURCE_DIR}"
)
add_custom_target(configure
COMMAND phpize && ./configure
DEPENDS ${SOURCE_FILES}
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR})
add_library(___ EXCLUDE_FROM_ALL ${SOURCE_FILES})