summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenda XU <heroxbd@gentoo.org>2012-05-20 16:48:17 +0000
committerBenda XU <heroxbd@gentoo.org>2012-05-20 16:48:17 +0000
commit664a341644386487dd62d7b38f868cdd2559b06e (patch)
tree4c630423a53a414bc667657172dcc085e221674d /sci-physics
parentI have massed up the keywords and Changelog with blind rsync with my overlay.... (diff)
downloadhistorical-664a341644386487dd62d7b38f868cdd2559b06e.tar.gz
historical-664a341644386487dd62d7b38f868cdd2559b06e.tar.bz2
historical-664a341644386487dd62d7b38f868cdd2559b06e.zip
add version 4.9.5 for 4.9.5_p01 cannot function correctly, upstream bug http://bugzilla-geant4.kek.jp/show_bug.cgi?id=1317; add example USE flag.
Package-Manager: portage-2.1.10.57/cvs/Linux x86_64
Diffstat (limited to 'sci-physics')
-rw-r--r--sci-physics/geant-python/geant-python-4.9.5.ebuild83
-rw-r--r--sci-physics/geant-python/geant-python-4.9.5_p01.ebuild9
2 files changed, 89 insertions, 3 deletions
diff --git a/sci-physics/geant-python/geant-python-4.9.5.ebuild b/sci-physics/geant-python/geant-python-4.9.5.ebuild
new file mode 100644
index 000000000000..0bb456c0ae8a
--- /dev/null
+++ b/sci-physics/geant-python/geant-python-4.9.5.ebuild
@@ -0,0 +1,83 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-physics/geant-python/geant-python-4.9.5.ebuild,v 1.1 2012/05/20 16:48:17 heroxbd Exp $
+
+EAPI=4
+
+inherit python versionator
+
+MYP="geant$(replace_version_separator 3 .)"
+
+DESCRIPTION="Python binding for geant"
+HOMEPAGE="http://geant4.cern.ch/"
+SRC_URI="http://geant4.cern.ch/support/source/${MYP}.tar.gz"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+
+LICENSE="geant4"
+SLOT="0"
+IUSE="examples"
+
+RDEPEND="=sci-physics/geant-${PV}* \
+ dev-libs/boost[python]"
+DEPEND="${RDEPEND}"
+
+S="${WORKDIR}/${MYP}/environments/g4py"
+
+src_prepare() {
+ # DISTDIR and python path patch
+ epatch "${FILESDIR}"/${PN}-4.9.5-build.patch
+
+ # set to the highest verbose for visManager
+ epatch "${FILESDIR}"/${PN}-4.9.5-visverbose.patch
+
+ # let Geant4 module installed into python sitedir instead of default
+ sed -i "/G4PY_LIBDIR :=/cG4PY_LIBDIR := $\(DESTDIR\)$(python_get_sitedir)/Geant4" \
+ config/install.gmk || die "sed failed on config/install.gmk"
+ for mfile in source/python{3,}/GNUmakefile
+ do
+ sed -i "/install_dir :=/cinstall_dir := $\(DESTDIR\)$(python_get_sitedir)/Geant4" \
+ "${mfile}" || die "sed failed on ${mfile}"
+ done
+
+ # let g4py module installed into python sitedir instead of default
+ sed -i "/install_dir :=/cinstall_dir := $\(DESTDIR\)$(python_get_sitedir)/g4py" \
+ config/site-install.gmk || die "sed failed on config/site-install.gmk"
+ for mfile in {processes/emcalculator,utils/MCScore}/{python3/,}GNUmakefile python/GNUmakefile
+ do
+ sed -i "/install_dir :=/cinstall_dir := $\(DESTDIR\)$(python_get_sitedir)/g4py" \
+ "site-modules/${mfile}" || die "sed failed on site-modules/${mfile}"
+ done
+}
+
+src_configure() {
+ case ${CHOST} in
+ x86_64-pc-linux-gnu)
+ ARG=linux64
+ ;;
+ i?86-pc-linux-gnu)
+ ARG=linux
+ ;;
+ *)
+ die "platform unknown"
+ ;;
+ esac
+
+ ./configure ${ARG} \
+ --prefix="${EPREFIX}/usr" \
+ --with-g4-incdir="${EPREFIX}/usr/include/Geant4" \
+ --with-g4-libdir="${EPREFIX}/usr/lib" \
+ --with-clhep-incdir="${EPREFIX}/usr/include" \
+ --with-clhep-libdir="${EPREFIX}/usr/lib" \
+ --with-python-incdir="${EPREFIX}$(python_get_includedir)" \
+ --with-python-libdir="${EPREFIX}$(python_get_libdir)" \
+ --with-boost-incdir="${EPREFIX}/usr/include" \
+ --with-boost-libdir="${EPREFIX}/usr/lib" \
+ || die "configure failed"
+}
+
+src_install() {
+ emake DESTDIR="${ED}" install
+ insinto /usr/share/doc/${PF}
+ dodoc 00README History AUTHORS
+ use examples && doins -r examples
+}
diff --git a/sci-physics/geant-python/geant-python-4.9.5_p01.ebuild b/sci-physics/geant-python/geant-python-4.9.5_p01.ebuild
index f8be72385d24..61b8f1cf05f3 100644
--- a/sci-physics/geant-python/geant-python-4.9.5_p01.ebuild
+++ b/sci-physics/geant-python/geant-python-4.9.5_p01.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sci-physics/geant-python/geant-python-4.9.5_p01.ebuild,v 1.1 2012/05/20 03:11:24 heroxbd Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-physics/geant-python/geant-python-4.9.5_p01.ebuild,v 1.2 2012/05/20 16:48:17 heroxbd Exp $
EAPI=4
@@ -15,9 +15,9 @@ KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
LICENSE="geant4"
SLOT="0"
-IUSE=""
+IUSE="examples"
-RDEPEND="sci-physics/geant:4 \
+RDEPEND="=sci-physics/geant-${PV}* \
dev-libs/boost[python]"
DEPEND="${RDEPEND}"
@@ -77,4 +77,7 @@ src_configure() {
src_install() {
emake DESTDIR="${ED}" install
+ insinto /usr/share/doc/${PF}
+ dodoc 00README History AUTHORS
+ use examples && doins -r examples
}