summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Junghans <ottxor@gentoo.org>2013-06-26 23:53:11 +0000
committerChristoph Junghans <ottxor@gentoo.org>2013-06-26 23:53:11 +0000
commit4837639f5d42454d9fff6e693bf1ddf10228a671 (patch)
tree819bfcfeecff63e0aa494b04abc8e3d12f7c6da4 /sci-physics
parentversion bump (diff)
downloadgentoo-2-4837639f5d42454d9fff6e693bf1ddf10228a671.tar.gz
gentoo-2-4837639f5d42454d9fff6e693bf1ddf10228a671.tar.bz2
gentoo-2-4837639f5d42454d9fff6e693bf1ddf10228a671.zip
initial import from sci overlay
(Portage version: 2.2.0_alpha185/cvs/Linux x86_64, signed Manifest commit with key C2000586)
Diffstat (limited to 'sci-physics')
-rw-r--r--sci-physics/lammps/ChangeLog9
-rw-r--r--sci-physics/lammps/Manifest3
-rw-r--r--sci-physics/lammps/lammps-20130526.ebuild105
-rw-r--r--sci-physics/lammps/metadata.xml31
4 files changed, 148 insertions, 0 deletions
diff --git a/sci-physics/lammps/ChangeLog b/sci-physics/lammps/ChangeLog
new file mode 100644
index 000000000000..aaadf2cf306e
--- /dev/null
+++ b/sci-physics/lammps/ChangeLog
@@ -0,0 +1,9 @@
+# ChangeLog for sci-physics/lammps
+# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/sci-physics/lammps/ChangeLog,v 1.1 2013/06/26 23:53:11 ottxor Exp $
+
+*lammps-20130526 (26 Jun 2013)
+
+ 26 Jun 2013; Christoph Junghans <ottxor@gentoo.org> +lammps-20130526.ebuild,
+ +metadata.xml:
+ initial import from sci overlay
diff --git a/sci-physics/lammps/Manifest b/sci-physics/lammps/Manifest
new file mode 100644
index 000000000000..e5654b327355
--- /dev/null
+++ b/sci-physics/lammps/Manifest
@@ -0,0 +1,3 @@
+DIST lammps-26May13.tar.gz 46937785 SHA256 c3568846ac818857e9cb131f16a7298becd4bc26237a8c4423fb403fbf54d6c0 SHA512 71424d8a422424105a95c63bcdbdafca68f97beb0f7e4a4d8ac4df927191ea3003a73c94c19047953d278151bc6d59120cae49fa11b81e2ab23c719dbc26ca01 WHIRLPOOL b150311fef0d55ea4c046d9138512344ba4add646a712cf86ec1569302e7d96d1d166f67b2b6f452d4a0573b501bd3f25d1f4fb175d2daa261530a843da19d05
+EBUILD lammps-20130526.ebuild 2127 SHA256 a6f9624626076abdd9c061c6c384e41795276bdc8a7048b4b15a838d156bfcd8 SHA512 46896acbe8dffc9121fa1a6a7cb0591c52ade4ec592424d3bec7345976248e4d5c05131702270564ed80860aec9ddc31d7d5abdc0f690b40d9a46bfe18f2d6a4 WHIRLPOOL fcc046c23c12baf05b4bfd115e783f5adfbe9a4e787cad2ea7f49fe659ce139ade4e580def5591669bf4e89dca627393a84851780edd1b6067fa65723dd3e817
+MISC metadata.xml 1270 SHA256 47201b2a97ef17ce0e1a926841741e3d8e6f31b603bb5d6d4a435cf219ffbd25 SHA512 67ecfc6aa96c02dba47387c7d6952528b2d661dcee62e02c91d4675ec27da609697111a9847d516e4f11ec8ca6e621bec2120f7491b2f3adde8d6d3e7ec0ef03 WHIRLPOOL 8f544729cf6b75cb27d581ba50ed0207b6ca3ed272f4a234345543c68deb6334378be250266a04043dafb4f3ed2959697d2b6d9789b42e697fab7092eccb6c2f
diff --git a/sci-physics/lammps/lammps-20130526.ebuild b/sci-physics/lammps/lammps-20130526.ebuild
new file mode 100644
index 000000000000..4793d83055a1
--- /dev/null
+++ b/sci-physics/lammps/lammps-20130526.ebuild
@@ -0,0 +1,105 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-physics/lammps/lammps-20130526.ebuild,v 1.1 2013/06/26 23:53:11 ottxor Exp $
+
+EAPI=5
+
+FORTRAN_NEEDED="package-meam"
+
+inherit eutils fortran-2
+
+convert_month() {
+ case $1 in
+ 01) echo Jan
+ ;;
+ 02) echo Feb
+ ;;
+ 03) echo Mar
+ ;;
+ 04) echo Apr
+ ;;
+ 05) echo May
+ ;;
+ 06) echo Jun
+ ;;
+ 07) echo Jul
+ ;;
+ 08) echo Aug
+ ;;
+ 09) echo Sep
+ ;;
+ 10) echo Oct
+ ;;
+ 11) echo Nov
+ ;;
+ 12) echo Dec
+ ;;
+ *) echo unknown
+ ;;
+ esac
+}
+
+MY_P=${PN}-$((${PV:6:2}))$(convert_month ${PV:4:2})${PV:2:2}
+
+DESCRIPTION="Large-scale Atomic/Molecular Massively Parallel Simulator"
+HOMEPAGE="http://lammps.sandia.gov/"
+SRC_URI="http://lammps.sandia.gov/tars/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="doc examples gzip lammps-memalign mpi package-dipole package-meam package-rigid"
+
+DEPEND="mpi? ( virtual/mpi )"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${MY_P}"
+
+lmp_emake() {
+ local LAMMPS_INCLUDEFLAGS="$(usex gzip '-DLAMMPS_GZIP' '')"
+ LAMMPS_INCLUDEFLAGS+="$(usex lammps-memalign ' -DLAMMPS_MEMALIGN' '')"
+
+ # Note: The lammps makefile uses CC to indicate the C++ compiler.
+ emake \
+ ARCHIVE=$(tc-getAR) \
+ CC=$(usex mpi "mpic++" "$(tc-getCXX)") \
+ F90=$(usex mpi "mpif90" "$(tc-getFC)") \
+ LINK=$(usex mpi "mpic++" "$(tc-getCXX)") \
+ CCFLAGS="${CXXFLAGS}" \
+ F90FLAGS="${FCFLAGS}" \
+ LINKFLAGS="${LDFLAGS}" \
+ LMP_INC="${LAMMPS_INCLUDEFLAGS}" \
+ MPI_INC=$(usex mpi '' "-I../STUBS") \
+ MPI_PATH=$(usex mpi '' '-L../STUBS') \
+ MPI_LIB=$(usex mpi '' '-lmpi_stubs') \
+ "$@"
+}
+
+src_compile() {
+ # Compile stubs for serial version.
+ use mpi || lmp_emake -C src stubs
+
+ # Build optional packages.
+ if use package-meam; then
+ lmp_emake -C src yes-meam
+ lmp_emake -j1 -C lib/meam -f Makefile.gfortran
+ fi
+ use package-dipole && emake -C src yes-dipole
+ use package-rigid && emake -C src yes-rigid
+
+ # Compile.
+ lmp_emake -C src serial
+}
+
+src_install() {
+ newbin "src/lmp_serial" "lmp"
+ if use examples; then
+ insinto "/usr/share/doc/${PF}"
+ doins -r examples
+ fi
+ dodoc README
+ if use doc; then
+ dodoc doc/Manual.pdf
+ dohtml -r doc/*
+ fi
+}
diff --git a/sci-physics/lammps/metadata.xml b/sci-physics/lammps/metadata.xml
new file mode 100644
index 000000000000..1acfbc73e30b
--- /dev/null
+++ b/sci-physics/lammps/metadata.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <longdescription lang="en">
+ LAMMPS is a classical molecular dynamics code, and an acronym for
+ Large-scale Atomic/Molecular Massively Parallel Simulator.
+
+ LAMMPS has potentials for soft materials (biomolecules, polymers) and
+ solid-state materials (metals, semiconductors) and coarse-grained or
+ mesoscopic systems. It can be used to model atoms or, more generically,
+ as a parallel particle simulator at the atomic, meso, or continuum
+ scale.
+
+ LAMMPS runs on single processors or in parallel using message-passing
+ techniques and a spatial-decomposition of the simulation domain. The
+ code is designed to be easy to modify or extend with new functionality.
+ </longdescription>
+ <use>
+ <flag name="lammps-memalign">Enables the use of the posix_memalign()
+ call instead of malloc() when large chunks or memory are allocated
+ by LAMMPS</flag>
+ <flag name="package-meam">modified EAM potential</flag>
+ <flag name="package-dipole">point dipole particles</flag>
+ <flag name="package-rigid">rigid bodies</flag>
+ </use>
+ <herd>sci-physics</herd>
+ <maintainer>
+ <email>nicolasbock@gmail.com</email>
+ </maintainer>
+</pkgmetadata>
+