summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIikka Eklund <iikka.eklund@qt.io>2022-05-12 12:10:49 +0300
committerIikka Eklund <iikka.eklund@qt.io>2022-05-19 08:53:33 +0300
commitf3271452d495d4cdd428c180aa53c9558d2ea1c6 (patch)
treec44ff6afadbff0c453317c5329ac0e4e6e328693
parente140a095d2bc592faeb2785120fe415556d6cba1 (diff)
Conan: Add recipe options for qtscxml and qtstatemachine
These features were not included as Conan recipe options so add those. These are translated: -o option1=True -> qt-configure-module -feature-option1 -o option1=False -> qt-configure-module -no-feature-option1 Task-number: QTBUG-100073 Pick-to: 6.3 Change-Id: Id28103d21668e90fc6b2c62451be8065482f0cab Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
-rw-r--r--conanfile_qtscxml.py15
-rw-r--r--conanfile_qtstatemachine.py16
2 files changed, 29 insertions, 2 deletions
diff --git a/conanfile_qtscxml.py b/conanfile_qtscxml.py
index 7539a79..781e2e1 100644
--- a/conanfile_qtscxml.py
+++ b/conanfile_qtscxml.py
@@ -1,6 +1,6 @@
#############################################################################
##
-## Copyright (C) 2021 The Qt Company Ltd.
+## Copyright (C) 2022 The Qt Company Ltd.
## Contact: https://www.qt.io/licensing/
##
## This file is part of the release tools of the Qt Toolkit.
@@ -29,6 +29,11 @@
from conans import ConanFile
import re
from pathlib import Path
+from typing import Dict, Any
+
+_qtscxml_features = [
+ "scxml-ecmascriptdatamodel",
+]
def _parse_qt_version_by_key(key: str) -> str:
@@ -54,3 +59,11 @@ class QtScxml(ConanFile):
exports_sources = "*", "!conan*.*"
python_requires = f"qt-conan-common/{_get_qt_minor_version()}@qt/everywhere"
python_requires_extend = "qt-conan-common.QtLeafModule"
+
+ def get_qt_leaf_module_options(self) -> Dict[str, Any]:
+ """Implements abstractmethod from qt-conan-common.QtLeafModule"""
+ return self._shared.convert_qt_features_to_conan_options(_qtscxml_features)
+
+ def get_qt_leaf_module_default_options(self) -> Dict[str, Any]:
+ """Implements abstractmethod from qt-conan-common.QtLeafModule"""
+ return self._shared.convert_qt_features_to_default_conan_options(_qtscxml_features)
diff --git a/conanfile_qtstatemachine.py b/conanfile_qtstatemachine.py
index ca8282c..8f1a50c 100644
--- a/conanfile_qtstatemachine.py
+++ b/conanfile_qtstatemachine.py
@@ -1,6 +1,6 @@
#############################################################################
##
-## Copyright (C) 2021 The Qt Company Ltd.
+## Copyright (C) 2022 The Qt Company Ltd.
## Contact: https://www.qt.io/licensing/
##
## This file is part of the release tools of the Qt Toolkit.
@@ -29,6 +29,12 @@
from conans import ConanFile
import re
from pathlib import Path
+from typing import Dict, Any
+
+_qtstatemachine_features = [
+ "statemachine",
+ "qeventtransition",
+]
def _parse_qt_version_by_key(key: str) -> str:
@@ -54,3 +60,11 @@ class QtStateMachine(ConanFile):
exports_sources = "*", "!conan*.*"
python_requires = f"qt-conan-common/{_get_qt_minor_version()}@qt/everywhere"
python_requires_extend = "qt-conan-common.QtLeafModule"
+
+ def get_qt_leaf_module_options(self) -> Dict[str, Any]:
+ """Implements abstractmethod from qt-conan-common.QtLeafModule"""
+ return self._shared.convert_qt_features_to_conan_options(_qtstatemachine_features)
+
+ def get_qt_leaf_module_default_options(self) -> Dict[str, Any]:
+ """Implements abstractmethod from qt-conan-common.QtLeafModule"""
+ return self._shared.convert_qt_features_to_default_conan_options(_qtstatemachine_features)