Skip to content

Commit 97df3b0

Browse files
committed
Add PythonQt_Wrap_QtAll build option
Currently xmlpattern wrappers are not built even if PythonQt_Wrap_QtAll is set to ON. Indeed, the wrappers failed to build on any of the supported Qt version.
1 parent 81a2cfc commit 97df3b0

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

CMakeLists.txt

+12-1
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,21 @@ add_definitions(-DPYTHONQT_USE_RELEASE_PYTHON_FALLBACK)
1414
#-----------------------------------------------------------------------------
1515
# Build options
1616

17-
foreach(qtlib core gui network opengl sql svg uitools webkit xml xmlpatterns)
17+
option(PythonQt_Wrap_QtAll "Make all Qt components available in python" OFF)
18+
19+
set(qtlibs core gui network opengl sql svg uitools webkit xml xmlpatterns)
20+
foreach(qtlib ${qtlibs})
1821
OPTION(PythonQt_Wrap_Qt${qtlib} "Make all of Qt${qtlib} available in python" OFF)
1922
endforeach()
2023

24+
# Force option if it applies
25+
if(PythonQt_Wrap_QtAll)
26+
list(REMOVE_ITEM qtlibs xmlpatterns) # xmlpatterns wrapper does *NOT* build at all :(
27+
foreach(qtlib ${qtlibs})
28+
set(PythonQt_Wrap_Qt${qtlib} ON CACHE BOOL "Make all of Qt${qtlib} available in python" FORCE)
29+
endforeach()
30+
endif()
31+
2132
option(PythonQt_DEBUG "Enable/Disable PythonQt debug output" OFF)
2233
if(PythonQt_DEBUG)
2334
add_definitions(-DPYTHONQT_DEBUG)

0 commit comments

Comments
 (0)