-
Notifications
You must be signed in to change notification settings - Fork 667
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
28 lines (24 loc) · 829 Bytes
/
CMakeLists.txt
File metadata and controls
28 lines (24 loc) · 829 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
# Copyright Contributors to the OpenImageIO project.
# SPDX-License-Identifier: Apache-2.0
# https://github.com/AcademySoftwareFoundation/OpenImageIO
set (nanobind_srcs
py_oiio.cpp
py_paramvalue.cpp
py_roi.cpp
py_imagespec.cpp
py_typedesc.cpp)
set (nanobind_build_package_dir ${CMAKE_BINARY_DIR}/lib/python/nanobind/OpenImageIO)
file (MAKE_DIRECTORY ${nanobind_build_package_dir})
configure_file (__init__.py
${nanobind_build_package_dir}/__init__.py
COPYONLY)
setup_python_module_nanobind (
TARGET PyOpenImageIONanobind
MODULE _OpenImageIO
SOURCES ${nanobind_srcs}
LIBS OpenImageIO
)
if (OIIO_PYTHON_BINDINGS_BACKEND STREQUAL "nanobind")
install (FILES __init__.py
DESTINATION ${PYTHON_SITE_DIR} COMPONENT user)
endif ()