mirror of
https://github.com/slsdetectorgroup/aare.git
synced 2025-06-11 06:47:14 +02:00
Files and structure for python interface
This commit is contained in:
17
python/CMakeLists.txt
Normal file
17
python/CMakeLists.txt
Normal file
@ -0,0 +1,17 @@
|
||||
if(AARE_FETCH_PYBIND11)
|
||||
FetchContent_Declare(
|
||||
pybind11
|
||||
GIT_REPOSITORY https://github.com/pybind/pybind11
|
||||
GIT_TAG v2.11.0
|
||||
)
|
||||
FetchContent_MakeAvailable(pybind11)
|
||||
else()
|
||||
find_package(pybind11 2.11 REQUIRED)
|
||||
endif()
|
||||
|
||||
|
||||
pybind11_add_module(_aare src/module.cpp)
|
||||
set_target_properties(_aare PROPERTIES
|
||||
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}
|
||||
)
|
||||
target_link_libraries(_aare PRIVATE aare_core aare_compiler_flags)
|
9
python/src/module.cpp
Normal file
9
python/src/module.cpp
Normal file
@ -0,0 +1,9 @@
|
||||
|
||||
|
||||
|
||||
#include <pybind11/pybind11.h>
|
||||
|
||||
namespace py = pybind11;
|
||||
|
||||
PYBIND11_MODULE(_aare, m) {
|
||||
}
|
Reference in New Issue
Block a user