aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Fabbro <sfabbro@uvic.ca>2012-07-26 16:27:06 -0700
committerSebastien Fabbro <sfabbro@uvic.ca>2012-07-26 16:27:06 -0700
commit16a226ca027f86c043fc3871bf12736db89f7a68 (patch)
tree169ecb8a69199ee700eb62e03e18e5bb09ca8bcf /sci-astronomy/zpeg/zpeg-5.23.ebuild
parentdev-cpp/eigen: Version bump. Changed license to MPL-2 (diff)
downloadsci-16a226ca027f86c043fc3871bf12736db89f7a68.tar.gz
sci-16a226ca027f86c043fc3871bf12736db89f7a68.tar.bz2
sci-16a226ca027f86c043fc3871bf12736db89f7a68.zip
sci-astronomy/zpeg: Initial import
(Portage version: 2.2.01.20796-prefix/git/Linux x86_64, unsigned Manifest commit)
Diffstat (limited to 'sci-astronomy/zpeg/zpeg-5.23.ebuild')
-rw-r--r--sci-astronomy/zpeg/zpeg-5.23.ebuild63
1 files changed, 63 insertions, 0 deletions
diff --git a/sci-astronomy/zpeg/zpeg-5.23.ebuild b/sci-astronomy/zpeg/zpeg-5.23.ebuild
new file mode 100644
index 000000000..51792f95b
--- /dev/null
+++ b/sci-astronomy/zpeg/zpeg-5.23.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=4
+
+inherit fortran-2
+
+MYP=${PN}_${PV}
+
+DESCRIPTION="Galaxy photometric redshifts from evolutionary synthesis"
+HOMEPAGE="http://imacdlb.iap.fr:8080/cgi-bin/zpeg/zpeg.pl"
+SRC_URI="ftp://ftp.iap.fr/pub/from_users/leborgne/${PN}/${MYP}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="gdl"
+
+RDEPEND="gdl? ( dev-lang/gdl )"
+DEPEND="virtual/fortran"
+
+S="${WORKDIR}/${MYP}"
+
+FORTRAN_STANDARD="90"
+
+src_prepare() {
+ # save configure for tests
+ cp configure{,.orig}
+ # install data in FHS
+ sed -i \
+ -e "s:ZPEG_ROOT=.*:ZPEG_ROOT=${EPREFIX}/usr/share/${PN}:" \
+ configure || die
+}
+
+src_compile() {
+ # not worth debugging parallell build failures which is due to
+ # fortran modules missing dependencies)
+ emake -j1 -C src
+}
+
+src_test() {
+ # test only works with hardcoded path, so reconfigure and recompile
+ mv bin/zpeg{,.orig}
+ mv configure{.orig,}
+ emake -C src clean && econf && emake -j1 -C src
+ cd test
+ ../bin/zpeg -V ZPEG1_cata.cat -o hdf.zpeg -p hdf.par -t hdf.par.tmp || die
+ mv bin/zpeg{.orig,}
+}
+
+src_install() {
+ dobin bin/zpeg
+ insinto /usr/share/${PN}
+ doins -r data VERSION
+ dodoc HISTORY
+ echo > 99zpeg "ZPEG_ROOT=${EROOT}/usr/share/${PN}"
+ doenvd 99zpeg
+ if use gdl; then
+ insinto /usr/share/gnudatalanguage/${PN}
+ doins idl/*.pro
+ fi
+}