summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonnie Berkholz <dberkholz@gentoo.org>2007-06-22 07:01:13 +0000
committerDonnie Berkholz <dberkholz@gentoo.org>2007-06-22 07:01:13 +0000
commite0b5d9be3df36d84f22f06382bab715154fdaa11 (patch)
treed33d71e996fdefaaa6467058682210d549858656 /sci-chemistry/cns
parentVersion bump (diff)
downloadgentoo-2-e0b5d9be3df36d84f22f06382bab715154fdaa11.tar.gz
gentoo-2-e0b5d9be3df36d84f22f06382bab715154fdaa11.tar.bz2
gentoo-2-e0b5d9be3df36d84f22f06382bab715154fdaa11.zip
(#162740) Bump.
(Portage version: 2.1.2.7)
Diffstat (limited to 'sci-chemistry/cns')
-rw-r--r--sci-chemistry/cns/ChangeLog8
-rw-r--r--sci-chemistry/cns/cns-1.1.ebuild8
-rw-r--r--sci-chemistry/cns/cns-1.2.ebuild125
-rw-r--r--sci-chemistry/cns/files/digest-cns-1.23
4 files changed, 140 insertions, 4 deletions
diff --git a/sci-chemistry/cns/ChangeLog b/sci-chemistry/cns/ChangeLog
index 25833d4ce123..0b23d6eeccf2 100644
--- a/sci-chemistry/cns/ChangeLog
+++ b/sci-chemistry/cns/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sci-chemistry/cns
# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/cns/ChangeLog,v 1.6 2007/03/15 17:08:43 kugelfang Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/cns/ChangeLog,v 1.7 2007/06/22 07:01:13 dberkholz Exp $
+
+*cns-1.2 (22 Jun 2007)
+
+ 22 Jun 2007; Donnie Berkholz <dberkholz@gentoo.org>; cns-1.1.ebuild,
+ +cns-1.2.ebuild:
+ (#162740) Bump.
15 Mar 2007; Danny van Dyk <kugelfang@gentoo.org> cns-1.1.ebuild:
QA: Removed illegal use of ${ROOT}. Bug #168043
diff --git a/sci-chemistry/cns/cns-1.1.ebuild b/sci-chemistry/cns/cns-1.1.ebuild
index e772a65dc1cc..29ae2413ac5d 100644
--- a/sci-chemistry/cns/cns-1.1.ebuild
+++ b/sci-chemistry/cns/cns-1.1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/cns/cns-1.1.ebuild,v 1.3 2007/03/15 17:08:43 kugelfang Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/cns/cns-1.1.ebuild,v 1.4 2007/06/22 07:01:13 dberkholz Exp $
inherit eutils fortran toolchain-funcs
@@ -17,8 +17,7 @@ LICENSE="cns"
SLOT="0"
KEYWORDS="ppc x86"
IUSE="test"
-RDEPEND="|| ( app-shells/tcsh app-shells/csh )
- !app-text/dos2unix"
+RDEPEND="|| ( app-shells/tcsh app-shells/csh )"
DEPEND="${RDEPEND}"
S="${WORKDIR}/${MY_P}"
@@ -117,6 +116,9 @@ src_install() {
-A iq,cgi,csh,cv,def,fm,gif,hkl,inp,jpeg,lib,link,list,mask,mtf,param,pdb,pdf,pl,ps,sc,sca,sdb,seq,tbl,top \
-f all_cns_info_template,omac,def \
-r doc/html/*
+
+ # Conflits with app-text/dos2unix
+ rm -f "${D}"/usr/bin/dos2unix
}
pkg_postinst() {
diff --git a/sci-chemistry/cns/cns-1.2.ebuild b/sci-chemistry/cns/cns-1.2.ebuild
new file mode 100644
index 000000000000..46ab988a4828
--- /dev/null
+++ b/sci-chemistry/cns/cns-1.2.ebuild
@@ -0,0 +1,125 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/cns/cns-1.2.ebuild,v 1.1 2007/06/22 07:01:13 dberkholz Exp $
+
+inherit eutils fortran toolchain-funcs
+
+MY_PN="${PN}_solve"
+MY_P="${MY_PN}_${PV}"
+
+DESCRIPTION="Crystallography and NMR System"
+HOMEPAGE="http://cns.csb.yale.edu/"
+SRC_URI="${MY_P}_all.tar.gz"
+RESTRICT="fetch"
+LICENSE="cns"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+RDEPEND="|| ( app-shells/tcsh app-shells/csh )
+ !app-text/dos2unix"
+DEPEND="${RDEPEND}"
+S="${WORKDIR}/${MY_P}"
+
+FORTRAN="g77 gfortran"
+
+pkg_nofetch() {
+ einfo "Fill out the form at http://cns.csb.yale.edu/cns_request/"
+ einfo "and place these files:"
+ einfo "${A}"
+ einfo "in ${DISTDIR}."
+}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ # The length of time must be at least 10, not 9
+ # http://gcc.gnu.org/ml/fortran/2006-02/msg00198.html
+ epatch "${FILESDIR}"/1.1-time-length-10.patch
+
+ # Set up location for the build directory
+ # Uses obsolete `sort` syntax, so we set _POSIX2_VERSION
+ sed -i \
+ -e "s:_CNSsolve_location_:${S}:g" \
+ -e "17 s:\(.*\):\1\nsetenv _POSIX2_VERSION 199209:g" \
+ "${S}"/cns_solve_env
+}
+
+src_compile() {
+ local GLOBALS
+ if [[ ${FORTRANC} = g77 ]]; then
+ GLOBALS="-fno-globals"
+ fi
+
+ # make install really means build, since it's expected to be used in-place
+ emake \
+ CC="$(tc-getCC)" \
+ F77="${FORTRANC}" \
+ LD="${FORTRANC}" \
+ CCFLAGS="${CFLAGS} -DCNS_ARCH_TYPE_\$(CNS_ARCH_TYPE) \$(EXT_CCFLAGS)" \
+ F77OPT="${FFLAGS:- -O2} \$(CNS_MALIGN_I86)" \
+ F77STD="${GLOBALS}" \
+ LDFLAGS="${LDFLAGS}" \
+ g77install \
+ || die "emake failed"
+}
+
+src_test() {
+ # We need to force on g77 manually, because we can't get aliases working
+ # when we source in a -c
+ einfo "Running tests ..."
+ csh -c \
+ "setenv CNS_G77; source cns_solve_env; make run_tests" \
+ || die "tests failed"
+ einfo "Displaying test results ..."
+ cat "${S}"/*_g77/test/*.diff-test
+}
+
+src_install() {
+ # Install to locations resembling FHS
+ sed -i \
+ -e "s:${S}:usr:g" \
+ -e "s:^\(setenv CNS_SOLVE.*\):\1\nsetenv CNS_ROOT usr:g" \
+ -e "s:^\(setenv CNS_SOLVE.*\):\1\nsetenv CNS_DATA \$CNS_ROOT/share/data:g" \
+ -e "s:^\(setenv CNS_SOLVE.*\):\1\nsetenv CNS_DOC \$CNS_ROOT/share/doc/${PF}:g" \
+ -e "s:CNS_MODULE \$CNS_SOLVE/modules:CNS_MODULE \$CNS_DATA/modules:g" \
+ -e "s:\$CNS_LIB:\$CNS_DATA:g" \
+ -e "s:CNS_HELPLIB \$CNS_SOLVE/helplib:CNS_HELPLIB \$CNS_DATA/helplib:g" \
+ -e "s:\$CNS_SOLVE/bin/cns_info:\$CNS_DATA/bin/cns_info:g" \
+ "${S}"/cns_solve_env
+
+ # Get rid of setup stuff we don't need in the installed script
+ sed -i \
+ -e "83,$ d" \
+ -e "37,46 d" \
+ "${S}"/cns_solve_env
+
+ newbin "${S}"/*_g77/bin/cns_solve* cns_solve \
+ || die "install cns_solve failed"
+
+ # Can be run by either cns_solve or cns
+ dosym cns_solve /usr/bin/cns
+
+ # Don't want to install this
+ rm -f "${S}"/*_g77/utils/Makefile
+
+ dobin "${S}"/*_g77/utils/* || die "install utils failed"
+
+ dobin "${S}"/bin/cns_{edit,header,transfer,web} || die "install bin failed"
+
+ insinto /usr/share/cns
+ doins -r "${S}"/libraries "${S}"/modules "${S}"/helplib
+ doins "${S}"/bin/cns_info
+ doins "${S}"/cns_solve_env
+
+ dohtml \
+ -A iq,cgi,csh,cv,def,fm,gif,hkl,inp,jpeg,lib,link,list,mask,mtf,param,pdb,pdf,pl,ps,sc,sca,sdb,seq,tbl,top \
+ -f all_cns_info_template,omac,def \
+ -r doc/html/*
+}
+
+pkg_postinst() {
+ ewarn "You must source ${ROOT}usr/share/cns/cns_solve_env"
+ ewarn "before running CNS. It's a C-shell script,"
+ ewarn "so you also must be using csh or tcsh."
+}
diff --git a/sci-chemistry/cns/files/digest-cns-1.2 b/sci-chemistry/cns/files/digest-cns-1.2
new file mode 100644
index 000000000000..1b3fb7cb9da1
--- /dev/null
+++ b/sci-chemistry/cns/files/digest-cns-1.2
@@ -0,0 +1,3 @@
+MD5 66b54d9f9e780beee850e4dd07d7031a cns_solve_1.2_all.tar.gz 30456531
+RMD160 45cff57b3f026d730032cfc1c9476880f7cc81ab cns_solve_1.2_all.tar.gz 30456531
+SHA256 230847d8e00def4b55dda8c50d9148bca11a88ed6bc575e735041c91f8fff064 cns_solve_1.2_all.tar.gz 30456531