Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.5:Update
nomacs
quazip1_cmake_remove_after_new_version.diff
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File quazip1_cmake_remove_after_new_version.diff of Package nomacs
diff --git a/ImageLounge/cmake/Unix.cmake b/ImageLounge/cmake/Unix.cmake index 5567084b..c90ba320 100644 --- a/ImageLounge/cmake/Unix.cmake +++ b/ImageLounge/cmake/Unix.cmake @@ -102,14 +102,26 @@ unset(QT_ROOT CACHE) if(ENABLE_QUAZIP) if(USE_SYSTEM_QUAZIP) - SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake) - - find_package(QuaZip5 QUIET) - if(NOT QUAZIP_FOUND) - message(FATAL_ERROR "QUAZIP not found. It's mandatory when used with ENABLE_QUAZIP enabled, you can also disable USE_SYSTEM_QUAZIP") - else() - add_definitions(-DWITH_QUAZIP) - endif() + # Let's try QuaZip1 first (it's the bright future) + find_package(QuaZip-Qt5 QUIET) + if (QuaZip-Qt5_FOUND) + message(STATUS "QUAZIP: QuaZip-1 for Qt5 found") + set(QUAZIP_LIBRARIES QuaZip::QuaZip) + add_definitions(-DWITH_QUAZIP1) + else () + message(WARNING "QUAZIP: 1.x not found. Trying to find 0.x") + # QuaZip < 1.0. This leg can be removed (including cmake/FindQuaZip5.cmake) + # ater the final migration to 1.x in Linux distros + SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake) + + find_package(QuaZip5 QUIET) + if(NOT QUAZIP_FOUND) + message(FATAL_ERROR "QUAZIP: even 0.x not found. It's mandatory when used with ENABLE_QUAZIP enabled, you can also disable USE_SYSTEM_QUAZIP") + endif() + + endif (QuaZip-Qt5_FOUND) + # we have any QuaZip after all + add_definitions(-DWITH_QUAZIP) else() find_package(ZLIB REQUIRED) set(QUAZIP_INCLUDE_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/quazip-0.7/quazip ${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/quazip-0.7/) diff --git a/ImageLounge/src/DkCore/DkBasicLoader.cpp b/ImageLounge/src/DkCore/DkBasicLoader.cpp index 7f9e889c..b7edfd43 100644 --- a/ImageLounge/src/DkCore/DkBasicLoader.cpp +++ b/ImageLounge/src/DkCore/DkBasicLoader.cpp @@ -54,8 +54,12 @@ // quazip #ifdef WITH_QUAZIP +#ifdef WITH_QUAZIP1 +#include <quazip/JlCompress.h> +#else #include <quazip5/JlCompress.h> #endif +#endif // opencv #ifdef WITH_OPENCV diff --git a/ImageLounge/src/DkCore/DkImageContainer.cpp b/ImageLounge/src/DkCore/DkImageContainer.cpp index 810994d3..150da9c2 100644 --- a/ImageLounge/src/DkCore/DkImageContainer.cpp +++ b/ImageLounge/src/DkCore/DkImageContainer.cpp @@ -41,8 +41,12 @@ // quazip #ifdef WITH_QUAZIP +#ifdef WITH_QUAZIP1 +#include <quazip/JlCompress.h> +#else #include <quazip5/JlCompress.h> #endif +#endif #pragma warning(pop) // no warnings from includes - end #pragma warning(disable: 4251) // TODO: remove diff --git a/ImageLounge/src/DkCore/DkImageLoader.cpp b/ImageLounge/src/DkCore/DkImageLoader.cpp index 09d25d23..e4186f2b 100644 --- a/ImageLounge/src/DkCore/DkImageLoader.cpp +++ b/ImageLounge/src/DkCore/DkImageLoader.cpp @@ -79,8 +79,12 @@ // quazip #ifdef WITH_QUAZIP +#ifdef WITH_QUAZIP1 +#include <quazip/JlCompress.h> +#else #include <quazip5/JlCompress.h> #endif +#endif // opencv #ifdef WITH_OPENCV @@ -2212,4 +2216,4 @@ QString DkImageLoader::fileName() const { return mCurrentImage->fileName(); } -} \ No newline at end of file +} diff --git a/ImageLounge/src/DkGui/DkDialog.cpp b/ImageLounge/src/DkGui/DkDialog.cpp index 008c9a3b..85842eca 100644 --- a/ImageLounge/src/DkGui/DkDialog.cpp +++ b/ImageLounge/src/DkGui/DkDialog.cpp @@ -97,8 +97,12 @@ // quazip #ifdef WITH_QUAZIP +#ifdef WITH_QUAZIP1 +#include <quazip/JlCompress.h> +#else #include <quazip5/JlCompress.h> #endif +#endif #pragma warning(pop) // no warnings from includes - end
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor