forked from AcademySoftwareFoundation/MaterialX
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
27 lines (22 loc) · 946 Bytes
/
CMakeLists.txt
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
file(GLOB pymaterialxgenglsl_source "${CMAKE_CURRENT_SOURCE_DIR}/*.cpp")
file(GLOB pymaterialxgenglsl_headers "${CMAKE_CURRENT_SOURCE_DIR}/*.h")
pybind11_add_module(PyMaterialXGenGlsl SHARED ${PYBIND11_MODULE_FLAGS} ${pymaterialxgenglsl_source} ${pymaterialxgenglsl_headers})
if(APPLE)
set_target_properties(PyMaterialXGenGlsl PROPERTIES CXX_VISIBILITY_PRESET "default")
endif()
set_target_properties(
PyMaterialXGenGlsl
PROPERTIES
OUTPUT_NAME PyMaterialXGenGlsl
COMPILE_FLAGS "${EXTERNAL_COMPILE_FLAGS}"
LINK_FLAGS "${EXTERNAL_LINK_FLAGS}"
VERSION "${MATERIALX_LIBRARY_VERSION}"
SOVERSION "${MATERIALX_MAJOR_VERSION}"
DEBUG_POSTFIX "${MATERIALX_PYTHON_DEBUG_POSTFIX}")
target_link_libraries(
PyMaterialXGenGlsl
PUBLIC PyMaterialXGenShader
MaterialXGenGlsl
PRIVATE ${CMAKE_DL_LIBS})
install(TARGETS PyMaterialXGenGlsl
DESTINATION "${CMAKE_INSTALL_PREFIX}/python/MaterialX")