summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorm-pilia2018-04-03 14:53:52 +0200
committerm-pilia2018-04-03 14:53:52 +0200
commit9cd0faca3cdb1b55a5f4996f92631e1107d2759f (patch)
tree6a1c414cf842b9e129d096344602f7f12c12a313
parentb454385eda854c56bf5787c5024b00aca18683e0 (diff)
downloadaur-9cd0faca3cdb1b55a5f4996f92631e1107d2759f.tar.gz
Improvements to the packaging
+ remove previous build folder if present + use the system freetype2 library + ensure that the extraction did not fail
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD15
2 files changed, 15 insertions, 2 deletions
diff --git a/.SRCINFO b/.SRCINFO
index e4a37d3d57f1..b51990b019c7 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = salome-meca-bin
pkgdesc = Integration of the Code_Aster solver in the Salome platform
pkgver = 2017.0.2
- pkgrel = 4
+ pkgrel = 5
url = https://www.code-aster.org/spip.php?article303
arch = x86_64
license = LGPL
diff --git a/PKGBUILD b/PKGBUILD
index 40e218e1f4a9..82694781e8b4 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,7 +1,7 @@
# Maintainer of this PKBGUILD file: Martino Pilia <martino.pilia@gmail.com>
pkgname=salome-meca-bin
pkgver=2017.0.2
-pkgrel=4
+pkgrel=5
pkgdesc='Integration of the Code_Aster solver in the Salome platform'
arch=('x86_64')
url='https://www.code-aster.org/spip.php?article303'
@@ -19,6 +19,9 @@ build() {
echo "Extracting installer..."
+ # remove previous build folder if present, otherwise the installer will fail
+ rm -rf ${srcdir}/salome_meca || :
+
# self-extract
./Salome-Meca-2017.0.2-LGPL-1.run &> /dev/null <<-EOF
${srcdir}/salome_meca
@@ -34,6 +37,10 @@ build() {
# use the bundled version of python
export PATH="${srcdir}/salome_meca/V2017.0.2/prerequisites/Python-2710/bin/":$PATH
+ # try using the system freetype2 library
+ # update to freetype2 2.8 breaks the bundled version
+ rm "${srcdir}/salome_meca/V2017.0.2/prerequisites/Freetype-2411"/lib/libfreetype.so*
+
echo "Building virtual application..."
# create virtual application
@@ -42,6 +49,12 @@ build() {
${srcdir}/salome_meca/appli_V2017.0.2
EOF
+ # ensure that the extraction did not fail
+ if [ ! -e "${srcdir}/salome_meca/appli_V2017.0.2/salome" ]; then
+ error "Extraction of the application failed, please check '${srcdir}/salome_meca/appli_V2017.0.2/appli_V2017.0.2.log' for relevant error messages."
+ exit 1
+ fi
+
# create .desktop file from template
# use the bundled libraries and Python version
_path='PATH=/opt/salome_meca/V2017.0.2/prerequisites/Python-2710/bin/:$PATH'