File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change 1+ cmake_minimum_required (VERSION 3.31)
2+ project (Python-for-ooRexx CXX)
3+
4+ # Configuration.
5+ set (oorexx_library $ENV{REXX_HOME} /api)
6+ set (python_version 3.12.7)
7+
8+ # Variables.
9+ set (target PyRexx)
10+
11+ # Target.
12+ add_library (${target} SHARED src/PyRexx.cpp)
13+
14+ # ooRexx library.
15+ target_include_directories (${target} PRIVATE ${oorexx_library} )
16+
17+ # Python library.
18+ find_package (Python3 ${python_version} EXACT REQUIRED COMPONENTS Development.Embed)
19+ target_link_libraries (${target} PRIVATE Python3::Python)
20+
21+ # Create distribution.
22+ add_custom_command (
23+ TARGET ${target}
24+ POST_BUILD
25+
26+ COMMAND ${CMAKE_COMMAND}
27+ ARGS -E copy $<TARGET_FILE:${target} > ${CMAKE_SOURCE_DIR} /dist/$<TARGET_FILE_NAME:${target} >
28+
29+ COMMAND ${CMAKE_COMMAND}
30+ ARGS -E copy ${CMAKE_SOURCE_DIR} /src/PyRexx.cls ${CMAKE_SOURCE_DIR} /src/pyrexx.py ${CMAKE_SOURCE_DIR} /dist
31+ )
You can’t perform that action at this time.
0 commit comments