forked from google/or-tools
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
18 lines (17 loc) · 866 Bytes
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
set_property(SOURCE linear_solver.i PROPERTY CPLUSPLUS ON)
set_property(SOURCE linear_solver.i PROPERTY SWIG_MODULE_NAME operations_research_linear_solver)
set_property(SOURCE linear_solver.i PROPERTY COMPILE_DEFINITIONS
${OR_TOOLS_COMPILE_DEFINITIONS} ABSL_MUST_USE_RESULT)
set_property(SOURCE linear_solver.i PROPERTY COMPILE_OPTIONS
-namespace ${OR_TOOLS_DOTNET}.LinearSolver
-dllimport google-ortools-native)
swig_add_library(dotnet_linear_solver
TYPE OBJECT
LANGUAGE csharp
OUTPUT_DIR ${PROJECT_BINARY_DIR}/dotnet/${PROJECT_NAME}/linear_solver
SOURCES linear_solver.i)
#target_include_directories(dotnet_linear_solver PRIVATE ${DOTNET_INCLUDE_DIRS})
set_target_properties(dotnet_linear_solver PROPERTIES
SWIG_USE_TARGET_INCLUDE_DIRECTORIES ON
POSITION_INDEPENDENT_CODE ON)
target_link_libraries(dotnet_linear_solver PRIVATE ortools::ortools)