summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorGabriel Chamon Araujo2021-06-24 16:12:00 -0300
committerGabriel Chamon Araujo2021-06-24 16:12:00 -0300
commit57f3e2762ae1958a168ca048488c83da8dfe21d0 (patch)
tree89e873f75217ef83a56fcdef9c1171d5e7168b99
parent8914adc31ec2ef103b87a554064b73d03b8c4d08 (diff)
downloadaur-57f3e2762ae1958a168ca048488c83da8dfe21d0.tar.gz
add contribution from Antonio Cervone; bump to 4.8.0
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD52
-rw-r--r--gcc11.patch22
3 files changed, 55 insertions, 21 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 11252e4faabc..b86b519b3c83 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = magics++
pkgdesc = Magics is the latest generation of the ECMWF's Meteorological plotting software MAGICS.
- pkgver = 4.6.0
+ pkgver = 4.8.0
pkgrel = 0
url = https://software.ecmwf.int/wiki/display/MAGP
arch = i686
diff --git a/PKGBUILD b/PKGBUILD
index ac7eef0649bc..71988287443a 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,43 +1,55 @@
# Maintainer: Gabriel Chamon Araujo <gchamon@live.com>
# Contributor: Anton Bazhenov <anton.bazhenov at gmail>
# Contributor: Graziano Giuliani <graziano.giuliani@poste.it>
+# Contributor: Antonio Cervone <ant.cervone@gmail.com>
pkgname=magics++
Pkgname=Magics
-pkgver=4.6.0
+pkgver=4.8.0
_attnum=3473464
pkgrel=0
pkgdesc="Magics is the latest generation of the ECMWF's Meteorological plotting software MAGICS."
arch=('i686' 'x86_64')
url="https://software.ecmwf.int/wiki/display/MAGP"
license=('Apache')
-depends=('qt5-base' 'proj' 'fftw' 'pango' 'netcdf-cxx-legacy' 'eccodes' 'python' 'libgeotiff')
-optdepends=('libaec' 'odb_api')
-makedepends=('perl-xml-parser' 'gcc-fortran' 'swig' 'python2-numpy' 'cmake' 'boost' 'emos' 'python-jinja')
-source=(http://software.ecmwf.int/wiki/download/attachments/${_attnum}/${Pkgname}-${pkgver}-Source.tar.gz)
-md5sums=('570d9888fc794b7c72c0a09fc9210dc3')
+depends=('eccodes>=2.19.0' qt5-base pango proj python)
+optdepends=(ksh libaec odb_api)
+makedepends=(cmake gcc-fortran perl-xml-parser python-jinja swig)
+source=(http://software.ecmwf.int/wiki/download/attachments/${_attnum}/${Pkgname}-${pkgver}-Source.tar.gz
+ gcc11.patch)
+sha256sums=('4786ab79fcd5ca5fc10ababfb8a1d58e5078b8a7246b81c9fba53b7443bf46c0'
+ 'c0250ac473b4703e79c8f879f6271d1409e800a0f8a7a77b3793cc9ce9a85951')
+
+prepare() {
+ cd "${Pkgname}-${pkgver}-Source"
+ patch --forward --strip=1 --input=$srcdir/gcc11.patch
+}
build() {
- cd "$srcdir/${Pkgname}-${pkgver}-Source"
- rm -fr src/boost && ln -sf /usr/include/boost src
[ -x /usr/bin/odb ] && has_odb=ON || has_odb=OFF
# force this for now. Metview does not compile
has_odb=OFF
- mkdir -p build
- cd build
- CC=gcc CXX='g++' \
- cmake -DCMAKE_LINKER_FLAGS="-pthread" \
+
+ cmake \
+ -B build \
+ -S "${Pkgname}-${pkgver}-Source" \
+ -DCMAKE_LINKER_FLAGS="-pthread" \
-DCMAKE_SHARED_LINKER_FLAGS="-pthread" \
- -DCMAKE_EXE_LINKER_FLAGS="-pthread" -DENABLE_ODB=${has_odb} \
- -DGEOTIFF_PATH=/usr -Dodb_api_DIR=/usr/share/odb_api/cmake \
- -DCMAKE_CXX_COMPILER=g++ -DCMAKE_CC_COMPILER=gcc \
- -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=production \
+ -DCMAKE_EXE_LINKER_FLAGS="-pthread" \
+ -DENABLE_ODB=${has_odb} \
+ -DGEOTIFF_PATH=/usr \
+ -Dodb_api_DIR=/usr/share/odb_api/cmake \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_BUILD_TYPE=production \
-DCMAKE_INSTALL_DATADIR=/usr/share \
- -DENABLE_METVIEW=1 -DENABLE_QT5=1 -DPYTHON_EXECUTABLE=/usr/bin/python3 ..
- make || return 1
+ -DENABLE_METVIEW=1 \
+ -DENABLE_QT5=1 \
+ -DPYTHON_EXECUTABLE=/usr/bin/python3
+
+ make -C build
}
package() {
- cd "$srcdir/${Pkgname}-${pkgver}-Source/build"
- make DESTDIR="$pkgdir" install || return 1
+ make -C build DESTDIR="$pkgdir" install
}
+
diff --git a/gcc11.patch b/gcc11.patch
new file mode 100644
index 000000000000..2cc145e1f8ff
--- /dev/null
+++ b/gcc11.patch
@@ -0,0 +1,22 @@
+diff -u -ur Magics-4.8.0-Source-orig/src/common/Transformation.cc Magics-4.8.0-Source/src/common/Transformation.cc
+--- Magics-4.8.0-Source-orig/src/common/Transformation.cc 2021-05-28 12:11:36.730390748 +0200
++++ Magics-4.8.0-Source/src/common/Transformation.cc 2021-05-28 12:12:37.981234331 +0200
+@@ -14,6 +14,7 @@
+
+ #include "Transformation.h"
+ #include <iomanip>
++#include <limits>
+ #include "BasicGraphicsObject.h"
+ #include "Layout.h"
+ #include "MatrixHandler.h"
+diff -u -ur Magics-4.8.0-Source-orig/src/visualisers/SimplePolylineVisualiser.cc Magics-4.8.0-Source/src/visualisers/SimplePolylineVisualiser.cc
+--- Magics-4.8.0-Source-orig/src/visualisers/SimplePolylineVisualiser.cc 2021-05-28 12:11:36.713723847 +0200
++++ Magics-4.8.0-Source/src/visualisers/SimplePolylineVisualiser.cc 2021-05-28 12:16:53.764425882 +0200
+@@ -19,6 +19,7 @@
+
+ */
+
++#include <limits>
+ #include "SimplePolylineVisualiser.h"
+ #include "Data.h"
+ #include "LegendVisitor.h"