diff --git a/CMakeLists.txt b/CMakeLists.txt index 2c56d51..bfb040c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -22,15 +22,16 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON) if (IOS) option(BUILD_SHARED_LIBS "This option forece build ${PROJECT_NAME} as a shared project with separated libraries as" OFF) -elseif() +else() option(BUILD_SHARED_LIBS "This option forece build ${PROJECT_NAME} as a shared project with separated libraries as" ON) endif() if (NOT QT_VERSION_MAJOR) find_package(QT NAMES Qt6 Qt5 COMPONENTS Core Test QUIET) + find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Core REQUIRED) + find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Test QUIET) endif() -find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Core Test QUIET) include(submodules/QuasarAppLib/CMake/QuasarApp.cmake) @@ -41,7 +42,7 @@ set(CQT_DEPLOYER_VERSION_SHORT_PREFIX "1.6") set(CQT_DEPLOYER_VERSION "${CQT_DEPLOYER_VERSION_SHORT_PREFIX}.${GIT_COMMIT_COUNT}.${GIT_COMMIT_HASH}") set(QIFW_VERSION "4.5") # rebuild for the 4.5.2 -option(CQT_DEPLOYER_TESTS "This option disables or enables tests of the ${PROJECT_NAME} project" ON) +option(CQT_DEPLOYER_TESTS "This option disables or enables tests of the ${PROJECT_NAME} project" ${Qt${QT_VERSION_MAJOR}Test_FOUND}) option(CQT_DEPLOYER_TOOL "This option disables or enables example app of the ${PROJECT_NAME} project" ON) if (ANDROID OR IOS OR NOT QT_VERSION_MAJOR OR QA_WASM32) diff --git a/tests/modules/modulesqt515.cpp b/tests/modules/modulesqt515.cpp index ab5ad0e..56d7719 100644 --- a/tests/modules/modulesqt515.cpp +++ b/tests/modules/modulesqt515.cpp @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2023-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #include "modulesqt515.h" ModulesQt515::ModulesQt515() diff --git a/tests/modules/modulesqt515.h b/tests/modules/modulesqt515.h index ba9e175..d284e3a 100644 --- a/tests/modules/modulesqt515.h +++ b/tests/modules/modulesqt515.h @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2018-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #ifndef MODULESQT515_H #define MODULESQT515_H diff --git a/tests/modules/modulesqt5152.cpp b/tests/modules/modulesqt5152.cpp index 812c41e..bf83b81 100644 --- a/tests/modules/modulesqt5152.cpp +++ b/tests/modules/modulesqt5152.cpp @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2023-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #include "modulesqt5152.h" ModulesQt5152::ModulesQt5152() diff --git a/tests/modules/modulesqt5152.h b/tests/modules/modulesqt5152.h index 9f82e47..f15df31 100644 --- a/tests/modules/modulesqt5152.h +++ b/tests/modules/modulesqt5152.h @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2018-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #ifndef MODULESQT5152_H #define MODULESQT5152_H diff --git a/tests/modules/modulesqt6_3.cpp b/tests/modules/modulesqt6_3.cpp index 38ce49e..1631f3e 100644 --- a/tests/modules/modulesqt6_3.cpp +++ b/tests/modules/modulesqt6_3.cpp @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2023-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #include "modulesqt6_3.h" ModulesQt63::ModulesQt63() { diff --git a/tests/modules/modulesqt6_3.h b/tests/modules/modulesqt6_3.h index 55547e6..f5074ba 100644 --- a/tests/modules/modulesqt6_3.h +++ b/tests/modules/modulesqt6_3.h @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2018-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #ifndef MODULESQT6_3_H #define MODULESQT6_3_H diff --git a/tests/modules/modulesqt6_4.cpp b/tests/modules/modulesqt6_4.cpp index ba42a8f..41eee60 100644 --- a/tests/modules/modulesqt6_4.cpp +++ b/tests/modules/modulesqt6_4.cpp @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2023-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #include "modulesqt6_4.h" ModulesQt6_4::ModulesQt6_4() diff --git a/tests/modules/modulesqt6_4.h b/tests/modules/modulesqt6_4.h index 77ea127..2477d56 100644 --- a/tests/modules/modulesqt6_4.h +++ b/tests/modules/modulesqt6_4.h @@ -1,3 +1,10 @@ +/* + * Copyright (C) 2018-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + #ifndef MODULESQT6_4_H #define MODULESQT6_4_H diff --git a/tests/modules/modulesqt6_5.cpp b/tests/modules/modulesqt6_5.cpp new file mode 100644 index 0000000..73cf6d6 --- /dev/null +++ b/tests/modules/modulesqt6_5.cpp @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2023-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + +#include "modulesqt6_5.h" + +ModulesQt6_5::ModulesQt6_5() +{ + +} + +QSet ModulesQt6_5::qmlLibs(const QString &distDir) const { + TestUtils utils; + auto Tree = ModulesQt6_4::qmlLibs(distDir); + + Tree -= utils.createTree( + { + "./" + distDir + "/qml/QtQml/libqmlplugin.so", + "./" + distDir + "/qml/QtQml/plugins.qmltypes" + } + ); + + Tree += utils.createTree( + { + "./" + distDir + "/qml/QtQml/Base/libqmlplugin.so", + "./" + distDir + "/qml/QtQml/Base/plugins.qmltypes", + "./" + distDir + "/qml/QtQml/Base/qmldir", + "./" + distDir + "/qml/QtQml/libqmlmetaplugin.so", + "./" + distDir + "/qml/QtQuick/Controls/Material/impl/RoundedElevationEffect.qml" + } + ); + + return Tree; +} + +QSet ModulesQt6_5::qmlVirtualKeyBoadrLibs(const QString &distDir) const { + + TestUtils utils; + + auto Tree = ModulesQt6_4::qmlVirtualKeyBoadrLibs(distDir); + return Tree; +} + +QSet ModulesQt6_5::qtWebEngine(const QString &distDir) const +{ + TestUtils utils; + + auto Tree = ModulesQt6_4::qtWebEngine(distDir); + return Tree; +} + +QSet ModulesQt6_5::qtWebEngineWidgets(const QString &distDir) const +{ + TestUtils utils; + + auto Tree = ModulesQt6_4::qtWebEngineWidgets(distDir); + + return Tree; +} diff --git a/tests/modules/modulesqt6_5.h b/tests/modules/modulesqt6_5.h new file mode 100644 index 0000000..0a5a3ad --- /dev/null +++ b/tests/modules/modulesqt6_5.h @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2023-2023 QuasarApp. + * Distributed under the lgplv3 software license, see the accompanying + * Everyone is permitted to copy and distribute verbatim copies + * of this license document, but changing it is not allowed. + */ + +#ifndef MODULESQT6_5_H +#define MODULESQT6_5_H + +#include "modulesqt6_4.h" + +class ModulesQt6_5: public ModulesQt6_4 +{ +public: + ModulesQt6_5(); + QSet qmlLibs(const QString &distDir = DISTRO_DIR) const override; + QSet qmlVirtualKeyBoadrLibs(const QString &distDir = DISTRO_DIR) const override; + QSet qtWebEngine(const QString &distDir = DISTRO_DIR) const override; + QSet qtWebEngineWidgets(const QString &distDir = DISTRO_DIR) const override; + + +}; + +#endif // MODULESQT6_5_H diff --git a/tests/units/modules.h b/tests/units/modules.h index c93030f..d0eabc3 100644 --- a/tests/units/modules.h +++ b/tests/units/modules.h @@ -11,7 +11,11 @@ #include #include -#if QT_VERSION >= QT_VERSION_CHECK(6, 4, 0) +#if QT_VERSION >= QT_VERSION_CHECK(6, 5, 0) + #include "modulesqt6_5.h" + class Modules: public ModulesQt6_5 + +#elif QT_VERSION >= QT_VERSION_CHECK(6, 4, 0) #include "modulesqt6_4.h" class Modules: public ModulesQt6_4