* [gentoo-commits] proj/sci:master commit in: sci-chemistry/specView/files/, sci-chemistry/specView/
@ 2012-09-21 8:13 Justin Lecher
0 siblings, 0 replies; only message in thread
From: Justin Lecher @ 2012-09-21 8:13 UTC (permalink / raw
To: gentoo-commits
commit: 18afebc92ac7adc947f3afd81a52864d33ef7396
Author: Justin Lecher <jlec <AT> gentoo <DOT> org>
AuthorDate: Fri Sep 21 07:56:21 2012 +0000
Commit: Justin Lecher <jlec <AT> gentoo <DOT> org>
CommitDate: Fri Sep 21 07:56:21 2012 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/sci.git;a=commit;h=18afebc9
sci-chemistry/specView: New addition
(Portage version: 2.2.0_alpha130/git/Linux x86_64, unsigned Manifest commit)
---
sci-chemistry/specView/ChangeLog | 10 +++
sci-chemistry/specView/files/specView | 9 +++
sci-chemistry/specView/metadata.xml | 5 ++
sci-chemistry/specView/specView-1.0.2.ebuild | 101 ++++++++++++++++++++++++++
4 files changed, 125 insertions(+), 0 deletions(-)
diff --git a/sci-chemistry/specView/ChangeLog b/sci-chemistry/specView/ChangeLog
new file mode 100644
index 0000000..a3d4b97
--- /dev/null
+++ b/sci-chemistry/specView/ChangeLog
@@ -0,0 +1,10 @@
+# ChangeLog for sci-chemistry/specView
+# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# $Header: $
+
+*specView-1.0.2 (21 Sep 2012)
+
+ 21 Sep 2012; Justin Lecher <jlec@gentoo.org> +specView-1.0.2.ebuild,
+ +files/specView, +metadata.xml:
+ New addition
+
diff --git a/sci-chemistry/specView/files/specView b/sci-chemistry/specView/files/specView
new file mode 100644
index 0000000..bca546c
--- /dev/null
+++ b/sci-chemistry/specView/files/specView
@@ -0,0 +1,9 @@
+#!/bin/bash
+
+export CCPNMR_TOP_DIR=gentoo_sitedir
+export PYTHONPATH=.:${CCPNMR_TOP_DIR}/specView/python
+export LD_LIBRARY_PATH=gentoolibdir
+export TCL_LIBRARY=gentootcl
+export TK_LIBRARY=gentootk
+export PSIPRED_DIR=gentoousr
+gentoopython -O ${CCPNMR_TOP_DIR}/specView/python/ccpnmr/specView/SpecView.py $@
diff --git a/sci-chemistry/specView/metadata.xml b/sci-chemistry/specView/metadata.xml
new file mode 100644
index 0000000..d369d06
--- /dev/null
+++ b/sci-chemistry/specView/metadata.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>sci</herd>
+</pkgmetadata>
diff --git a/sci-chemistry/specView/specView-1.0.2.ebuild b/sci-chemistry/specView/specView-1.0.2.ebuild
new file mode 100644
index 0000000..5debc8c
--- /dev/null
+++ b/sci-chemistry/specView/specView-1.0.2.ebuild
@@ -0,0 +1,101 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=4
+
+PYTHON_DEPEND="2"
+
+inherit python toolchain-funcs
+
+DESCRIPTION="Fast way to visualise NMR spectrum and peak data"
+HOMEPAGE="http://www.ccpn.ac.uk/software/specview"
+SRC_URI="http://www2.ccpn.ac.uk/download/ccpnmr/${PN}${PV}.tar.gz"
+
+SLOT="0"
+LICENSE="|| ( CCPN LGPL-2.1 )"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+IUSE=""
+
+RDEPEND="
+ dev-python/pyopengl
+ dev-python/pyside"
+DEPEND="${RDEPEND}"
+
+S="${WORKDIR}"/ccpnmr/ccpnmr3.0/
+
+#TODO:
+#install in sane place
+#unbundle data model
+#unbundle inchi
+#parallel build
+
+pkg_setup() {
+ python_set_active_version 2
+ python_pkg_setup
+}
+
+src_prepare() {
+ sed \
+ -e "s|/usr|${EPREFIX}/usr|g" \
+ -e "s|^\(CC =\).*|\1 $(tc-getCC)|g" \
+ -e '/^MALLOC_FLAG/s:^:#:g' \
+ -e "/^OPT_FLAG/s:=.*$:= ${CFLAGS}:g" \
+ -e "/^LINK_FLAGS/s:$: ${LDFLAGS}:g" \
+ -e "/^PYTHON_DIR/s:=.*:= ${EPREFIX}/usr:g" \
+ -e "/^PYTHON_LIB/s:=.*:= $(python_get_library -l):g" \
+ -e "/^PYTHON_INCLUDE_FLAGS/s:=.*:= -I$(python_get_includedir) -I$(python_get_sitedir)/numpy/core/include/numpy:g" \
+ -e "/^PYTHON_LIB_FLAGS/s:=.*:= -L${EPREFIX}/usr/$(get_libdir):g" \
+ -e "/^SHARED_FLAGS/s:=.*:= -shared:g" \
+ -e "/^GL_DIR/s:=.*:= ${EPREFIX}/usr/$(get_libdir):g" \
+ -e "/^GL_INCLUDE_FLAGS/s:=.*:= -I${EPREFIX}/usr/include:g" \
+ -e "/^GL_LIB_FLAGS/s:=.*:= -L${EPREFIX}/usr/$(get_libdir):g" \
+ cNg/environment_default.txt > cNg/environment.txt || die
+ echo "SHARED_LINK_PARM = ${LDFLAGS}" >> cNg/environment.txt || die
+
+ rm -rf license || die
+
+ sed \
+ -e 's:ln -s:cp -f:g' \
+ -i $(find python -name linkSharedObjs) || die
+}
+
+src_compile() {
+ emake -C cNg all
+ emake -j1 -C cNg links
+}
+
+src_install() {
+ local in_path=$(python_get_sitedir)/${PN}
+ local _file
+
+ find . -name "*.pyc" -type f -delete
+ dodir /usr/bin
+ sed \
+ -e "s|gentoo_sitedir|${EPREFIX}$(python_get_sitedir)|g" \
+ -e "s|gentoolibdir|${EPREFIX}/usr/${libdir}|g" \
+ -e "s|gentootk|${EPREFIX}/usr/${libdir}/tk${tkver}|g" \
+ -e "s|gentootcl|${EPREFIX}/usr/${libdir}/tclk${tkver}|g" \
+ -e "s|gentoopython|$(PYTHON -a)|g" \
+ -e "s|gentoousr|${EPREFIX}/usr|g" \
+ -e "s|//|/|g" \
+ "${FILESDIR}"/${PN} > "${ED}"/usr/bin/${PN} || die
+ fperms 755 /usr/bin/${PN}
+
+ insinto ${in_path}
+
+ dodir ${in_path}/cNg
+ rm -rf cNg || die
+
+ ebegin "Installing main files"
+ doins -r *
+ eend
+
+ ebegin "Adjusting permissions"
+
+ for _file in $(find "${ED}" -type f -name "*so"); do
+ chmod 755 ${_file}
+ done
+ eend
+
+}
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2012-09-21 8:14 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-21 8:13 [gentoo-commits] proj/sci:master commit in: sci-chemistry/specView/files/, sci-chemistry/specView/ Justin Lecher
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox