refactor: simpler includes for quazip

This commit is contained in:
Sefa Eyeoglu 2022-01-25 12:53:33 +01:00
parent 81c72c2038
commit 0442b80a2c
No known key found for this signature in database
GPG Key ID: C10411294912A422
14 changed files with 2 additions and 76 deletions

View File

@ -263,7 +263,6 @@ add_subdirectory(libraries/javacheck) # java compatibility checker
add_subdirectory(libraries/xz-embedded) # xz compression
if (NOT QuaZip-Qt${QT_VERSION_MAJOR}_FOUND)
set(QUAZIP_QT_MAJOR_VERSION ${QT_VERSION_MAJOR})
add_compile_definitions(QUAZIP_USE_SUBMODULE)
MESSAGE(STATUS "Adding QuaZip submodule, with QT_VERSION_MAJOR ${QUAZIP_QT_MAJOR_VERSION}")
add_subdirectory(libraries/quazip) # zip manipulation library
endif()

View File

@ -29,12 +29,7 @@
#include "modplatform/flame/FileResolvingTask.h"
#include "modplatform/flame/PackManifest.h"
#include "Json.h"
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazipdir.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazipdir.h>
#endif
#include "modplatform/technic/TechnicPackProcessor.h"
#include "icons/IconList.h"

View File

@ -12,15 +12,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#include <quazip/quazipdir.h>
#include <quazip/quazipfile.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#include <QuaZip-Qt5-1.2/quazip/quazipdir.h>
#include <QuaZip-Qt5-1.2/quazip/quazipfile.h>
#endif
#include "MMCZip.h"
#include "FileSystem.h"

View File

@ -19,14 +19,10 @@
#include <QFileInfo>
#include <QSet>
#include "minecraft/mod/Mod.h"
#include "nonstd/optional"
#include <functional>
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/JlCompress.h>
#else
#include <QuaZip-Qt5-1.2/quazip/JlCompress.h>
#endif
#include <nonstd/optional>
namespace MMCZip
{

View File

@ -20,12 +20,7 @@
#include <QUrl>
#include "tasks/Task.h"
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#endif
#include "QObjectPtr.h"

View File

@ -22,12 +22,7 @@
#include "net/NetJob.h"
#include "tasks/Task.h"
#include "minecraft/VersionFilterData.h"
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#endif
class MinecraftVersion;
class MinecraftInstance;

View File

@ -26,16 +26,9 @@
#include <io/stream_reader.h>
#include <tag_string.h>
#include <tag_primitive.h>
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#include <quazip/quazipfile.h>
#include <quazip/quazipdir.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#include <QuaZip-Qt5-1.2/quazip/quazipfile.h>
#include <QuaZip-Qt5-1.2/quazip/quazipdir.h>
#endif
#include <QCoreApplication>

View File

@ -17,14 +17,8 @@
#include <minecraft/MinecraftInstance.h>
#include <launch/LaunchTask.h>
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#include <quazip/quazipdir.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#include <QuaZip-Qt5-1.2/quazip/quazipdir.h>
#endif
#include "MMCZip.h"
#include "FileSystem.h"
#include <QDir>

View File

@ -4,15 +4,8 @@
#include <QJsonObject>
#include <QJsonArray>
#include <QJsonValue>
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#include <quazip/quazipfile.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#include <QuaZip-Qt5-1.2/quazip/quazipfile.h>
#endif
#include <toml.h>
#include "settings/INIFile.h"

View File

@ -19,11 +19,7 @@
#include <QtConcurrent/QtConcurrent>
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#endif
#include "MMCZip.h"
#include "minecraft/OneSixVersionFormat.h"

View File

@ -1,15 +1,8 @@
#pragma once
#include "InstanceTask.h"
#include "net/NetJob.h"
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#include <quazip/quazipdir.h>
#else
#include "QuaZip-Qt5-1.2/quazip/quazip.h"
#include "QuaZip-Qt5-1.2/quazip/quazipdir.h"
#endif
#include "meta/Index.h"
#include "meta/Version.h"
#include "meta/VersionList.h"

View File

@ -18,11 +18,7 @@
#include "InstanceTask.h"
#include "net/NetJob.h"
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#else
#include "QuaZip-Qt5-1.2/quazip/quazip.h"
#endif
#include <QFutureWatcher>
#include <QStringList>

View File

@ -19,17 +19,9 @@
#include <Json.h>
#include <minecraft/MinecraftInstance.h>
#include <minecraft/PackProfile.h>
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazip.h>
#include <quazip/quazipdir.h>
#include <quazip/quazipfile.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazip.h>
#include <QuaZip-Qt5-1.2/quazip/quazipdir.h>
#include <QuaZip-Qt5-1.2/quazip/quazipfile.h>
#endif
#include <settings/INISettingsObject.h>
#include <memory>

View File

@ -18,13 +18,7 @@
#include "classparser.h"
#include <QFile>
#ifdef QUAZIP_USE_SUBMODULE
#include <quazip/quazipfile.h>
#else
#include <QuaZip-Qt5-1.2/quazip/quazipfile.h>
#endif
#include <QDebug>
namespace classparser