@@ -13,6 +13,14 @@ include(UseColors)
13
13
#WArning this is horrible but is needed to avoid a typo in Pybind11...
14
14
SET (CMAKE_HOST_WIN32 OFF )
15
15
16
+ include (PyiglDependencies )
17
+
18
+ # NumpyEigen
19
+ set (CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${LIBIGL_EXTERNAL} /numpyeigen/cmake )
20
+ # Generate position independent code by default
21
+ set (CMAKE_POSITION_INDEPENDENT_CODE ON )
22
+ include (numpyeigen )
23
+
16
24
17
25
# Extra warnings
18
26
include (Warnings )
@@ -24,24 +32,6 @@ include(CXXFeatures)
24
32
# Sort projects inside the solution
25
33
set_property (GLOBAL PROPERTY USE_FOLDERS ON )
26
34
27
- # Generate position independent code by default
28
- set (CMAKE_POSITION_INDEPENDENT_CODE ON )
29
-
30
- if (${CMAKE_SYSTEM_NAME} MATCHES "Windows" )
31
- foreach (config ${CMAKE_CONFIGURATION_TYPES} )
32
- string (TOUPPER ${config} config )
33
- string (REPLACE /MD /MT CMAKE_C_FLAGS_${config} "${CMAKE_C_FLAGS_${config} }" )
34
- string (REPLACE /MD /MT CMAKE_CXX_FLAGS_${config} "${CMAKE_CXX_FLAGS_${config} }" )
35
- endforeach ()
36
- endif ()
37
-
38
- include (PyiglDependencies )
39
-
40
- # NumpyEigen
41
- set (CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${LIBIGL_EXTERNAL} /numpyeigen/cmake )
42
- set (CMAKE_POSITION_INDEPENDENT_CODE ON )
43
- include (numpyeigen )
44
-
45
35
46
36
# LibIGL
47
37
option (LIBIGL_USE_STATIC_LIBRARY "Use libigl as static library" OFF )
@@ -94,6 +84,16 @@ target_include_directories(pyigl PRIVATE "src/include")
94
84
# set_target_properties(pyigl PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${PROJECT_SOURCE_DIR}/igl")
95
85
96
86
87
+ if (${CMAKE_SYSTEM_NAME} MATCHES "Windows" )
88
+ foreach (config ${CMAKE_CONFIGURATION_TYPES} )
89
+ string (TOUPPER ${config} config )
90
+ string (REPLACE /MD /MT CMAKE_C_FLAGS_${config} "${CMAKE_C_FLAGS_${config} }" )
91
+ string (REPLACE /MD /MT CMAKE_CXX_FLAGS_${config} "${CMAKE_CXX_FLAGS_${config} }" )
92
+ endforeach ()
93
+ endif ()
94
+
95
+
96
+
97
97
if (${LIBIGL_PYTHON_TESTS} )
98
98
enable_testing ()
99
99
add_subdirectory (tests )
0 commit comments