Last active
May 18, 2018 17:56
-
-
Save awygle/60b40d69bf217e12289061d47ccc7d8e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake_minimum_required(VERSION 3.9) | |
project(libtrellis) | |
set(CMAKE_CXX_STANDARD 14) | |
set(CMAKE_CXX_FLAGS "-Wall -pedantic -Wextra -Werror") | |
set(CMAKE_DEFIN) | |
find_package(PythonInterp 3.6 REQUIRED) | |
find_package(PythonLibs 3.6 REQUIRED) | |
find_package(Boost REQUIRED COMPONENTS python-py36 filesystem thread) | |
include_directories(include/ ${Boost_INCLUDE_DIRS} ${PYTHON_INCLUDE_DIRS}) | |
aux_source_directory(include/ INCLUDE_FILES) | |
aux_source_directory(src/ SOURCE_FILES) | |
add_library(trellis SHARED ${INCLUDE_FILES} ${SOURCE_FILES}) | |
PYTHON_ADD_MODULE(pytrellis ${INCLUDE_FILES} ${SOURCE_FILES}) | |
target_compile_definitions(trellis PRIVATE FUZZ_SAFETY_CHECK=1) | |
target_compile_definitions(pytrellis PRIVATE FUZZ_SAFETY_CHECK=1) | |
target_link_libraries(trellis LINK_PUBLIC ${Boost_LIBRARIES} ${PYTHON_LIBRARIES}) | |
target_link_libraries(pytrellis LINK_PUBLIC ${Boost_LIBRARIES} ${PYTHON_LIBRARIES}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment