summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sci-chemistry/ambertools/ambertools-1.5-r1.ebuild
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sci-chemistry/ambertools/ambertools-1.5-r1.ebuild')
-rw-r--r--sci-chemistry/ambertools/ambertools-1.5-r1.ebuild144
1 files changed, 144 insertions, 0 deletions
diff --git a/sci-chemistry/ambertools/ambertools-1.5-r1.ebuild b/sci-chemistry/ambertools/ambertools-1.5-r1.ebuild
new file mode 100644
index 000000000000..47adf6201db7
--- /dev/null
+++ b/sci-chemistry/ambertools/ambertools-1.5-r1.ebuild
@@ -0,0 +1,144 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=4
+
+inherit eutils fortran-2 multilib toolchain-funcs
+
+DESCRIPTION="A suite for carrying out complete molecular mechanics investigations"
+HOMEPAGE="http://ambermd.org/#AmberTools"
+SRC_URI="
+ AmberTools-${PV}.tar.bz2
+ mirror://gentoo/${P}-bugfix_1-10.patch.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux"
+IUSE="mpi openmp static-libs X"
+
+RESTRICT="fetch"
+
+RDEPEND="
+ virtual/cblas
+ virtual/lapack
+ sci-libs/clapack
+ sci-libs/arpack
+ sci-libs/cifparse-obj
+ sci-chemistry/mopac7
+ sci-libs/netcdf
+ sci-libs/fftw:2.1
+ sci-chemistry/reduce"
+DEPEND="${RDEPEND}
+ dev-util/byacc
+ dev-libs/libf2c
+ sys-devel/ucpp
+ virtual/pkgconfig"
+S="${WORKDIR}/amber11"
+
+pkg_nofetch() {
+ einfo "Go to ${HOMEPAGE} and get ${A}"
+ einfo "Place it in ${DISTDIR}"
+}
+
+pkg_setup() {
+ fortran-2_pkg_setup
+ if use openmp; then
+ tc-has-openmp || \
+ die "Please select an openmp capable compiler like gcc[openmp]"
+ fi
+ AMBERHOME="${S}"
+}
+
+src_prepare() {
+ epatch \
+ "${WORKDIR}/${P}-bugfix_1-10.patch" \
+ "${FILESDIR}/${P}-gentoo.patch"
+ cd AmberTools/src
+ rm -r arpack blas lapack fftw-2.1.5 c9x-complex cifparse netcdf pnetcdf reduce ucpp-1.3 || die
+}
+
+src_configure() {
+ cd AmberTools/src
+ sed \
+ -e "s:\\\\\$(LIBDIR)/arpack.a:-larpack:g" \
+ -e "s:\\\\\$(LIBDIR)/lapack.a:$($(tc-getPKG_CONFIG) --libs lapack) -lclapack:g" \
+ -e "s:\\\\\$(LIBDIR)/blas.a:$($(tc-getPKG_CONFIG) --libs blas cblas):g" \
+ -e "s:\\\\\$(LIBDIR)/libdrfftw.a:${EPREFIX}/usr/$(get_libdir)/libdrfftw.a:g" \
+ -e "s:\\\\\$(LIBDIR)/libdfftw.a:${EPREFIX}/usr/$(get_libdir)/libdrfftw.a:g" \
+ -e "s:CFLAGS=:CFLAGS=${CFLAGS} -DBINTRAJ :g" \
+ -e "s:FFLAGS=:FFLAGS=${FFLAGS} :g" \
+ -e "s:LDFLAGS=$ldflags:LDFLAGS=${LDFLAGS}:g" \
+ -e "s:fc=g77:fc=$(tc-getFC):g" \
+ -e "s:\$netcdflib:$($(tc-getPKG_CONFIG) --libs netcdf):g" \
+ -e "s:NETCDF=\$netcdf:NETCDF=netcdf.mod:g" \
+ -e "s:-O3::g" \
+ -i configure || die
+ sed -e "s:arsecond_:arscnd_:g" \
+ -i sff/time.c \
+ -i sff/sff.h \
+ -i sff/sff.c || die
+ sed -e "s:\$(NAB):\$(NAB) -lrfftw:g" \
+ -i nss/Makefile || die
+
+ local myconf
+
+ use X || myconf="${myconf} -noX11"
+
+ for x in mpi openmp; do
+ use ${x} && myconf="${myconf} -${x}"
+ done
+
+ ./configure \
+ ${myconf} \
+ -nobintraj \
+ -nomdgx \
+ -nopython \
+ -nomtkpp \
+ gnu
+# $(expr match "$(tc-getCC)" '.*\([a-z]cc\)')
+}
+
+src_compile() {
+ cd AmberTools/src
+ emake
+}
+
+src_install() {
+ rm -r bin/chemistry bin/MMPBSA_mods
+ rm bin/ante-MMPBSA.py bin/extractFrcmod.py
+ for x in bin/*
+ do dobin ${x} || die
+ done
+ rm "${ED}/usr/bin/yacc"
+ dobin AmberTools/src/antechamber/mopac.sh
+ sed -e "s:\$AMBERHOME/bin/mopac:mopac7:g" \
+ -i "${ED}/usr/bin/mopac.sh" || die
+ # Make symlinks untill binpath for amber will be fixed
+ dodir /usr/share/${PN}/bin
+ cd "${ED}/usr/bin"
+ for x in *; do
+ dosym /usr/bin/${x} /usr/share/${PN}/bin/${x}
+ done
+ cd "${S}"
+# sed -e "s:\$AMBERHOME/dat:\$AMBERHOME/share/ambertools/dat:g" \
+# -i "${ED}/usr/bin/xleap" \
+# -i "${ED}/usr/bin/tleap" || die
+ dodoc doc/AmberTools.pdf doc/leap_pg.pdf
+
+ use static-libs && dolib.a lib/*
+
+ insinto /usr/include/${PN}
+ doins include/*
+
+ insinto /usr/share/${PN}
+ doins -r dat
+
+ cd AmberTools
+ doins -r benchmarks examples test
+
+ cat >> "${T}"/99ambertools <<- EOF
+ AMBERHOME="${EPREFIX}/usr/share/ambertools"
+ EOF
+ doenvd "${T}"/99ambertools
+}