summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeffrey Gardner <je_fro@gentoo.org>2009-05-30 02:17:17 +0000
committerJeffrey Gardner <je_fro@gentoo.org>2009-05-30 02:17:17 +0000
commita88e2e89eee8bda9d2e27dab4aebe3e816b237ba (patch)
tree9303ada2e170097802624e30751ee56263c2d0af /sys-cluster
parentmanifest (diff)
downloadje_fro-a88e2e89eee8bda9d2e27dab4aebe3e816b237ba.tar.gz
je_fro-a88e2e89eee8bda9d2e27dab4aebe3e816b237ba.tar.bz2
je_fro-a88e2e89eee8bda9d2e27dab4aebe3e816b237ba.zip
latest charm for testing
svn path=/; revision=281
Diffstat (limited to 'sys-cluster')
-rw-r--r--sys-cluster/charm/Manifest4
-rw-r--r--sys-cluster/charm/charm-6.1.2.ebuild136
-rw-r--r--sys-cluster/charm/charm-9999.ebuild2
-rw-r--r--sys-cluster/charm/files/charm-6.1.2-charmrun.patch11
4 files changed, 151 insertions, 2 deletions
diff --git a/sys-cluster/charm/Manifest b/sys-cluster/charm/Manifest
index 4e109aa..2e9c116 100644
--- a/sys-cluster/charm/Manifest
+++ b/sys-cluster/charm/Manifest
@@ -1,3 +1,5 @@
+AUX charm-6.1.2-charmrun.patch 451 RMD160 f4f14fb156a5a402b16855624105c5ed4948b4d3 SHA1 844aedde27d8b0a4a5f585e0e9f040692d758eb2 SHA256 c4be50f38883b6882fd58e327be28741c1c54b13b0f7e57e4b101377fa2fc247
AUX charm-9999-charmc-gentoo.patch 963 RMD160 0f6001288cc8e9fa2d471c0d7cb9395d6fcd6399 SHA1 a68f5edab5da468a425dd8f17956c48ad0f85676 SHA256 b46d982eb9244d9e97cf7a48afd320e84788a060beddfa86b13be18547e93138
DIST charm_src.tar.gz 23903605 RMD160 6a4ec1e725001073903de0241f23c7e53cdb5e97 SHA1 0443fe79a4d7f489c227316a50927ed9c71685d5 SHA256 d30a6d069d334760fcf919d1f6dba3ac76b64336fe7570e43f91af8de5b21839
-EBUILD charm-9999.ebuild 3346 RMD160 6b88358a4bd81f42d87bb8a5373831f1e1259253 SHA1 b97746145c2723170cfeed6c3270400bbfbd278f SHA256 d846a76b0fd03d3f183f9a004d4c9c1550d03ba519835fb4f4f0337d1b0e4b5d
+EBUILD charm-6.1.2.ebuild 3127 RMD160 b8a976d4b278abe8f6118845712d466099220b0e SHA1 c79951e4d715170a8924973c18a42325d1ce2901 SHA256 0161e70cef60efde6d8adb1c1f32888f7832424423034f8c40278b2b2fdd26b7
+EBUILD charm-9999.ebuild 3335 RMD160 1dfce9d798191fe74bb5a04e9ba7bb3fddc7210f SHA1 4154bbb0eac565832074f6f03c526eb04afe5d00 SHA256 c75770a17900a6553339335fdeb63e72e409ef3f4eeab77f4ba18b41f1a66f09
diff --git a/sys-cluster/charm/charm-6.1.2.ebuild b/sys-cluster/charm/charm-6.1.2.ebuild
new file mode 100644
index 0000000..3ddca10
--- /dev/null
+++ b/sys-cluster/charm/charm-6.1.2.ebuild
@@ -0,0 +1,136 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+inherit eutils toolchain-funcs flag-o-matic
+
+DESCRIPTION="Charm++ is a message-passing parallel language and runtime system."
+LICENSE="charm"
+HOMEPAGE="http://charm.cs.uiuc.edu/"
+SRC_URI="${PN}_src.tar.gz"
+S="${WORKDIR}/${PN}"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="cmkopt tcp smp doc icc"
+
+DEPEND="icc? ( >=dev-lang/icc-8.1 )
+ doc? (
+ app-text/poppler
+ dev-tex/latex2html
+ virtual/tetex
+ )"
+
+case ${ARCH} in
+
+ x86)
+ CHARM_ARCH="net-linux" ;;
+
+ amd64)
+ CHARM_ARCH="net-linux-amd64" ;;
+esac
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}/${P}-charmrun.patch"
+
+ # TCP instead of default UDP for socket comunication
+ # protocol
+ if use tcp; then
+ CHARM_OPTS="${CHARM_OPTS} tcp"
+ fi
+
+ # enable direct SMP support using shared memory
+ if [ use smp ] && [ -x ${ARCH} != amd64 ]; then
+ CHARM_OPTS="${CHARM_OPTS} smp"
+ fi
+
+ # compile with icc if requested
+ if use icc; then
+ if [ $(tc-getCC) != "icc" ]; then
+ die "You cannot use $(tc-getCC) with USE='icc'"
+ fi
+ CHARM_OPTS="${CHARM_OPTS} icc"
+ fi
+
+ # CMK optimization
+ if use cmkopt; then
+ append-flags -DCMK_OPTIMIZE=1
+ fi
+}
+
+src_compile() {
+ # build charmm++ first
+pwd
+cd "${S}"
+ ./build charm++ ${CHARM_ARCH} ${CHARM_OPTS} ${CFLAGS} || \
+ die "Failed to build charm++"
+
+ # make pdf/html docs
+ if use doc; then
+ cd "${S}"/doc
+ make doc || die "failed to create pdf/html docs"
+ fi
+}
+
+src_install() {
+ # make charmc play well with gentoo before
+ # we move it into /usr/bin
+ einfo "Fixing paths in charmc wrapper"
+ epatch "${FILESDIR}"/${P}-charmc-gentoo.patch
+
+ cd "${S}"
+ sed -e "s/gentoo-include/${P}/" -i ./src/scripts/charmc || \
+ die "failed patching charmc script"
+
+ # install binaries
+ cd "${S}"/bin
+ dobin ./charmd ./charmd_faceless ./charmr* ./charmc ./charmxi \
+ ./conv-cpm ./dep.pl || die "Failed to install binaries"
+
+ # install headers
+ cd "${S}"/include
+ insinto /usr/include/${P}
+ doins * || die "failed to install header files"
+
+ # install static libs
+ cd "${S}"/lib
+ dolib.a * || die "failed to install static libs"
+
+ # install shared libs
+ cd "${S}"/lib_so
+ dolib.so * || die "failed to install shared libs"
+
+ # basic docs
+ cd "${S}"
+ dodoc CHANGES README || die "Failed to install docs"
+
+ # install examples after fixing path to charmc
+ find examples/ -name 'Makefile' | xargs sed \
+ -r "s:(../)+bin/charmc:/usr/bin/charmc:" -i || \
+ die "Failed to fix examples"
+ find examples/ -name 'Makefile' | xargs sed \
+ -r "s:./charmrun:./charmrun ++local:" -i || \
+ die "Failed to fix examples"
+ insinto /usr/share/doc/${PF}/examples
+ doins -r examples/charm++/*
+
+ # pdf/html docs
+ if use doc; then
+ cd "${S}"/doc
+ # install pdfs
+ insinto /usr/share/doc/${PF}/pdf
+ doins doc/pdf/* || die "failed to install pdf docs"
+ # install html
+ docinto html
+ dohtml -r doc/html/* || die "failed to install html docs"
+ fi
+}
+
+pkg_postinst() {
+ echo
+ einfo "Please test your charm installation by copying the"
+ einfo "content of /usr/share/doc/${PF}/examples to a"
+ einfo "temporary location and run 'make test'."
+ echo
+}
diff --git a/sys-cluster/charm/charm-9999.ebuild b/sys-cluster/charm/charm-9999.ebuild
index 5691935..127eba3 100644
--- a/sys-cluster/charm/charm-9999.ebuild
+++ b/sys-cluster/charm/charm-9999.ebuild
@@ -10,7 +10,7 @@ HOMEPAGE="http://charm.cs.uiuc.edu/"
SRC_URI="${PN}_src.tar.gz"
S="${WORKDIR}/${PN}"
SLOT="0"
-KEYWORDS="~amd64 ~x86"
+KEYWORDS=""
IUSE="cmkopt tcp smp doc icc"
RESTRICT="fetch"
diff --git a/sys-cluster/charm/files/charm-6.1.2-charmrun.patch b/sys-cluster/charm/files/charm-6.1.2-charmrun.patch
new file mode 100644
index 0000000..eff6c85
--- /dev/null
+++ b/sys-cluster/charm/files/charm-6.1.2-charmrun.patch
@@ -0,0 +1,11 @@
+--- src/arch/net/charmrun/charmrun.c.orig 2009-05-29 21:01:16.773778549 -0500
++++ src/arch/net/charmrun/charmrun.c 2009-05-29 21:02:38.868587242 -0500
+@@ -1291,7 +1291,7 @@
+ char *tmp=tmpnam(NULL);/*This was once /tmp/fnord*/
+ #endif
+ unlink(tmp);
+- fd = open(tmp,O_RDWR | O_CREAT | O_TRUNC);
++ fd = open(tmp,O_RDWR | O_CREAT | O_TRUNC, 0666);
+ if (fd<0) {
+ fprintf(stderr,"cannot open temp file /tmp/fnord");
+ exit(1);