From d9cc9eb916a4e9d7c88a19de29e0a4d9b2043c2c Mon Sep 17 00:00:00 2001 From: Tadej Novak Date: Sat, 27 Jul 2024 18:27:53 +0200 Subject: [PATCH] Fix static and Android releases (#148) * Fix Android release * Fix static build installation issues --- .github/workflows/Android.yml | 2 +- src/location/macros.cmake | 21 +++++++++++---------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/.github/workflows/Android.yml b/.github/workflows/Android.yml index 73c7f1e..44560c6 100644 --- a/.github/workflows/Android.yml +++ b/.github/workflows/Android.yml @@ -140,7 +140,7 @@ jobs: needs: build strategy: matrix: - qt_version: [6.5.3, 6.6.3] + qt_version: [6.5.3, 6.6.3, 6.7.2] steps: - name: Download artifacts for x86 diff --git a/src/location/macros.cmake b/src/location/macros.cmake index 51470cc..09cd0e3 100644 --- a/src/location/macros.cmake +++ b/src/location/macros.cmake @@ -25,16 +25,6 @@ function(qmaplibre_location_setup_plugins target) set(_targetDestination "${_targetDestination}/") endif() - get_target_property(_targetTypeCore QMapLibre::Core TYPE) - if(_targetTypeCore STREQUAL STATIC_LIBRARY) - target_link_libraries( - ${target} - PRIVATE - QMapLibre::PluginGeoServices - QMapLibre::PluginQml - ) - endif() - set_target_properties( ${target} PROPERTIES @@ -46,6 +36,17 @@ function(qmaplibre_location_setup_plugins target) list(REMOVE_DUPLICATES _importPathCache) set(QML_IMPORT_PATH ${_importPathCache} CACHE STRING "QML import path for QtCreator" FORCE) + get_target_property(_targetTypeCore QMapLibre::Core TYPE) + if(_targetTypeCore STREQUAL STATIC_LIBRARY) + target_link_libraries( + ${target} + PRIVATE + QMapLibre::PluginGeoServices + QMapLibre::PluginQml + ) + return() + endif() + if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") file( COPY "${_ImportedLocationGeoServices}"