Browse Source

python: provide a MagnumBindings::Python library for CMake superprojects.

The FindMagnumBindings so far worked for bindings as a subprojects due
to some weird magic, but as of 2bcc7b94d3
it no longer does, which is how it should be as no such target was
created by the subproject buildsystem at all until now.
next
Vladimír Vondruš 1 year ago
parent
commit
c8824470c9
  1. 7
      src/python/CMakeLists.txt

7
src/python/CMakeLists.txt

@ -86,3 +86,10 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/setup.py.cmake
${CMAKE_CURRENT_BINARY_DIR}/setup.py.in) ${CMAKE_CURRENT_BINARY_DIR}/setup.py.in)
file(GENERATE OUTPUT ${output_dir}/setup.py file(GENERATE OUTPUT ${output_dir}/setup.py
INPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py.in) INPUT ${CMAKE_CURRENT_BINARY_DIR}/setup.py.in)
# MagnumPythonBindings library and alias, just for superprojects to have
# something to link to get to the headers
add_library(MagnumPythonBindings INTERFACE)
set_target_properties(MagnumPythonBindings PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES ${PROJECT_SOURCE_DIR}/src)
add_library(MagnumBindings::Python ALIAS MagnumPythonBindings)

Loading…
Cancel
Save