Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to Qt 6 #4584

Merged
merged 71 commits into from
Apr 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
71 commits
Select commit Hold shift + click to select a range
2146406
port away from QDesktopServices::storageLocation
mgallien May 20, 2022
80b25d3
port away from QStringList::toSet
mgallien May 20, 2022
b712108
add missing Qt:: namespace when using Qt::endl
mgallien May 20, 2022
d035c26
replace qrand/qsrand
mgallien May 22, 2022
20ee506
port away from deprecated API from QFontMetricsF
mgallien May 22, 2022
249e0eb
port away from QWidget related margines APIs
mgallien May 22, 2022
ee245f2
replace deprecated QWebEngineProfile::setRequestInterceptor
mgallien May 22, 2022
b63c88e
add missing QStringLiteral
mgallien May 23, 2022
1f0279e
remove usage of QStringRef due to it being missing in Qt6
mgallien May 23, 2022
d3442d1
disable qt apis deprecated before qt 5.12, enable warnings
mgallien May 20, 2022
aa76de9
allow detection of qt5 or qt6
mgallien May 20, 2022
4566400
streamline find_package calls to really find Qt6
mgallien Oct 2, 2022
fe7c00a
Fix macOS-specific CMake things with Qt6
claucambra Nov 21, 2022
79a150b
Fix qtkeychain imports with Qt6
claucambra Nov 21, 2022
29b0d2b
Remove use of QNetworkConfiguration in Qt6
claucambra Nov 21, 2022
9932956
Remove qtokenizer in favour of Qt6 QStringTokenizer
claucambra Nov 22, 2022
4cad9eb
Fix type of decpoint
claucambra Nov 23, 2022
6a497cf
Fix QTextCodec related build issues
claucambra Nov 23, 2022
366f5f0
Fix bad conversion to bool of shared pointer
claucambra Nov 23, 2022
ac1206a
Remove conflicting alias to QStringList
claucambra Nov 23, 2022
7954695
Add missing QStandardPaths include
claucambra Nov 23, 2022
1a2db48
Add missing QActionGroup include
claucambra Nov 23, 2022
6210490
Replace now invalid '+' operator with '|' operator for QKeySequence
claucambra Nov 23, 2022
84414ce
Replace deleted '+' operator for flags with '|' operator
claucambra Nov 23, 2022
7e1448b
Remove use of qRegisterMetatypeStreamOperators
claucambra Nov 23, 2022
7a17a51
Use QEnterEvent for new enterEvent parameters
claucambra Nov 23, 2022
aaea451
Replace removed progress bar option orientation with state flag
claucambra Nov 23, 2022
a8e7e34
Replace use of staticQtMetaObject with staticMetaObject
claucambra Nov 23, 2022
a0e90cf
Remove use of QCoreApplication AA attributes
claucambra Nov 23, 2022
c31e65c
Remove crashing QRandomGenerator seed call
claucambra Nov 23, 2022
7e62368
Fix QDateTime string formatting
claucambra Nov 23, 2022
5087d51
Fix all broken QML imports
claucambra Nov 23, 2022
52758a0
Fix QML coloring issues
claucambra Nov 23, 2022
3597766
Add separators to SyncStatus and UnifiedSearchInputContainer to stop …
claucambra Nov 24, 2022
3765df6
Fix test compilation
claucambra Nov 28, 2022
5d765dd
Fix user status selector
claucambra Nov 30, 2022
70931fb
Remove commented out broken quick compiler check in Qt6
claucambra Dec 13, 2022
e345684
last step
mgallien Jul 27, 2023
ced85ac
fix automated tests with network requests
mgallien Sep 17, 2023
274d866
fix failing automated test that erases invalid iterator
mgallien Sep 17, 2023
670b2ce
fix automated tests missing toString() convert from QVariant
mgallien Sep 17, 2023
fa766c0
properly use QStringView to avoid copies
mgallien Sep 17, 2023
09e6074
e proper data type in data for activity model automated test data
mgallien Sep 17, 2023
032af80
fix computation of timeout for jobs to have proper bounds (min < max)
mgallien Sep 17, 2023
44f6d51
only try to include qt6-keychain header and not the qt5 version
mgallien Sep 18, 2023
b7bba50
let appimage build script work with Qt6 based version
mgallien Sep 18, 2023
332f069
use the new CI images with Qt6
mgallien Sep 18, 2023
ced6d32
build appimage
mgallien Sep 18, 2023
430d56e
build image for Qt6
mgallien Sep 18, 2023
7432fb4
adapt ci checks to Qt6
mgallien Sep 18, 2023
910d7f0
when loading translation catalog, do not ignore the return value
mgallien Sep 19, 2023
3ad7ac9
avoid warning by ignoring the return value of QtConcurrent::run
mgallien Sep 19, 2023
4f178fa
fix order of init in a constructor to avoid warnings
mgallien Sep 19, 2023
8ad2a82
Signed drone.yml
tobiasKaminsky Sep 19, 2023
aae9e84
fix compilation issues after rebase
mgallien Apr 5, 2024
060181f
fix some of the qml issues
mgallien Apr 8, 2024
7d13202
use new qt 6.6.3 ci images
mgallien Apr 10, 2024
82a0c1d
NetrcParser tests are known to be broken
mgallien Apr 10, 2024
3099628
header changes needed for clang/vs2022 compilers
mgallien Apr 10, 2024
9b9ff4f
add needed namespace for declarations read by Qt metaobject system
mgallien Apr 10, 2024
a05ac62
do some header includes clean-up as recommended by compiler
mgallien Apr 10, 2024
1533670
add NextcloudSslCertificate to wrap QSslCertificate in QHash
mgallien Apr 10, 2024
20db6b6
fully qualify types for use with Qt metaobject system
mgallien Apr 10, 2024
bebb8e1
fix compilation issues on windows
mgallien Apr 10, 2024
a357570
fix compilation after rebase
mgallien Apr 17, 2024
2d5753c
make it easy to find out that this branch is Qt6 based
mgallien Apr 18, 2024
794db30
fix compilation of AppImage packages
mgallien Apr 22, 2024
5bed41a
use the correct Qt6 build in newer CI images
mgallien Apr 23, 2024
347285b
fix build issue after rebase
mgallien Apr 24, 2024
07c2554
AppImage build tool for Qt needs to know our qml files
mgallien Apr 24, 2024
3770eec
windows needs an explicit QML import path to be set
mgallien Apr 24, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions .drone.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
---
kind: pipeline
name: qt-5.15
name: drone desktop client

steps:
- name: cmake
image: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
image: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
volumes:
- name: build
path: /drone/build
commands:
- cd /drone/build
- cmake -G Ninja -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11 -DCMAKE_BUILD_TYPE=Debug -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DADD_E2E_TESTS=ON -DECM_ENABLE_SANITIZERS=address -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64 ../src
- cmake -G Ninja -DCMAKE_PREFIX_PATH=/opt/qt6.6.3 -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11 -DCMAKE_BUILD_TYPE=Debug -DQT_MAJOR_VERSION=6 -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DADD_E2E_TESTS=ON -DECM_ENABLE_SANITIZERS=address -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64 ../src

- name: compile
image: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
image: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
volumes:
- name: build
path: /drone/build
Expand All @@ -22,7 +22,7 @@ steps:
- ninja

- name: test
image: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
image: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
volumes:
- name: build
path: /drone/build
Expand Down Expand Up @@ -79,23 +79,23 @@ name: qt-5.15-clang

steps:
- name: cmake
image: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
image: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
volumes:
- name: build
path: /drone/build
commands:
- cd /drone/build
- cmake -G Ninja -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_C_COMPILER=clang-14 -DCMAKE_CXX_COMPILER=clang++-14 -DCMAKE_BUILD_TYPE=Debug -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DADD_E2E_TESTS=ON -DECM_ENABLE_SANITIZERS=address -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64 ../src
- cmake -G Ninja -DCMAKE_PREFIX_PATH=/opt/qt6.6.3 -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_C_COMPILER=clang-14 -DCMAKE_CXX_COMPILER=clang++-14 -DCMAKE_BUILD_TYPE=Debug -DQT_MAJOR_VERSION=6 -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DADD_E2E_TESTS=ON -DECM_ENABLE_SANITIZERS=address -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64 ../src
- name: compile
image: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
image: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
volumes:
- name: build
path: /drone/build
commands:
- cd /drone/build
- ninja
- name: test
image: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
image: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
volumes:
- name: build
path: /drone/build
Expand Down Expand Up @@ -152,7 +152,7 @@ name: AppImage

steps:
- name: build
image: ghcr.io/nextcloud/continuous-integration-client-appimage:client-appimage-10
image: ghcr.io/nextcloud/continuous-integration-client-appimage-qt6:client-appimage-6.6.3-2
environment:
CI_UPLOAD_GIT_TOKEN:
from_secret: CI_UPLOAD_GIT_TOKEN
Expand Down Expand Up @@ -206,6 +206,6 @@ trigger:
- push
---
kind: signature
hmac: 52e9470231175367dbb83f5aa33659332e977546cf1a9db3d942401778f53d68
hmac: 418915bcd7a880be3656a8c09aef0f6e7b3721d13f196838f8c5a9de6020f786

...
4 changes: 2 additions & 2 deletions .github/workflows/linux-clang-compile-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
build:
name: Linux Clang compilation and tests
runs-on: ubuntu-latest
container: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
container: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -15,7 +15,7 @@ jobs:
run: |
mkdir build
cd build
cmake .. -G Ninja -DCMAKE_C_COMPILER=clang-14 -DCMAKE_CXX_COMPILER=clang++-14 -DCMAKE_BUILD_TYPE=Debug -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64
cmake .. -G Ninja -DCMAKE_PREFIX_PATH=/opt/qt6.6.3 -DCMAKE_C_COMPILER=clang-14 -DCMAKE_CXX_COMPILER=clang++-14 -DCMAKE_BUILD_TYPE=Debug -DQT_MAJOR_VERSION=6 -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64
ninja
- name: Run tests
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/linux-gcc-compile-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
build:
name: Linux GCC compilation and tests
runs-on: ubuntu-latest
container: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
container: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -15,7 +15,7 @@ jobs:
run: |
mkdir build
cd build
cmake .. -G Ninja -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11 -DCMAKE_BUILD_TYPE=Debug -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64
cmake .. -G Ninja -DCMAKE_PREFIX_PATH=/opt/qt6.6.3 -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11 -DCMAKE_BUILD_TYPE=Debug -DQT_MAJOR_VERSION=6 -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64
ninja
- name: Run tests
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
build:
name: SonarCloud analysis
runs-on: ubuntu-latest
container: ghcr.io/nextcloud/continuous-integration-client:client-5.15-15
container: ghcr.io/nextcloud/continuous-integration-client-qt6:client-6.6.3-2
env:
SONAR_SERVER_URL: "https://sonarcloud.io"
BUILD_WRAPPER_OUT_DIR: build_wrapper_output_directory # Directory where build-wrapper output will be placed
Expand All @@ -25,7 +25,7 @@ jobs:
run: |
mkdir build
cd build
cmake .. -G Ninja -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11 -DCMAKE_BUILD_TYPE=Debug -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64 -DBUILD_COVERAGE=ON -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
cmake .. -G Ninja -DCMAKE_PREFIX_PATH=/opt/qt6.6.3 -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11 -DCMAKE_BUILD_TYPE=Debug -DQUICK_COMPILER=ON -DBUILD_UPDATER=ON -DBUILD_TESTING=1 -DQT_MAJOR_VERSION=6 -DCMAKE_CXX_FLAGS=-Werror -DOPENSSL_ROOT_DIR=/usr/local/lib64 -DBUILD_COVERAGE=ON -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
build-wrapper-linux-x86-64 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} ninja
- name: Run tests
run: |
Expand Down
8 changes: 6 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ set(BIN_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")

include(${CMAKE_SOURCE_DIR}/NEXTCLOUD.cmake)

set(QT_VERSION_MAJOR "6")
set(REQUIRED_QT_VERSION "6.0.0")

# CfAPI Shell Extensions
set( CFAPI_SHELL_EXTENSIONS_LIB_NAME CfApiShellExtensions )

Expand Down Expand Up @@ -108,7 +111,8 @@ include(GetGitRevisionDescription)
get_git_head_revision(GIT_REFSPEC GIT_SHA1)

add_definitions(
-DQT_DISABLE_DEPRECATED_BEFORE=0x000000
-DQT_DISABLE_DEPRECATED_BEFORE=0x051200
-DQT_DEPRECATED_WARNINGS
-DQT_USE_QSTRINGBUILDER
-DQT_MESSAGELOGCONTEXT #enable function name and line number in debug output
)
Expand Down Expand Up @@ -138,7 +142,7 @@ if(APPLE AND BUILD_OWNCLOUD_OSX_BUNDLE)
add_definitions(-DBUILD_OWNCLOUD_OSX_BUNDLE)
endif()


find_package(Qt${QT_MAJOR_VERSION} COMPONENTS Core)
option(QUICK_COMPILER "Use QtQuick compiler to improve performance" OFF)

# this option removes Http authentication, keychain, shibboleth etc and is intended for
Expand Down
2 changes: 2 additions & 0 deletions VERSION.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,5 @@ set( MIRALL_VERSION_STRING "${MIRALL_VERSION}${MIRALL_VERSION_SUFFIX}" )
if( MIRALL_VERSION_BUILD )
set( MIRALL_VERSION_STRING "${MIRALL_VERSION_STRING} (build ${MIRALL_VERSION_BUILD})" )
endif( MIRALL_VERSION_BUILD )

set(QT_MAJOR_VERSION 6)
90 changes: 38 additions & 52 deletions admin/linux/build-appimage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,12 @@

set -xe

export APPNAME=${APPNAME:-nextcloud}
export APPNAME=${APPNAME:-Nextcloud}
export EXECUTABLE_NAME=${EXECUTABLE_NAME:-nextcloud}
export BUILD_UPDATER=${BUILD_UPDATER:-OFF}
export BUILDNR=${BUILDNR:-0000}
export DESKTOP_CLIENT_ROOT=${DESKTOP_CLIENT_ROOT:-/home/user}

#Set Qt-5.15
export QT_BASE_DIR=/opt/kdeqt5.15

export QTDIR=$QT_BASE_DIR
export PATH=$QT_BASE_DIR/bin:$PATH

# Set defaults
export SUFFIX=${DRONE_PULL_REQUEST:=master}
if [ $SUFFIX != "master" ]; then
Expand All @@ -29,12 +24,14 @@ mkdir build-client
cd build-client
cmake \
-G Ninja \
-D CMAKE_INSTALL_PREFIX=/usr \
-D BUILD_TESTING=OFF \
-D BUILD_UPDATER=$BUILD_UPDATER \
-D MIRALL_VERSION_BUILD=$BUILDNR \
-D MIRALL_VERSION_SUFFIX="$VERSION_SUFFIX" \
-D CMAKE_UNITY_BUILD=ON \
-DCMAKE_PREFIX_PATH=/opt/qt6.6.3 \
-DOPENSSL_ROOT_DIR=/usr/local/lib64 \
-DCMAKE_INSTALL_PREFIX=/usr \
-DBUILD_TESTING=OFF \
-DBUILD_UPDATER=$BUILD_UPDATER \
-DMIRALL_VERSION_BUILD=$BUILDNR \
-DMIRALL_VERSION_SUFFIX="$VERSION_SUFFIX" \
-DCMAKE_UNITY_BUILD=ON \
${DESKTOP_CLIENT_ROOT}
cmake --build . --target all
DESTDIR=/app cmake --install .
Expand Down Expand Up @@ -64,48 +61,37 @@ rm -rf etc

# com.nextcloud.desktopclient.nextcloud.desktop
DESKTOP_FILE=$(ls /app/usr/share/applications/*.desktop)
sed -i -e 's|Icon=nextcloud|Icon=Nextcloud|g' ${DESKTOP_FILE} # Bug in desktop file?
cp ./usr/share/icons/hicolor/512x512/apps/*.png . # Workaround for linuxeployqt bug, FIXME

# Because distros need to get their shit together
cp -R /usr/lib/x86_64-linux-gnu/libssl.so* ./usr/lib/
cp -R /usr/lib/x86_64-linux-gnu/libcrypto.so* ./usr/lib/
cp -P /usr/local/lib*/libssl.so* ./usr/lib/
cp -P /usr/local/lib*/libcrypto.so* ./usr/lib/
cp -P /usr/local/lib*/libsqlite*.so* ./usr/lib/

# NSS fun
cp -P -r /usr/lib/x86_64-linux-gnu/nss ./usr/lib/

# Use linuxdeployqt to deploy
LINUXDEPLOYQT_VERSION="continuous"
wget -O linuxdeployqt.AppImage --ca-directory=/etc/ssl/certs -c "https://github.com/probonopd/linuxdeployqt/releases/download/${LINUXDEPLOYQT_VERSION}/linuxdeployqt-continuous-x86_64.AppImage"
chmod a+x linuxdeployqt.AppImage
./linuxdeployqt.AppImage --appimage-extract
rm ./linuxdeployqt.AppImage
cp -r ./squashfs-root ./linuxdeployqt-squashfs-root
unset QTDIR; unset QT_PLUGIN_PATH ; unset LD_LIBRARY_PATH
export LD_LIBRARY_PATH=/usr/local/lib:/usr/local/lib/x86_64-linux-gnu
./squashfs-root/AppRun ${DESKTOP_FILE} -bundle-non-qt-libs -qmldir=${DESKTOP_CLIENT_ROOT}/src/gui

# Set origin
./squashfs-root/usr/bin/patchelf --set-rpath '$ORIGIN/' /app/usr/lib/lib*sync.so.0

# Build AppImage
./squashfs-root/AppRun ${DESKTOP_FILE} -appimage -updateinformation="gh-releases-zsync|nextcloud-releases|desktop|latest|Nextcloud-*-x86_64.AppImage.zsync"

# Workaround issue #103
rm -rf ./squashfs-root
APPIMAGE=$(ls *.AppImage)
"./${APPIMAGE}" --appimage-extract
rm "./${APPIMAGE}"
rm ./squashfs-root/usr/lib/libglib-2.0.so.0
rm ./squashfs-root/usr/lib/libgobject-2.0.so.0
PATH=./linuxdeployqt-squashfs-root/usr/bin:$PATH appimagetool -n ./squashfs-root "$APPIMAGE"

# Use linuxdeploy to deploy
export APPIMAGE_NAME=linuxdeploy-x86_64.AppImage
wget -O ${APPIMAGE_NAME} --ca-directory=/etc/ssl/certs -c "https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage"
chmod a+x ${APPIMAGE_NAME}
./${APPIMAGE_NAME} --appimage-extract
rm ./${APPIMAGE_NAME}
cp -r ./squashfs-root ./linuxdeploy-squashfs-root

export LD_LIBRARY_PATH=/app/usr/lib:/opt/qt6.6.3/lib:/usr/local/lib/x86_64-linux-gnu:/usr/local/lib:/usr/local/lib64
./linuxdeploy-squashfs-root/AppRun --desktop-file=${DESKTOP_FILE} --icon-file=usr/share/icons/hicolor/512x512/apps/${APPNAME}.png --executable=usr/bin/${EXECUTABLE_NAME} --appdir=AppDir

# Use linuxdeploy-plugin-qt to deploy qt dependencies
export APPIMAGE_NAME=linuxdeploy-plugin-qt-x86_64.AppImage
wget -O ${APPIMAGE_NAME} --ca-directory=/etc/ssl/certs -c "https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage"
chmod a+x ${APPIMAGE_NAME}
./${APPIMAGE_NAME} --appimage-extract
rm ./${APPIMAGE_NAME}
cp -r ./squashfs-root ./linuxdeploy-plugin-qt-squashfs-root

export PATH=/opt/qt6.6.3/bin:${PATH}
export QML_SOURCES_PATHS=${DESKTOP_CLIENT_ROOT}/src/gui
./linuxdeploy-plugin-qt-squashfs-root/AppRun --appdir=AppDir

./linuxdeploy-squashfs-root/AppRun --desktop-file=${DESKTOP_FILE} --icon-file=usr/share/icons/hicolor/512x512/apps/${APPNAME}.png --executable=usr/bin/${EXECUTABLE_NAME} --appdir=AppDir --output appimage

#move AppImage
if [ ! -z "$DRONE_COMMIT" ]
then
mv *.AppImage ${APPNAME}-${SUFFIX}-${DRONE_COMMIT}-x86_64.AppImage
mv *.AppImage ${EXECUTABLE_NAME}-${SUFFIX}-${DRONE_COMMIT}-x86_64.AppImage
else
mv *.AppImage ${EXECUTABLE_NAME}-${SUFFIX}-x86_64.AppImage
fi
mv *.AppImage ${DESKTOP_CLIENT_ROOT}/
2 changes: 1 addition & 1 deletion admin/osx/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ else()
set(MAC_INSTALLER_DO_CUSTOM_BACKGROUND "0")
endif()

find_package(Qt5 5.15 COMPONENTS Core REQUIRED)
find_package(Qt${QT_VERSION_MAJOR} ${REQUIRED_QT_VERSION} COMPONENTS Core REQUIRED)
configure_file(create_mac.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/create_mac.sh)
configure_file(macosx.pkgproj.cmake ${CMAKE_CURRENT_BINARY_DIR}/macosx.pkgproj)
configure_file(pre_install.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/pre_install.sh)
Expand Down
9 changes: 7 additions & 2 deletions shell_integration/libcloudproviders/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,13 @@ macro(libcloudproviders_add_config _sources)
endmacro(libcloudproviders_add_config _sources)


find_package(Qt5 5.15 COMPONENTS DBus)
IF (Qt5DBus_FOUND)
if (Qt6_FOUND)
find_package(Qt6 COMPONENTS COMPONENTS DBus)
else()
set(REQUIRED_QT_VERSION "5.15.0")
find_package(Qt5 ${REQUIRED_QT_VERSION} COMPONENTS DBus)
endif()
IF (Qt5DBus_FOUND OR Qt6DBus_FOUND)
STRING(TOLOWER "${APPLICATION_VENDOR}" DBUS_VENDOR)
STRING(REGEX REPLACE "[^A-z0-9]" "" DBUS_VENDOR "${DBUS_VENDOR}")
STRING(REGEX REPLACE "[^A-z0-9]" "" DBUS_APPLICATION_NAME "${APPLICATION_SHORTNAME}")
Expand Down
Loading
Loading