Browse Source

xap/compucell3d: Upgraded to compucell3d-4.1.0.

current-20191101
Damien Goutte-Gattat 2 years ago
parent
commit
f6c98100e6
  1. 40
      xap/compucell3d/compucell3d.SlackBuild
  2. 1
      xap/compucell3d/swig-3.0.12.tar.gz.sha256

40
xap/compucell3d/compucell3d.SlackBuild

@ -1,6 +1,6 @@
#!/bin/bash
# Build script for Slackware
# Copyright (C) 2018 Damien Goutte-Gattat
# Copyright (C) 2018,2019 Damien Goutte-Gattat
#
# Redistribution and use of this script, with or without modifications,
# is permitted provided that the following conditions are met:
@ -25,13 +25,14 @@
# Latest CompuCell3D sourcecode is available at:
# <http://www.compucell3d.org/>.
#
# Depends: l/PyQt5, l/vtk, l/pyqtgraph, l/qscintilla
# Depends: l/PyQt5, l/pyqtgraph, l/python-deprecated, l/qscintilla
# Depends: l/vtk
# Source package infos
NAMESRC=${NAMESRC:-CompuCell3D}
VERSION=${VERSION:-20180916}
VERSION=${VERSION:-4.1.0}
REPOSITORY=${REPOSITORY:-https://github.com/CompuCell3D/CompuCell3D.git}
COMMIT=${COMMIT:-48c9ca56be7ad07cebcfd5a4048fa25bd0ae8854}
COMMIT=${COMMIT:-a30b3ba216b4564898796e1b90fcafb60a87698e}
ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION.tar.gz}
# Build infos
@ -84,6 +85,27 @@ if [ ! -r $ARCHIVE ]; then
rm -rf CompuCell3D
fi
# As of version 4.1.0, CompuCell3D cannot be properly built with
# Swig 4.0.1 as provided by Slackware due to some changes in the
# way Swig generates the Python code. The -olddefs flag, supposed
# to "keep the old method definitions", is of no help. Until the
# CompuCell3D devs update their code for Swig 4, or until the
# Swig developers decide to care about backwards compatibility,
# it seems the only solution is to build CompuCell3d with an
# old Swig 3, which we will do here.
if [ ! -r swig-3.0.12.tar.gz ]; then
wget -c -O swig-3.0.12.tar.gz.part https://downloads.sourceforge.net/project/swig/swig/swig-3.0.12/swig-3.0.12.tar.gz
mv swig-3.0.12.tar.gz.part swig-3.0.12.tar.gz
fi
sha256sum -c swig-3.0.12.tar.gz.sha256
cd $TMP
echo "Building swig-3.0.12.tar.gz..."
tar xf $CWD/swig-3.0.12.tar.gz
cd swig-3.0.12
./configure --prefix=$TMP/swig-for-compucell3d --disable--alllang --with-python3
make -j $JOBS
make install
# Compile
cd $TMP
echo "Building $ARCHIVE..."
@ -95,7 +117,8 @@ cmake \
-DCMAKE_INSTALL_PREFIX=/opt/compucell3d \
-DBUILD_PYINTERFACE=ON \
-DBUILD_QT_WRAPPERS=OFF \
-DCMAKE_CXX_FLAGS="$CPUOPT -std=c++11 -DVTK6" \
-DCMAKE_CXX_FLAGS="$CPUOPT -fpermissive" \
-DSWIG_EXECUTABLE=$TMP/swig-for-compucell3d/bin/swig \
..
make -j $JOBS
make install/strip DESTDIR=$PKG
@ -108,7 +131,7 @@ install -m 755 $CWD/twedit++.sh $PKG/usr/bin/twedit++
# Install the documentation
mkdir -p $PKG/usr/doc/$NAME
install -m 644 ChangeLog.txt README-Linux.txt ReleaseNotes.rst \
docs/CompuCell3D_release_notes.pdf $PKG/usr/doc/$NAME
$PKG/usr/doc/$NAME
# Install desktop files
install -D -m 644 $CWD/compucell3d.desktop $PKG/usr/share/applications/compucell3d.desktop
@ -121,9 +144,10 @@ install -m 755 $CWD/doinst.sh $PKG/install/doinst.sh
# Add dependency infos
cat <<EOF > $PKG/install/slack-required
PyQt5
vtk
pyqtgraph
python-deprecated
qscintilla
vtk
EOF
# Package the tree
@ -133,7 +157,7 @@ PACKAGING="
chown root:root . -R
/sbin/makepkg -l y -c n $OUT/$NAMEPKG-$VERSION-$ARCH-$BUILD.$EXT
rm -rf $PKG
rm -rf $TMP/$NAME
rm -rf $TMP/$NAME $TMP/swig-3.0.12 $TMP/swig-for-compucell3d
"
if type -p fakeroot ; then
echo "$PACKAGING" | fakeroot

1
xap/compucell3d/swig-3.0.12.tar.gz.sha256

@ -0,0 +1 @@
7cf9f447ae7ed1c51722efc45e7f14418d15d7a1e143ac9f09a668999f4fc94d swig-3.0.12.tar.gz
Loading…
Cancel
Save