academic/OpenFOAM: Updated for version 6.

Signed-off-by: David Spencer <idlemoor@slackbuilds.org>
This commit is contained in:
Lorenzo Trevisan 2018-07-16 19:39:40 +01:00 committed by Willy Sudiarto Raharjo
parent 19e983380b
commit eb1f6670bf
No known key found for this signature in database
GPG Key ID: 887B8374D7333381
5 changed files with 19 additions and 20 deletions

View File

@ -2,7 +2,7 @@
# Slackware build script for OpenFOAM
# Copyright 2017 Lorenzo Trevisan, Caorle, Venice, Italy
# Copyright 2017, 2018 Lorenzo Trevisan, Caorle, Venice, Italy
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@ -23,12 +23,10 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=OpenFOAM
VERSION=${VERSION:-5.0}
VERSION=${VERSION:-6}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
XVER=${VERSION%%.*}.x
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) ARCH=i586 ;;
@ -49,10 +47,10 @@ mkdir -p $TMP $PKG $OUTPUT
cd $PKG
mkdir -p opt/$PRGNAM
cd $PKG/opt/$PRGNAM
tar xvf $CWD/$PRGNAM-$XVER-version-$VERSION.tar.gz
mv $PRGNAM-$XVER-version-$VERSION $PRGNAM-$VERSION
tar xvf $CWD/ThirdParty-$XVER-version-$VERSION.tar.gz
mv ThirdParty-$XVER-version-$VERSION ThirdParty-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION-version-$VERSION.tar.gz
mv $PRGNAM-$VERSION-version-$VERSION $PRGNAM-$VERSION
tar xvf $CWD/ThirdParty-$VERSION-version-$VERSION.tar.gz
mv ThirdParty-$VERSION-version-$VERSION ThirdParty-$VERSION
chown -R root:root .
find -L . \
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
@ -62,10 +60,7 @@ find -L . \
cd $PRGNAM-$VERSION
sed -i -e '16s=-lreadline=-lreadline -lncurses=' ./applications/utilities/mesh/manipulation/setSet/Allwmake
sed -i -e '47s=$HOME=/opt=' ./etc/bashrc
# Fix bash_completion for posixly-incorrect identifier
sed -i -e 's/rm~all/rmAll/g' etc/config.sh/bash_completion
# "Allwmake" below doesn't accept MAKEFLAGS. If MAKEFLAGS contains a -j option,
# extract the number of jobs and export it for "Allwmake". (Thanks to Chris Willing)
@ -78,7 +73,9 @@ jval="$(echo $MAKEFLAGS |grep -o "\-j *[0-9]*" | grep -o "[0-9]*")" || true
./Allwmake
# check for graphviz
if [ -x /usr/bin/dot ]; then
wmake all doc
cd $WM_PROJECT_DIR/doc/Doxygen
./Allwmake
cd $WM_PROJECT_DIR
fi
)

View File

@ -1,10 +1,10 @@
PRGNAM="OpenFOAM"
VERSION="5.0"
VERSION="6"
HOMEPAGE="https://openfoam.org/"
DOWNLOAD="https://github.com/OpenFOAM/OpenFOAM-5.x/archive/version-5.0/OpenFOAM-5.x-version-5.0.tar.gz \
https://github.com/OpenFOAM/ThirdParty-5.x/archive/version-5.0/ThirdParty-5.x-version-5.0.tar.gz"
MD5SUM="cd8c5bdd3ff39c34f61747c8e55f59d1 \
76d619a8c79eae38baed2e08305eb923"
DOWNLOAD="https://github.com/OpenFOAM/OpenFOAM-6/archive/version-6/OpenFOAM-6-version-6.tar.gz \
https://github.com/OpenFOAM/ThirdParty-6/archive/version-6/ThirdParty-6-version-6.tar.gz"
MD5SUM="f40aa39d4d5dfe7ea8d9a58f2625037a \
848652a3eaf8a1a7e17a7ad9655a123c"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="openmpi CGAL"

View File

@ -1 +1 @@
. /opt/OpenFOAM/OpenFOAM-5.0/etc/bashrc
. /opt/OpenFOAM/OpenFOAM-6/etc/bashrc

View File

@ -4,7 +4,9 @@ suppression in buildings, involving combustion, chemical reactions,
heat transfer, liquid sprays and films. It includes tools for meshing
in and around complex geometries (e.g. a vehicle), and for data
processing and visualisation, and more. Almost all computations can be
executed in parallel as standard to take full advantage of todays
executed in parallel as standard to take full advantage of today's
multi-core processors and multi-processor computers.
Optional dependency: graphviz (for documentation with graphs)
You can build with multiple jobs by setting the MAKEFLAGS environment variable.

View File

@ -14,6 +14,6 @@ OpenFOAM: suppression in buildings, involving combustion, chemical reactions,
OpenFOAM: heat transfer, liquid sprays and films. It includes tools for meshing
OpenFOAM: in and around complex geometries (e.g. a vehicle), and for data
OpenFOAM: processing and visualisation, and more. Almost all computations can be
OpenFOAM: executed in parallel as standard to take full advantage of todays
OpenFOAM: executed in parallel as standard to take full advantage of today's
OpenFOAM: multi-core processors and multi-processor computers.
OpenFOAM: