summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMinze Zwerver2018-06-14 08:39:58 +0200
committerMinze Zwerver2018-06-14 09:34:16 +0200
commit20c398d091af8971143b331890e3aa1d73253dd0 (patch)
tree2be3655c88f23d274a15a45758d066d19916d8f8
parentb355243074119c0887b1b0956cb0966e2c718f6d (diff)
downloadaur-20c398d091af8971143b331890e3aa1d73253dd0.tar.gz
replaced qt5_use_modules to fit qt version 5.11
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD8
-rw-r--r--qt5_modules.patch116
3 files changed, 125 insertions, 3 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 36120a66bd5..2bd86a9ae55 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = opentx-companion
pkgdesc = EEPROM Editor for OpenTX RC transmitter firmwares
pkgver = 2.2.1
- pkgrel = 2
+ pkgrel = 3
url = http://www.open-tx.org/
arch = x86_64
license = GPL
@@ -29,8 +29,10 @@ pkgbase = opentx-companion
conflicts = companion9x-svn
source = https://github.com/opentx/opentx/archive/2.2.1.tar.gz
source = installprefix.patch
+ source = qt5_modules.patch
sha256sums = 626e8f6c48d686b41311b633326811cab6788bb667185cb0e3ec0f0d627390af
sha256sums = 9d669cf723e98b7be5463538b0590ae7776b3b866a423cceeb30ba9840748c64
+ sha256sums = 30fd1396a47bfc250780786e52447547aafcf934c6fe1775e4301fa3c7185be2
pkgname = opentx-companion
diff --git a/PKGBUILD b/PKGBUILD
index 81a833d8934..b43f4862272 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,7 +3,7 @@
# Contributer: Arnaud
pkgname=('opentx-companion')
pkgver=2.2.1
-pkgrel=2
+pkgrel=3
pkgdesc="EEPROM Editor for OpenTX RC transmitter firmwares"
arch=('x86_64')
url="http://www.open-tx.org/"
@@ -15,20 +15,24 @@ provides=('companion')
conflicts=('companion' 'companion9x-svn')
source=("https://github.com/opentx/opentx/archive/$pkgver.tar.gz"
"installprefix.patch"
+"qt5_modules.patch"
)
sha256sums=(
'626e8f6c48d686b41311b633326811cab6788bb667185cb0e3ec0f0d627390af'
'9d669cf723e98b7be5463538b0590ae7776b3b866a423cceeb30ba9840748c64'
+ '30fd1396a47bfc250780786e52447547aafcf934c6fe1775e4301fa3c7185be2'
)
build() {
patch $srcdir/opentx-$pkgver/tools/build-companion-release.sh $startdir/installprefix.patch
+ cd $srcdir/opentx-$pkgver
+ patch -t -p 1 < $startdir/qt5_modules.patch
$srcdir/opentx-$pkgver/tools/build-companion-release.sh $srcdir/opentx-$pkgver dummy
}
package() {
- cd build
+ cd $srcdir/opentx-$pkgver/build
make -j`nproc` DESTDIR=$pkgdir/ install
cd $pkgdir/usr/share/applications
sed -i -e 's/Categories=Application/Categories=Development;/' companion22.desktop
diff --git a/qt5_modules.patch b/qt5_modules.patch
new file mode 100644
index 00000000000..536c65eff39
--- /dev/null
+++ b/qt5_modules.patch
@@ -0,0 +1,116 @@
+diff -ur opentx-2.2.1/companion/src/CMakeLists.txt opentx-2.2.1.fix/companion/src/CMakeLists.txt
+--- opentx-2.2.1/companion/src/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/companion/src/CMakeLists.txt 2018-06-14 08:53:05.635342446 +0200
+@@ -193,8 +193,8 @@
+ #add_custom_target(gen_qrc DEPENDS ${common_RCC} ${companion_QM})
+
+ add_library(common ${common_SRCS} ${common_RCC})
+-qt5_use_modules(common Core Xml Widgets)
+-target_link_libraries(common PRIVATE simulation)
++#qt5_use_modules(common Core Xml Widgets)
++target_link_libraries(common PRIVATE simulation Qt5::Core Qt5::Xml Qt5::Widgets)
+ #add_dependencies(common gen_qrc)
+
+ set(CPN_COMMON_LIB common)
+@@ -304,7 +304,7 @@
+ qt5_wrap_cpp(companion_SRCS ${companion_MOC_HDRS})
+
+ add_executable(${COMPANION_NAME} MACOSX_BUNDLE ${WIN_EXECUTABLE_TYPE} ${companion_SRCS} ${icon_RC})
+-qt5_use_modules(${COMPANION_NAME} Core Widgets Network)
++#qt5_use_modules(${COMPANION_NAME} Core Widgets Network)
+ target_link_libraries(${COMPANION_NAME} PRIVATE generaledit modeledit simulation ${CPN_COMMON_LIB} qcustomplot shared storage ${PTHREAD_LIBRARY} ${SDL_LIBRARY} ${WIN_LINK_LIBRARIES})
+
+ PrintTargetReport("${COMPANION_NAME}")
+diff -ur opentx-2.2.1/companion/src/generaledit/CMakeLists.txt opentx-2.2.1.fix/companion/src/generaledit/CMakeLists.txt
+--- opentx-2.2.1/companion/src/generaledit/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/companion/src/generaledit/CMakeLists.txt 2018-06-14 08:33:52.072648515 +0200
+@@ -28,5 +28,5 @@
+ qt5_wrap_cpp(generaledit_SRCS ${generaledit_HDRS})
+
+ add_library(generaledit ${generaledit_SRCS})
+-qt5_use_modules(generaledit Widgets Xml Multimedia)
+-target_link_libraries(generaledit PRIVATE ${CPN_COMMON_LIB})
++#qt5_use_modules(generaledit Widgets Xml Multimedia)
++target_link_libraries(generaledit PRIVATE ${CPN_COMMON_LIB} Qt5::Multimedia)
+diff -ur opentx-2.2.1/companion/src/modeledit/CMakeLists.txt opentx-2.2.1.fix/companion/src/modeledit/CMakeLists.txt
+--- opentx-2.2.1/companion/src/modeledit/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/companion/src/modeledit/CMakeLists.txt 2018-06-14 08:17:00.145716807 +0200
+@@ -60,5 +60,5 @@
+ qt5_wrap_cpp(modeledit_SRCS ${modeledit_HDRS})
+
+ add_library(modeledit ${modeledit_SRCS})
+-qt5_use_modules(modeledit Widgets Xml Multimedia)
+-target_link_libraries(modeledit PRIVATE ${CPN_COMMON_LIB})
++#qt5_use_modules(modeledit Widgets Xml Multimedia)
++target_link_libraries(modeledit PRIVATE ${CPN_COMMON_LIB} Qt5::Multimedia)
+diff -ur opentx-2.2.1/companion/src/shared/CMakeLists.txt opentx-2.2.1.fix/companion/src/shared/CMakeLists.txt
+--- opentx-2.2.1/companion/src/shared/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/companion/src/shared/CMakeLists.txt 2018-06-14 08:21:36.524073161 +0200
+@@ -19,4 +19,5 @@
+ qt5_wrap_cpp(shared_SRCS ${shared_HDRS})
+
+ add_library(shared ${shared_SRCS})
+-qt5_use_modules(shared Widgets)
+\ Geen regeleindeteken (LF) aan einde van bestand
++target_link_libraries(shared Qt5::Widgets)
++#qt5_use_modules(shared Widgets)
+diff -ur opentx-2.2.1/companion/src/simulation/CMakeLists.txt opentx-2.2.1.fix/companion/src/simulation/CMakeLists.txt
+--- opentx-2.2.1/companion/src/simulation/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/companion/src/simulation/CMakeLists.txt 2018-06-14 08:34:05.419295334 +0200
+@@ -92,4 +92,5 @@
+ qt5_wrap_cpp(simulation_SRCS ${simulation_HDRS})
+
+ add_library(simulation ${simulation_SRCS} ${simulation_HDRS})
+-qt5_use_modules(simulation Core Widgets Svg)
++target_link_libraries(simulation Qt5::Core Qt5::Widgets Qt5::Svg)
++#qt5_use_modules(simulation Core Widgets Svg)
+diff -ur opentx-2.2.1/companion/src/storage/CMakeLists.txt opentx-2.2.1.fix/companion/src/storage/CMakeLists.txt
+--- opentx-2.2.1/companion/src/storage/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/companion/src/storage/CMakeLists.txt 2018-06-14 08:22:04.997603631 +0200
+@@ -27,5 +27,5 @@
+ endforeach()
+
+ add_library(storage ${storage_SRCS})
+-qt5_use_modules(storage Core Xml Widgets)
+-target_link_libraries(storage PRIVATE ${CPN_COMMON_LIB})
++#qt5_use_modules(storage Core Xml Widgets)
++target_link_libraries(storage PRIVATE ${CPN_COMMON_LIB} Qt5::Core Qt5::Xml Qt5::Widgets)
+diff -ur opentx-2.2.1/companion/src/thirdparty/qcustomplot/CMakeLists.txt opentx-2.2.1.fix/companion/src/thirdparty/qcustomplot/CMakeLists.txt
+--- opentx-2.2.1/companion/src/thirdparty/qcustomplot/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/companion/src/thirdparty/qcustomplot/CMakeLists.txt 2018-06-14 08:17:48.509302945 +0200
+@@ -9,4 +9,5 @@
+ qt5_wrap_cpp(qcustomplot_SRCS ${qcustomplot_HDRS})
+
+ add_library(qcustomplot ${qcustomplot_SRCS})
+-qt5_use_modules(qcustomplot Widgets PrintSupport)
++#qt5_use_modules(qcustomplot Widgets PrintSupport)
++target_link_libraries(qcustomplot PRIVATE ${CPN_COMMON_LIB} Qt5::Widgets Qt5::PrintSupport)
+diff -ur opentx-2.2.1/radio/src/targets/simu/CMakeLists.txt opentx-2.2.1.fix/radio/src/targets/simu/CMakeLists.txt
+--- opentx-2.2.1/radio/src/targets/simu/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/radio/src/targets/simu/CMakeLists.txt 2018-06-14 08:18:34.846234636 +0200
+@@ -31,8 +31,8 @@
+ add_library(${SIMULATOR_TARGET} SHARED ${SIMULATOR_SRC})
+ add_dependencies(${SIMULATOR_TARGET} ${FIRMWARE_DEPENDENCIES})
+ target_compile_definitions(${SIMULATOR_TARGET} PUBLIC ${APP_COMMON_DEFINES}) # set in top-level CMakeLists
+- target_link_libraries(${SIMULATOR_TARGET} ${SDL_LIBRARY})
+- qt5_use_modules(${SIMULATOR_TARGET} Core)
++ #qt5_use_modules(${SIMULATOR_TARGET} Core)
++ target_link_libraries(${SIMULATOR_TARGET} ${SDL_LIBRARY} Qt5::Core)
+ add_custom_target(libsimulator DEPENDS ${SIMULATOR_TARGET})
+
+ # Prepare the "all-simu-libs" target to build simulator libraries for *every* supported PCB type (PCB_TYPES list)
+diff -ur opentx-2.2.1/radio/src/tests/CMakeLists.txt opentx-2.2.1.fix/radio/src/tests/CMakeLists.txt
+--- opentx-2.2.1/radio/src/tests/CMakeLists.txt 2017-12-17 10:07:54.000000000 +0100
++++ opentx-2.2.1.fix/radio/src/tests/CMakeLists.txt 2018-06-14 08:19:51.093371690 +0200
+@@ -38,9 +38,9 @@
+ use_cxx11() # ensure gnu++11 in CXX_FLAGS with CMake < 3.1
+
+ add_executable(gtests EXCLUDE_FROM_ALL ${TEST_SRC_FILES} ${CMAKE_CURRENT_SOURCE_DIR}/location.h ${RADIO_SRC} ../targets/simu/simpgmspace.cpp ../targets/simu/simueeprom.cpp ../targets/simu/simufatfs.cpp)
+- qt5_use_modules(gtests Core Widgets)
++ #qt5_use_modules(gtests Core Widgets)
+ add_dependencies(gtests ${FIRMWARE_DEPENDENCIES} gtests-lib)
+- target_link_libraries(gtests gtests-lib pthread)
++ target_link_libraries(gtests gtests-lib pthread Qt5::Core Qt5::Widgets)
+ message(STATUS "Added optional gtests target")
+ else()
+ message(WARNING "WARNING: gtests target will not be available (check that GTEST_INCDIR, GTEST_SRCDIR, and Qt5Widgets are configured).")