diff options
author | Sebastien Fabbro <bicatali@gentoo.org> | 2012-02-01 17:43:25 +0000 |
---|---|---|
committer | Sebastien Fabbro <bicatali@gentoo.org> | 2012-02-01 17:43:25 +0000 |
commit | 9137936cc2dab5ddea386c0c3412e1601030cede (patch) | |
tree | 39422ee78ed63847e3a8779a88fb3a240174c705 /dev-lang/gdl | |
parent | Marking qu-prolog-9.1 ppc for bug 398815 (diff) | |
download | gentoo-2-9137936cc2dab5ddea386c0c3412e1601030cede.tar.gz gentoo-2-9137936cc2dab5ddea386c0c3412e1601030cede.tar.bz2 gentoo-2-9137936cc2dab5ddea386c0c3412e1601030cede.zip |
Added a test for openmp, install pro routines in default directory (/usr/shared/gnudatalanguage/lib), bug #401703 thanks Ben Kohler, and force libX11 dependency since it does not compile without
(Portage version: 2.1.10.41/cvs/Linux x86_64)
Diffstat (limited to 'dev-lang/gdl')
-rw-r--r-- | dev-lang/gdl/ChangeLog | 11 | ||||
-rw-r--r-- | dev-lang/gdl/gdl-0.9.2-r1.ebuild | 132 |
2 files changed, 141 insertions, 2 deletions
diff --git a/dev-lang/gdl/ChangeLog b/dev-lang/gdl/ChangeLog index e7197462932d..3294c084a5f2 100644 --- a/dev-lang/gdl/ChangeLog +++ b/dev-lang/gdl/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for dev-lang/gdl -# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-lang/gdl/ChangeLog,v 1.26 2011/12/27 08:01:38 bicatali Exp $ +# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/dev-lang/gdl/ChangeLog,v 1.27 2012/02/01 17:43:25 bicatali Exp $ + +*gdl-0.9.2-r1 (01 Feb 2012) + + 01 Feb 2012; Sébastien Fabbro <bicatali@gentoo.org> +gdl-0.9.2-r1.ebuild: + Added a test for openmp, install pro routines in default directory + (/usr/shared/gnudatalanguage/lib), bug #401703 thanks Ben Kohler, and force + libX11 dependency since it does not compile without *gdl-0.9.2 (27 Dec 2011) diff --git a/dev-lang/gdl/gdl-0.9.2-r1.ebuild b/dev-lang/gdl/gdl-0.9.2-r1.ebuild new file mode 100644 index 000000000000..a9a2eab6e0da --- /dev/null +++ b/dev-lang/gdl/gdl-0.9.2-r1.ebuild @@ -0,0 +1,132 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-lang/gdl/gdl-0.9.2-r1.ebuild,v 1.1 2012/02/01 17:43:25 bicatali Exp $ + +EAPI=4 + +WX_GTK_VER="2.8" +PYTHON_DEPEND="python? 2" +SUPPORT_PYTHON_ABIS="1" + +inherit cmake-utils eutils wxwidgets python virtualx + +RESTRICT_PYTHON_ABIS="3.*" + +DESCRIPTION="Interactive Data Language compatible incremental compiler" +HOMEPAGE="http://gnudatalanguage.sourceforge.net/" +SRC_URI="mirror://sourceforge/gnudatalanguage/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="fftw grib gshhs hdf hdf5 imagemagick netcdf openmp proj ps python + static-libs udunits wxwidgets X" + +RDEPEND="sci-libs/gsl + sci-libs/plplot + sys-libs/ncurses + sys-libs/readline + sys-libs/zlib + x11-libs/libX11 + fftw? ( >=sci-libs/fftw-3 ) + grib? ( sci-libs/grib_api ) + gshhs? ( sci-geosciences/gshhs-data sci-geosciences/gshhs ) + hdf? ( sci-libs/hdf ) + hdf5? ( sci-libs/hdf5 ) + imagemagick? ( media-gfx/imagemagick ) + netcdf? ( sci-libs/netcdf ) + proj? ( sci-libs/proj ) + ps? ( dev-libs/pslib ) + python? ( dev-python/numpy ) + udunits? ( sci-libs/udunits ) + wxwidgets? ( x11-libs/wxGTK:2.8[X] )" + +DEPEND="${RDEPEND} + >=dev-java/antlr-2.7.7-r5:0[cxx]" + +pkg_setup() { + use wxwidgets && wxwidgets_pkg_setup + use python && python_pkg_setup + use openmp && [[ $(tc-getCXX)$ == *g++* ]] && ! tc-has-openmp && \ + die "You have openmp enabled but your current g++ does not support it" +} + +src_prepare() { + use hdf5 && has_version sci-libs/hdf5[mpi] && export CXX=mpicxx + epatch "${FILESDIR}"/${PV}-{antlr,numpy,proj4,include,tests}.patch + # make sure antlr includes are from system + rm -rf src/antlr + # gentoo: use proj instead of libproj4 (libproj4 last update: 2004) + sed -i \ + -e 's:proj4:proj:' \ + -e 's:lib_proj\.h:proj_api\.h:g' \ + CMakeModules/FindLibproj4.cmake src/math_utl.hpp || die + # gentoo: avoid install files in datadir directory + sed -i \ + -e '/AUTHORS/d' \ + CMakeLists.txt || die + + if use python; then + local abi + for abi in ${PYTHON_ABIS}; do + mkdir "${S}"-${abi} + done + fi +} + +src_configure() { + # MPI is still very buggy + # x11=off does not compile + mycmakeargs+=( + -DMPICH=OFF + -DBUNDLED_ANTLR=OFF + -DX11=ON + $(cmake-utils_use fftw) + $(cmake-utils_use grib) + $(cmake-utils_use gshhs) + $(cmake-utils_use hdf) + $(cmake-utils_use hdf5) + $(cmake-utils_use imagemagick MAGICK) + $(cmake-utils_use netcdf) + $(cmake-utils_use openmp) + $(cmake-utils_use proj LIBPROJ4) + $(cmake-utils_use ps PSLIB) + $(cmake-utils_use udunits) + $(cmake-utils_use wxwidgets) + ) + configuration() { + mycmakeargs+=( $@ ) + CMAKE_BUILD_DIR="${BUILDDIR:-${S}_build}" cmake-utils_src_configure + } + configuration -DPYTHON_MODULE=OFF -DPYTHON=OFF + use python && python_execute_function -s \ + configuration -DPYTHON_MODULE=ON -DPYTHON=ON +} + +src_compile() { + cmake-utils_src_compile + use python && python_src_compile +} + +src_test() { + # defines a check target instead of the ctest to define some LDPATH + if use X; then + Xemake -j1 -C ${CMAKE_BUILD_DIR} check + else + emake -j1 -C ${CMAKE_BUILD_DIR} check + fi +} + +src_install() { + cmake-utils_src_install + if use python; then + installation() { + exeinto $(python_get_sitedir) + newexe "${S}"-${PYTHON_ABI}/src/libgdl.so GDL.so + } + python_execute_function -s installation + dodoc PYTHON.txt + fi + echo "GDL_PATH=\"+${EPREFIX}/usr/share/gnudatalanguage\"" > 50gdl + doenvd 50gdl +} |