aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sci-physics/thepeg')
-rw-r--r--sci-physics/thepeg/ChangeLog10
-rw-r--r--sci-physics/thepeg/Manifest5
-rw-r--r--sci-physics/thepeg/files/thepeg-1.8.0-java.patch37
-rw-r--r--sci-physics/thepeg/metadata.xml20
-rw-r--r--sci-physics/thepeg/thepeg-1.8.0.ebuild93
5 files changed, 165 insertions, 0 deletions
diff --git a/sci-physics/thepeg/ChangeLog b/sci-physics/thepeg/ChangeLog
new file mode 100644
index 000000000..35a5eb321
--- /dev/null
+++ b/sci-physics/thepeg/ChangeLog
@@ -0,0 +1,10 @@
+# ChangeLog for sci-physics/thepeg
+# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# $Header: $
+
+*thepeg-1.8.0 (07 Sep 2012)
+
+ 07 Sep 2012; Jauhien Piatlicki (jauhien) <piatlicki@gmail.com>
+ +thepeg-1.8.0.ebuild, +files/thepeg-1.8.0-java.patch, +metadata.xml:
+ New Ebuild for bug #424003 thanks to hasufell, mgorny and xarthisius.
+
diff --git a/sci-physics/thepeg/Manifest b/sci-physics/thepeg/Manifest
new file mode 100644
index 000000000..5f93a1391
--- /dev/null
+++ b/sci-physics/thepeg/Manifest
@@ -0,0 +1,5 @@
+DIST GRV98nlo.LHgrid 221906 SHA256 dca2cd4f13c6e9750da3cb1a1260c1db2e6b9ede9988f92f85e20524df0fe1d0 SHA512 ff615ab723d1f5ed8bd0187031fae441d41d6152938fd7d72d11fcfa7ffbee40704d2341e6d922432ae1f9fb5563210a9010d9466dda5c4f80c301bc4b563cd1 WHIRLPOOL be92c2c0fe0152dfff6c7aea9a937af42b553bde5fbe387774520805a0fa8601698e4545cb8dea70f7ccfb96306f8086545bca600f9bf02417dcf17518b5451a
+DIST MRST2001nlo.LHgrid 719690 SHA256 2f925ac31f458b81cfeb2291961ec5ef8dba30f543b0e758c1fb2bd41bde6139 SHA512 d477bcc678a17ed6ba8e13c5b9b009c2f1c7632793ca69320cf6e132ecac315521b9cdc2da9bd7cadc94f4e6218d2d41f9ae2e77c1c9a3a5d13770ef9fe7124d WHIRLPOOL 711f0e353d2b68e5c6ed4a42756b17b63289b5b9890cd3b07fa9766748556e8bd2aedbd33b59840347e351176f098bd710d590849e76b237709655bb6bf8d370
+DIST ThePEG-1.8.0.tar.bz2 1085822 SHA256 4b22fda1078f410b999a23a17f611c9ae3a7f0f4cee4e83dc82c9336b7adf037 SHA512 34a0aae5450b8d8668fbcd786ddb3add63f827d075206abab876db2f3a4a22e0c8cb7bbe3a826180bab2f36db2ffec54e8dafdefe41bcb47d4b16b1f4f8c298a WHIRLPOOL 907c93f157759988ea30c23554505b98a0891c246e62a227dfb23eca2d5e16fa3e83dbc0486ca634d35eba9a48e5a500a6ca78df69a6120d7ce860ba9bc01cb2
+DIST cteq5l.LHgrid 134797 SHA256 83c92bc90fd6e12be9cd76bc032eca26dcedbe90f0c11aef843bbf54734d5bba SHA512 1ba41fd773104a933af6f37745dcb6f8422e1aece74ba2b1e15a5fb69fdaf694336c0ec1dc6fbc964d2cf3fe363d17ca0c01a6c2ba6def0afa4389cb4083f34b WHIRLPOOL 8a86877fcbae2b45576e3fae08dfd4771c668257893ba2f813c578641dce9800f42bfd57d0d8ac2abc6bf7cd40921020478f1912014a36cfb722ed408ca1430f
+DIST cteq6ll.LHpdf 1461 SHA256 a3c6bd1ebea30f75fa23fa94922ba281872a66e59465b61f73a0f3629c2b5c03 SHA512 b89a87d1c1c7cc910aa4af53abc3cc6550670a5a6332989232d33c7da1ba01ce49bbbf9f3bb454e673312fb5bc1679f86eea18f95a1443d1c80d3a622e2b8728 WHIRLPOOL 3eeba4277668b92bfa0de3d0fb27d0d9b940904061b6aa212936e4a9b86f9955188b81d9572672f64155abc7f2c6184fc90f8f81dd7eabbe1b015b749a5af304
diff --git a/sci-physics/thepeg/files/thepeg-1.8.0-java.patch b/sci-physics/thepeg/files/thepeg-1.8.0-java.patch
new file mode 100644
index 000000000..45b0e9559
--- /dev/null
+++ b/sci-physics/thepeg/files/thepeg-1.8.0-java.patch
@@ -0,0 +1,37 @@
+--- java/Makefile.am
++++ java/Makefile.am
+@@ -11,8 +12,7 @@
+
+ CLEANFILES = ThePEG.jar thepeg.sh
+
+-jardir = $(pkglibdir)
+-nodist_jar_DATA = ThePEG.jar
++noinst_DATA = ThePEG.jar
+
+ dist_noinst_DATA = $(JAVASOURCES) jar-manifest
+
+@@ -34,7 +34,7 @@
+ $(JAR) cmf ThePEG/jar-manifest ThePEG.jar ThePEG/*.class
+
+ thepeg.sh: thepeg.install Makefile
+- sed -e s:@pkglibdir[@]:$(pkglibdir):g \
++ sed -e s:@datadir[@]:$(datadir):g \
+ -e s:@bindir[@]:$(bindir):g \
+ -e s:@java[@]:$(JAVA):g $(srcdir)/thepeg.install > thepeg.sh
+ chmod +x thepeg.sh
+--- java/thepeg.install
++++ java/thepeg.install
+@@ -1,6 +1,6 @@
+ #!/bin/sh
+
+-pkglibdir=@pkglibdir@
++source @datadir@/thepeg/package.env
+ bindir=@bindir@
+
+ ThePEG_CMD="${bindir}/setupThePEG"
+@@ -19,4 +19,4 @@
+
+
+
+-exec @java@ ${HEADLESS} -jar ${pkglibdir}/ThePEG.jar ${ThePEG_CMD} "$@"
++exec @java@ ${HEADLESS} -jar ${CLASSPATH} ${ThePEG_CMD} "$@"
diff --git a/sci-physics/thepeg/metadata.xml b/sci-physics/thepeg/metadata.xml
new file mode 100644
index 000000000..ca863dd54
--- /dev/null
+++ b/sci-physics/thepeg/metadata.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>sci</herd>
+<maintainer>
+ <email>maintainer-wanted@gentoo.org</email>
+</maintainer>
+<longdescription>
+ Toolkit for High Energy Physics Event Generation.
+ ThePEG has been broken out from the PYTHIA7 program
+ to better factorize the parts which were PYTHIA-specific
+ from those which are general model-independent components
+ of the toolkit and which can be used by any event generator model.
+</longdescription>
+<use>
+ <flag name='hepmc'>Adds support for High Energy Physics Monte Carlo
+ Generators <pkg>sci-physics/hepmc</pkg></flag>
+ <flag name='lhapdf'>Adds support for <pkg>sci-physics/lhapdf</pkg></flag>
+</use>
+</pkgmetadata>
diff --git a/sci-physics/thepeg/thepeg-1.8.0.ebuild b/sci-physics/thepeg/thepeg-1.8.0.ebuild
new file mode 100644
index 000000000..16982601b
--- /dev/null
+++ b/sci-physics/thepeg/thepeg-1.8.0.ebuild
@@ -0,0 +1,93 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=4
+
+inherit autotools elisp-common eutils java-pkg-opt-2
+
+MYP=ThePEG-${PV}
+
+DESCRIPTION="Toolkit for High Energy Physics Event Generation"
+HOMEPAGE="http://home.thep.lu.se/ThePEG/"
+SRC_URI="http://www.hepforge.org/archive/thepeg/${MYP}.tar.bz2
+ test? ( hepmc? (
+ http://www.hepforge.org/archive/lhapdf/pdfsets/current/cteq6ll.LHpdf
+ http://www.hepforge.org/archive/lhapdf/pdfsets/current/cteq5l.LHgrid
+ http://www.hepforge.org/archive/lhapdf/pdfsets/current/GRV98nlo.LHgrid
+ http://www.hepforge.org/archive/lhapdf/pdfsets/current/MRST2001nlo.LHgrid ) )"
+LICENSE="GPL-2"
+
+SLOT="0"
+KEYWORDS="~x86"
+IUSE="emacs hepmc java lhapdf test zlib"
+
+DEPEND="sci-libs/gsl
+ dev-lang/perl
+ emacs? ( virtual/emacs )
+ hepmc? ( sci-physics/hepmc )
+ java? ( >=virtual/jre-1.5 )
+ lhapdf? ( sci-physics/lhapdf )
+ zlib? ( sys-libs/zlib )
+"
+RDEPEND="${DEPEND}"
+DEPEND="${DEPEND}
+ test? ( sys-process/time )"
+
+S="${WORKDIR}/${MYP}"
+
+pkg_setup() {
+ elog "There is an extra option on package Rivet not yet in Gentoo:"
+ elog "You can use the env variable EXTRA_ECONF variable for this:"
+ elog "EXTRA_ECONF=\"--with-rivet=DIR\""
+ elog "where DIR - location of Rivet installation"
+ java-pkg-opt-2_pkg_setup
+}
+
+src_prepare() {
+ find -name 'Makefile.am' -exec sed -i '1ipkgdatadir=$(datadir)/thepeg' {} \; \
+ || die "changing pkgdatadir name failed"
+ sed -i '/dist_pkgdata_DATA = ThePEG.el/d' lib/Makefile.am \
+ || die "preventing install ThePEG.el in pkgdatadir failed"
+ epatch "${FILESDIR}"/${P}-java.patch
+ eautoreconf
+
+ java-pkg-opt-2_src_prepare
+}
+
+src_configure() {
+ econf \
+ --disable-silent-rules \
+ $(use_with hepmc hepmc "${EPREFIX}"/usr) \
+ $(use_with java javagui) \
+ $(use_with lhapdf LHAPDF "${EPREFIX}"/usr) \
+ $(use_with zlib zlib "${EPREFIX}"/usr)
+}
+
+src_compile() {
+ emake
+ if use emacs; then
+ elisp-compile lib/ThePEG.el || die
+ fi
+}
+
+src_test() {
+ emake LHAPATH="${DISTDIR}" check
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ if use emacs; then
+ elisp-install ${PN} lib/ThePEG.el lib/ThePEG.elc || die
+ fi
+ use java && java-pkg_newjar java/ThePEG.jar
+}
+
+pkg_postinst() {
+ if use emacs; then
+ elog "To use installed elisp file you should add"
+ elog "(add-to-list 'load-path \"${SITELISP}/${PN}\")"
+ elog "(load \"ThePEG\")"
+ elog "to your .emacs file"
+ fi
+}