summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author William PC <w_calandrini[at]hotmail[dot]com>2022-10-15 03:56:43 +0100
committer Willy Sudiarto Raharjo <willysr@slackbuilds.org>2022-10-15 10:47:38 +0700
commit03f969c1802f301a525ed3f4ac6cec7a1455d983 (patch)
tree79149570d7c192248682b611da0cba542cd26da1
parent5f82b7ab0e070a3acb8c9da2c7ceea08ff909391 (diff)
downloadslackbuilds-03f969c1802f301a525ed3f4ac6cec7a1455d983.tar.gz
slackbuilds-03f969c1802f301a525ed3f4ac6cec7a1455d983.tar.xz
academic/voro++: Added (A 3D Voronoi cell software library)
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
-rw-r--r--academic/voro++/README7
-rw-r--r--academic/voro++/slack-desc19
-rw-r--r--academic/voro++/voro++.SlackBuild118
-rw-r--r--academic/voro++/voro++.info10
4 files changed, 154 insertions, 0 deletions
diff --git a/academic/voro++/README b/academic/voro++/README
new file mode 100644
index 0000000000..886a2a1030
--- /dev/null
+++ b/academic/voro++/README
@@ -0,0 +1,7 @@
+ Voro++ is a software library for carrying out three-dimensional
+computations of the Voronoi tessellation. A distinguishing feature of
+the Voro++ library is that it carries out cell-based calculations,
+computing the Voronoi cell for each particle individually. It is
+particularly well-suited for applications that rely on cell-based
+statistics, where features of Voronoi cells (eg. volume, centroid,
+number of faces) can be used to analyze a system of particles.
diff --git a/academic/voro++/slack-desc b/academic/voro++/slack-desc
new file mode 100644
index 0000000000..a0482548d5
--- /dev/null
+++ b/academic/voro++/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description.
+# Line up the first '|' above the ':' following the base package name, and
+# the '|' on the right side marks the last column you can put a character in.
+# You must make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':' except on otherwise blank lines.
+
+ |-----handy-ruler------------------------------------------------------|
+voro++: voro++ (A 3D Voronoi cell software library)
+voro++:
+voro++: Voro++ is a software library for carrying out three-dimensional
+voro++: computations of the Voronoi tessellation. A distinguishing feature of
+voro++: the Voro++ library is that it carries out cell-based calculations,
+voro++: computing the Voronoi cell for each particle individually. It is
+voro++: particularly well-suited for applications that rely on cell-based
+voro++: statistics, where features of Voronoi cells (eg. volume, centroid,
+voro++: number of faces) can be used to analyze a system of particles.
+voro++:
+voro++:
diff --git a/academic/voro++/voro++.SlackBuild b/academic/voro++/voro++.SlackBuild
new file mode 100644
index 0000000000..563f9f3e56
--- /dev/null
+++ b/academic/voro++/voro++.SlackBuild
@@ -0,0 +1,118 @@
+#!/bin/bash
+
+# Slackware build script for voro++
+
+# Copyright 2022 William PC - Seattle, USA
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+cd $(dirname $0) ; CWD=$(pwd)
+
+PRGNAM=voro++
+VERSION=${VERSION:-0.4.6}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i586 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+cd $PRGNAM-$VERSION
+chown -R root:root .
+find -L . \
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+
+
+# the default make build the examples
+# let's keep source only
+sed -i '15s/^/#/;24s/^/#/' Makefile
+
+# comment the include line of example's Makefiles
+# then add the right path for include files
+sed -i 's/^include ../#&/; /#include/aE_INC=-I/usr/include/voro++' examples/*/Makefile
+
+CFLAGS="$SLKCFLAGS" \
+CXXFLAGS="$SLKCFLAGS" \
+make
+make install PREFIX=$PKG/usr
+
+mkdir -p $PKG/usr/share/$PRGNAM-$VERSION
+cp -a examples $PKG/usr/share/$PRGNAM-$VERSION
+cp -a scripts $PKG/usr/share/$PRGNAM-$VERSION
+
+find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+
+find $PKG/usr/man -type f -exec gzip -9 {} \;
+for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a \
+ LICENSE html \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+chmod 755 $PKG/usr/doc/$PRGNAM-$VERSION/html
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE
diff --git a/academic/voro++/voro++.info b/academic/voro++/voro++.info
new file mode 100644
index 0000000000..0bfd5007a7
--- /dev/null
+++ b/academic/voro++/voro++.info
@@ -0,0 +1,10 @@
+PRGNAM="voro++"
+VERSION="0.4.6"
+HOMEPAGE="https://crd.lbl.gov/divisions/amcr/mathematics-dept/math/software/voro-a-three-dimensional-voronoi-library-in-c/"
+DOWNLOAD="https://math.lbl.gov/voro++/download/dir/voro++-0.4.6.tar.gz"
+MD5SUM="2338b824c3b7b25590e18e8df5d68af9"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+REQUIRES=""
+MAINTAINER="William PC"
+EMAIL="w_calandrini[at]hotmail[dot]com"