Skip to content

Commit 2a65a4f

Browse files
committed
Add option for including ITK shared libraries to wheel package
1 parent 46fdc2f commit 2a65a4f

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

CMakeLists.txt

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ if (NOT ${ITK_WRAP_PYTHON})
2222
)
2323
endif()
2424

25+
option(INCLUDE_ITK_SHARED_LIBRARIES "Include ITK shared libraries to wheel package" ON)
26+
2527
set(ITK_PACKAGE_VERSION "${ITK_VERSION_MAJOR}.${ITK_VERSION_MINOR}.${ITK_VERSION_PATCH}")
2628

2729
string(REGEX MATCH "^[2-3]\\.[0-9]+"
@@ -67,10 +69,15 @@ add_custom_target(pip_uninstall
6769
set(GLOB_COPY_FILES
6870
"*.py"
6971
"*.pyd"
70-
"*.dll"
71-
"*.so"
7272
)
7373

74+
if (INCLUDE_ITK_SHARED_LIBRARIES)
75+
list(APPEND GLOB_COPY_FILES
76+
"*.dll"
77+
"*.so"
78+
)
79+
endif()
80+
7481
configure_file(
7582
${CMAKE_SOURCE_DIR}/copy_files.py.in
7683
${TARGET_DIR}/copy_files.py

0 commit comments

Comments
 (0)