diff options
author | Fellype do Nascimento <fellype(at)gmail.com> | 2016-12-15 12:36:17 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2016-12-16 04:41:23 +0700 |
commit | 9347e82d80b73b1c1945973436f6882f924d3dcf (patch) | |
tree | 1129b12fd5dac758a2056164be91d15498c4ecac /academic | |
parent | 388361f667f157725eb62a3acb204e52b08d42c9 (diff) | |
download | slackbuilds-9347e82d80b73b1c1945973436f6882f924d3dcf.tar.gz |
academic/scidavis: Added (data analysis and visualization).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'academic')
-rw-r--r-- | academic/scidavis/README | 10 | ||||
-rw-r--r-- | academic/scidavis/correction_to_use_qwt5.patch | 15 | ||||
-rw-r--r-- | academic/scidavis/desktop_integration.txt | 36 | ||||
-rw-r--r-- | academic/scidavis/fix_wrong_values_on_parameters_errors.patch | 16 | ||||
-rw-r--r-- | academic/scidavis/scidavis.SlackBuild | 116 | ||||
-rw-r--r-- | academic/scidavis/scidavis.info | 10 | ||||
-rw-r--r-- | academic/scidavis/slack-desc | 19 |
7 files changed, 222 insertions, 0 deletions
diff --git a/academic/scidavis/README b/academic/scidavis/README new file mode 100644 index 0000000000..60a6565565 --- /dev/null +++ b/academic/scidavis/README @@ -0,0 +1,10 @@ +SciDAVis (data analysis and visualization) + +SciDAVis is a free interactive application aimed at data analysis and +publication-quality plotting. It combines a shallow learning curve and +an intuitive, easy-to-use graphical user interface with powerful +features such as scriptability and extensibility. + +SciDAVis started as a fork of QtiPlot. + +Optional dependencies are numpy and scipy (to improve python scripting) diff --git a/academic/scidavis/correction_to_use_qwt5.patch b/academic/scidavis/correction_to_use_qwt5.patch new file mode 100644 index 0000000000..3706a382e3 --- /dev/null +++ b/academic/scidavis/correction_to_use_qwt5.patch @@ -0,0 +1,15 @@ +--- config.pri 2016-07-28 22:17:44.000000000 -0300 ++++ config.pri.new 2016-12-12 16:43:50.000000000 -0200 +@@ -280,12 +280,8 @@ + + exists(/usr/include/qwt5) { + INCLUDEPATH += /usr/include/qwt5 +- exists(/usr/lib*/libqwt5.*) { + LIBS += -lqwt5 + } else { +- LIBS += -lqwt +- } +- } else { + INCLUDEPATH += /usr/include/qwt$${qwtsuff} + LIBS += -lqwt$${qwtsuff} + } diff --git a/academic/scidavis/desktop_integration.txt b/academic/scidavis/desktop_integration.txt new file mode 100644 index 0000000000..029fc66f83 --- /dev/null +++ b/academic/scidavis/desktop_integration.txt @@ -0,0 +1,36 @@ +###################### DESKTOP INTEGRATION ################################## + +unix { + desktop_entry.files = scidavis.desktop + desktop_entry.path = "$$INSTALLBASE/share/applications" + + mime_package.files = scidavis.xml + mime_package.path = "$$INSTALLBASE/share/mime/packages" + + #deprecated + mime_link.files = x-sciprj.desktop + mime_link.path = "$$INSTALLBASE/share/mimelnk/application" + + contains(INSTALLS, icons) { + # scalable icon + icons.files = icons/scidavis.svg + icons.path = "$$INSTALLBASE/share/icons/hicolor/scalable/apps" + + # hicolor icons for different resolutions + resolutions = 16 22 32 48 64 128 + for(res, resolutions) { + eval(icon_hicolor_$${res}.files = icons/hicolor-$${res}/scidavis.png) + eval(icon_hicolor_$${res}.path = "$$INSTALLBASE/share/icons/hicolor/$${res}x$${res}/apps") + INSTALLS += icon_hicolor_$${res} + } + + # locolor icons for different resolutions + resolutions = 16 22 32 + for(res, resolutions) { + eval(icon_locolor_$${res}.files = icons/locolor-$${res}/scidavis.png) + eval(icon_locolor_$${res}.path = "$$INSTALLBASE/share/icons/locolor/$${res}x$${res}/apps") + + INSTALLS += icon_locolor_$${res} + } + } +} diff --git a/academic/scidavis/fix_wrong_values_on_parameters_errors.patch b/academic/scidavis/fix_wrong_values_on_parameters_errors.patch new file mode 100644 index 0000000000..380ad4d6d8 --- /dev/null +++ b/academic/scidavis/fix_wrong_values_on_parameters_errors.patch @@ -0,0 +1,16 @@ +--- Fit.cpp 2016-07-28 22:17:44.000000000 -0300 ++++ Fit.cpp.new 2016-11-28 10:46:40.000000000 -0200 +@@ -127,9 +127,10 @@ + gsl_multifit_covar (s->J, 0.0, covar); + #else + { +- gsl_matrix J; +- gsl_multifit_fdfsolver_jac(s,&J); +- gsl_multifit_covar (&J, 0.0, covar); ++ gsl_matrix *J = gsl_matrix_alloc(d_n, d_p); ++ gsl_multifit_fdfsolver_jac(s,J); ++ gsl_multifit_covar (J, 0.0, covar); ++ gsl_matrix_free (J); + } + #endif + if (d_y_error_source == UnknownErrors) { diff --git a/academic/scidavis/scidavis.SlackBuild b/academic/scidavis/scidavis.SlackBuild new file mode 100644 index 0000000000..ee13ce7f97 --- /dev/null +++ b/academic/scidavis/scidavis.SlackBuild @@ -0,0 +1,116 @@ +#!/bin/sh + +# Slackware build script for SciDAVis +# Based on the Slackware 14.1 SlackBuild +# Written by Fellype do Nascimento <fellype(at)gmail.com> + +# +# 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. + +PRGNAM=scidavis +VERSION=${VERSION:-1.14} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i586 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686"; SLKLDFLAGS=""; LIBDIRSUFFIX=""; +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686"; SLKLDFLAGS=""; LIBDIRSUFFIX=""; +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC"; SLKLDFLAGS="-L/usr/lib64"; LIBDIRSUFFIX="64" +fi + + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +tar -zxvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION +chown -R root:root . + +# Correction needed in order to find qwtplot3d in its default path +grep -rl "qwtplot3d/" libscidavis/src/ | xargs sed -i "s:<qwtplot3d/:<:" + +# Correction needed in order to re-enable desktop integration +cat $CWD/desktop_integration.txt >> scidavis/basic.pri + +## Applying a patch on libscidavis/src/Fit.cpp in order to have correct values of parameters' errors generated by fit functions +patch -p1 < $CWD/fix_wrong_values_on_parameters_errors.patch libscidavis/src/Fit.cpp + +## Applying a patch in the config.pri file in order to build with the correct path for qwt5 +patch -p1 < $CWD/correction_to_use_qwt5.patch config.pri + +## For some unknown reason, to build in Slackware we need to run qmake twice in order to get icons working properly +## See https://sourceforge.net/p/scidavis/scidavis-bugs/259/ +qmake +qmake CONFIG+="liborigin python" PRESET=linux_package + +# Build and install: +LDFLAGS="$SLKLDFLAGS" \ +CFLAGS="$SLKCFLAGS" \ +CXXFLAGS="$SLKCFLAGS" \ +make +make install INSTALL_ROOT=$PKG + +## Sometimes 'make install' fails to install the translation files +mkdir -p $PKG/usr/share/scidavis/translations +cp scidavis/translations/*.qm $PKG/usr/share/scidavis/translations + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a README.md LICENSE $PKG/usr/doc/$PRGNAM-$VERSION +cp -a $PKG/usr/share/doc/scidavis/*.* $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +rm -rf $PKG/usr/share/doc + +( cd $PKG +find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true +find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true +find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs strip -g 2> /dev/null || true +) + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc +cat $CWD/slack-desc > $PKG/usr/doc/$PRGNAM-$VERSION/slack-desc + +mkdir -p $PKG/usr/man/man1 +docbook2man man/manpage.sgml -o $PKG/usr/man/man1/ +cp $PKG/usr/man/man1/SciDAVis.1 $PKG/usr/man/man1/scidavis.1 +gzip -9 $PKG/usr/man/man1/*.1 +rm $PKG/usr/man/man1/manpage.* + +if [ -e /usr/bin/requiredbuilder ]; then + requiredbuilder -v -y -s $CWD $PKG +fi + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} diff --git a/academic/scidavis/scidavis.info b/academic/scidavis/scidavis.info new file mode 100644 index 0000000000..853e5488be --- /dev/null +++ b/academic/scidavis/scidavis.info @@ -0,0 +1,10 @@ +PRGNAM="scidavis" +VERSION="1.14" +HOMEPAGE="http://scidavis.sourceforge.net/" +DOWNLOAD="http://downloads.sourceforge.net/project/scidavis/SciDAVis/1.14/scidavis-1.14.tar.gz" +MD5SUM="6b5fd39c17ed67cd64c77ac214099b2e" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="muParser qwt5 qwtplot3d" +MAINTAINER="Fellype do Nascimento" +EMAIL="fellype(at)gmail.com" diff --git a/academic/scidavis/slack-desc b/academic/scidavis/slack-desc new file mode 100644 index 0000000000..8d9b58c6ef --- /dev/null +++ b/academic/scidavis/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--------------------------------------------------------| +scidavis: scidavis (data analysis and visualization) +scidavis: +scidavis: SciDAVis is a free interactive application aimed at data analysis and +scidavis: publication-quality plotting. It combines a shallow learning curve and +scidavis: an intuitive, easy-to-use graphical user interface with powerful +scidavis: features such as scriptability and extensibility. +scidavis: +scidavis: +scidavis: For more information visit http://scidavis.sourceforge.net/ +scidavis: +scidavis: |