diff options
author | schnetter <schnetter@9e23cc15-e5c8-4d65-9080-beda90ea645b> | 2009-09-28 18:20:08 +0000 |
---|---|---|
committer | schnetter <schnetter@9e23cc15-e5c8-4d65-9080-beda90ea645b> | 2009-09-28 18:20:08 +0000 |
commit | b898a4e8e9d4816362505cc2f674f142404669d3 (patch) | |
tree | 7c20ddc3bae8a7aaf70b0e26b683aa50b30bc387 | |
parent | 776fc43af031376ccd9e8247adba688e835e71b2 (diff) |
Add thorn containing the GSL library
git-svn-id: http://svn.cactuscode.org/projects/ExternalLibraries/GSL/trunk@2 9e23cc15-e5c8-4d65-9080-beda90ea645b
-rw-r--r-- | GSL.sh | 85 | ||||
-rw-r--r-- | README | 22 | ||||
-rw-r--r-- | configuration.ccl | 8 | ||||
-rw-r--r-- | dist/gsl-1.12.tar.gz | bin | 0 -> 2924732 bytes | |||
-rw-r--r-- | interface.ccl | 3 | ||||
-rw-r--r-- | param.ccl | 1 | ||||
-rw-r--r-- | schedule.ccl | 1 | ||||
-rw-r--r-- | src/make.code.defn | 7 |
8 files changed, 127 insertions, 0 deletions
@@ -0,0 +1,85 @@ +#! /bin/bash + +################################################################################ +# Prepare +################################################################################ + +# Set up shell +set -x # Output commands +set -e # Abort on errors + +# Set locations +NAME=gsl-1.12 +SRCDIR=$(dirname $0) +INSTALL_DIR=${SCRATCH_BUILD} +GSL_DIR=${INSTALL_DIR}/${NAME} + +# Clean up environment +unset LIBS + + + +################################################################################ +# Build +################################################################################ + +( + exec >&2 # Redirect stdout to stderr + set -x # Output commands + set -e # Abort on errors + cd ${INSTALL_DIR} + if [ -e done-${NAME} -a done-${NAME} -nt ${SRCDIR}/dist/${NAME}.tar.gz ]; then + echo "GSL: The enclosed GSL library has already been built; doing nothing" + else + echo "GSL: Building enclosed GSL library" + + echo "GSL: Unpacking archive..." + rm -rf build-${NAME} + mkdir build-${NAME} + pushd build-${NAME} + # Should we use gtar or tar? + TAR=$(gtar --help > /dev/null 2> /dev/null && echo gtar || echo tar) + ${TAR} xzf ${SRCDIR}/dist/${NAME}.tar.gz + popd + + echo "GSL: Configuring..." + rm -rf ${NAME} + mkdir ${NAME} + pushd build-${NAME}/${NAME} + ./configure --prefix=${GSL_DIR} + + echo "GSL: Building..." + make + + echo "GSL: Installing..." + make install + popd + + : > done-${NAME} + echo "GSL: Done." + fi +) + + + +################################################################################ +# Configure Cactus +################################################################################ + +# Set options +GSL_INC_DIRS="${GSL_DIR}/include" +GSL_LIB_DIRS="${GSL_DIR}/lib" +GSL_LIBS='gsl gslcblas' + +# Pass options to Cactus +echo "BEGIN MAKE_DEFINITION" +echo "HAVE_GSL = 1" +echo "GSL_DIR = ${GSL_DIR}" +echo "GSL_INC_DIRS = ${GSL_INC_DIRS}" +echo "GSL_LIB_DIRS = ${GSL_LIB_DIRS}" +echo "GSL_LIBS = ${GSL_LIBS}" +echo "END MAKE_DEFINITION" + +echo 'INCLUDE_DIRECTORY $(GSL_INC_DIRS)' +echo 'LIBRARY_DIRECTORY $(GSL_LIB_DIRS)' +echo 'LIBRARY $(GSL_LIBS)' @@ -0,0 +1,22 @@ +Cactus Code Thorn GSL +Author(s) : Erik Schnetter +Maintainer(s): Cactus team +Licence : GPL +-------------------------------------------------------------------------- + +1. Purpose + +Distribute the GNU Scientific Library; see +<http://www.gnu.org/software/gsl/>. + + + +From the web site: + +The GNU Scientific Library (GSL) is a numerical library for C and C++ +programmers. It is free software under the GNU General Public +License. + +The library provides a wide range of mathematical routines such as +random number generators, special functions and least-squares fitting. +There are over 1000 functions in total with an extensive test suite. diff --git a/configuration.ccl b/configuration.ccl new file mode 100644 index 0000000..13ff6f4 --- /dev/null +++ b/configuration.ccl @@ -0,0 +1,8 @@ +# Configuration definitions for thorn GSL +# $Header$ + +PROVIDES GSL +{ + SCRIPT GSL.sh + LANG bash +} diff --git a/dist/gsl-1.12.tar.gz b/dist/gsl-1.12.tar.gz Binary files differnew file mode 100644 index 0000000..01d3577 --- /dev/null +++ b/dist/gsl-1.12.tar.gz diff --git a/interface.ccl b/interface.ccl new file mode 100644 index 0000000..d4f9312 --- /dev/null +++ b/interface.ccl @@ -0,0 +1,3 @@ +# Interface definition for thorn GSL + +IMPLEMENTS: GSL diff --git a/param.ccl b/param.ccl new file mode 100644 index 0000000..fc02c04 --- /dev/null +++ b/param.ccl @@ -0,0 +1 @@ +# Parameter definitions for thorn GSL diff --git a/schedule.ccl b/schedule.ccl new file mode 100644 index 0000000..65301e7 --- /dev/null +++ b/schedule.ccl @@ -0,0 +1 @@ +# Schedule definitions for thorn GSL diff --git a/src/make.code.defn b/src/make.code.defn new file mode 100644 index 0000000..2f14a8d --- /dev/null +++ b/src/make.code.defn @@ -0,0 +1,7 @@ +# Main make.code.defn file for thorn GSL + +# Source files in this directory +SRCS = + +# Subdirectories containing source files +SUBDIRS = |