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/phaser
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/phaser')
-rw-r--r--sci-chemistry/phaser/Manifest1
-rw-r--r--sci-chemistry/phaser/files/phaser-2.1.4-chmod.patch13
-rw-r--r--sci-chemistry/phaser/metadata.xml9
-rw-r--r--sci-chemistry/phaser/phaser-2.1.4.ebuild115
4 files changed, 138 insertions, 0 deletions
diff --git a/sci-chemistry/phaser/Manifest b/sci-chemistry/phaser/Manifest
new file mode 100644
index 000000000000..33872db5dc96
--- /dev/null
+++ b/sci-chemistry/phaser/Manifest
@@ -0,0 +1 @@
+DIST ccp4-6.1.13-phaser-cctbx-src.tar.gz 22021353 SHA256 e6c4365cb34da5ce2dd5f1e74b8927258064016194446163418c8a3139a4b804
diff --git a/sci-chemistry/phaser/files/phaser-2.1.4-chmod.patch b/sci-chemistry/phaser/files/phaser-2.1.4-chmod.patch
new file mode 100644
index 000000000000..5311cb332785
--- /dev/null
+++ b/sci-chemistry/phaser/files/phaser-2.1.4-chmod.patch
@@ -0,0 +1,13 @@
+diff --git a/lib/cctbx/cctbx_sources/libtbx/libtbx/config.py b/lib/cctbx/cctbx_sources/libtbx/libtbx/config.py
+index 3b1bd3a..8939a74 100755
+--- a/lib/cctbx/cctbx_sources/libtbx/libtbx/config.py
++++ b/lib/cctbx/cctbx_sources/libtbx/libtbx/config.py
+@@ -802,8 +802,6 @@ class environment:
+ else:
+ action = self.write_bin_sh_dispatcher
+ ext = ""
+- try: os.chmod(source_file, 0755)
+- except OSError: pass
+ target_file_ext = target_file + ext
+ remove_or_rename(target_file_ext)
+ try: action(source_file, target_file_ext)
diff --git a/sci-chemistry/phaser/metadata.xml b/sci-chemistry/phaser/metadata.xml
new file mode 100644
index 000000000000..6b4826474daa
--- /dev/null
+++ b/sci-chemistry/phaser/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>sci-chemistry</herd>
+ <maintainer>
+ <email>jlec@gentoo.org</email>
+ <description>ccp4 maintainer</description>
+ </maintainer>
+</pkgmetadata>
diff --git a/sci-chemistry/phaser/phaser-2.1.4.ebuild b/sci-chemistry/phaser/phaser-2.1.4.ebuild
new file mode 100644
index 000000000000..86fa57f52603
--- /dev/null
+++ b/sci-chemistry/phaser/phaser-2.1.4.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+PYTHON_COMPAT=( python2_7 )
+
+inherit eutils flag-o-matic python-single-r1 toolchain-funcs
+
+CCP4VER="6.1.13"
+
+DESCRIPTION="A program for phasing macromolecular crystal structures"
+HOMEPAGE="http://www-structmed.cimr.cam.ac.uk/phaser"
+SRC_URI="ftp://ftp.ccp4.ac.uk/ccp4/${CCP4VER}/ccp4-${CCP4VER}-${PN}-cctbx-src.tar.gz"
+
+LICENSE="|| ( phaser phaser-com ccp4 )"
+SLOT="0"
+#KEYWORDS="~amd64 ~x86"
+KEYWORDS=""
+IUSE="openmp"
+
+RDEPEND=""
+DEPEND="${RDEPEND}
+ app-shells/tcsh"
+
+S="${WORKDIR}"/ccp4-${CCP4VER}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/phaser-2.1.4-chmod.patch \
+ "${FILESDIR}"/phaser-2.1.4-ldflags.patch
+
+ use openmp && append-flags -fopenmp
+
+ for i in ${CXXFLAGS}; do
+ OPTS="${OPTS} \"${i}\","
+ done
+
+ OPTS=${OPTS%,}
+
+ sed -i \
+ -e "s:opts = \[.*\]$:opts = \[${OPTS}\]:g" \
+ "${S}"/lib/cctbx/cctbx_sources/libtbx/SConscript || die
+
+ for i in ${LDFLAGS}; do
+ OPTSLD="${OPTSLD} \"${i}\","
+ done
+
+ sed -i \
+ -e "s:env_etc.shlinkflags .* \"-shared\":env_etc.shlinkflags = \[ ${OPTSLD} \"-shared\"\]:g" \
+ -e "s:\[\"-static:\[${OPTSLD} \"-static:g" \
+ "${S}"/lib/cctbx/cctbx_sources/libtbx/SConscript || die
+
+}
+
+src_configure() {
+ local compiler
+ local mtype
+ local mversion
+ local nproc
+
+ # Valid compilers are win32_cl, sunos_CC, unix_gcc, unix_ecc,
+ # unix_icc, unix_icpc, tru64_cxx, hp_ux11_aCC, irix_CC,
+ # darwin_c++, darwin_gcc. The build systems seems to prepend
+ # unix_ all by itself. Can this be derived from $(tc-getCC)?
+ compiler=$(expr match "$(tc-getCC)" '.*\([a-z]cc\)')
+
+ # Breaks cross compilation.
+ mtype=$(src/${PN}/bin/machine_type)
+ mversion=$(src/${PN}/bin/machine_version)
+
+ einfo "Creating build directory"
+ mkdir build
+ cd build
+ ln -sf "${S}/lib/cctbx/cctbx_sources/scons" scons
+ ln -sf "${S}/lib/cctbx/cctbx_sources/libtbx" libtbx
+
+ einfo "Configuring phaser components"
+ $(PYTHON) "libtbx/configure.py" \
+ --build=release \
+ --compiler=${compiler} \
+ --repository="${S}"/src/${PN}/source \
+ --repository="${S}"/lib/cctbx/cctbx_sources \
+ --static_libraries \
+ ccp4io="${S}" \
+ mmtbx \
+ phaser || die "configure.py failed"
+}
+
+src_compile() {
+ nproc=`echo "-j1 ${MAKEOPTS}" \
+ | sed -e "s/.*\(-j\s*\|--jobs=\)\([0-9]\+\).*/\2/"`
+
+ cd build
+ einfo "Setting up build environment"
+ source setpaths.sh
+
+ einfo "Compiling phaser components"
+ libtbx.scons -j ${nproc} || die "libtbx.scons failed"
+}
+
+src_install() {
+ dobin build/exe/phaser || die
+
+ cat >> "${T}"/53${PN} <<- EOF
+ PHASER="${EPREFIX}/usr/bin"
+ PHASER_ENVIRONMENT="1"
+ PHASER_MTYPE="${mtype}"
+ PHASER_MVERSION="${mversion}"
+ PHASER_VERSION="${PV}"
+ EOF
+
+ doenvd "${T}"/53${PN} || die
+}