From 617aa8caae1d7cb83836d530be7174ce5e10ad2a Mon Sep 17 00:00:00 2001 From: Nicolas Bock Date: Fri, 10 May 2013 10:00:08 -0600 Subject: Added first draft version of lammps. For now this is only the serial version. Package-Manager: portage-2.2.0_alpha174 --- sci-physics/lammps/ChangeLog | 9 ++ sci-physics/lammps/Manifest | 1 + .../lammps/files/Makefile.gentoo-serial.patch | 111 +++++++++++++++++++++ sci-physics/lammps/lammps-20130512.ebuild | 36 +++++++ sci-physics/lammps/metadata.xml | 19 ++++ 5 files changed, 176 insertions(+) create mode 100644 sci-physics/lammps/ChangeLog create mode 100644 sci-physics/lammps/Manifest create mode 100755 sci-physics/lammps/files/Makefile.gentoo-serial.patch create mode 100644 sci-physics/lammps/lammps-20130512.ebuild create mode 100644 sci-physics/lammps/metadata.xml diff --git a/sci-physics/lammps/ChangeLog b/sci-physics/lammps/ChangeLog new file mode 100644 index 000000000..d717a1883 --- /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: $ + +*lammps-20130512 (10 May 2013) + + 10 May 2013; Nicolas Bock + +files/Makefile.gentoo-serial.patch, +lammps-20130512.ebuild, +metadata.xml: + Added first draft version of lammps. For now this is only the serial version. diff --git a/sci-physics/lammps/Manifest b/sci-physics/lammps/Manifest new file mode 100644 index 000000000..2ffa747c4 --- /dev/null +++ b/sci-physics/lammps/Manifest @@ -0,0 +1 @@ +DIST lammps-12May13.tar.gz 46932918 SHA256 d2ac793bda61edb17d128320a778b2cb2fcfae78082b8a5ad2703ccb099521c4 SHA512 85c20e0ae951e63eccc40d64541b2f628cd5fcc9928d66ecf1da99dee6b5b0633fa69a64076ecea98e3eda39857e43a5f13d6469a94f0b85da8902eb49482487 WHIRLPOOL f2f8e592c590dbf57b22b64fbe213f037669b64ad30dab59d7ddfd385e5223d1cf93bf1ff6b8527bdfc08cf06069a66d53f8e4eae22f6e2ed27d4a2bce97959a diff --git a/sci-physics/lammps/files/Makefile.gentoo-serial.patch b/sci-physics/lammps/files/Makefile.gentoo-serial.patch new file mode 100755 index 000000000..7b9267cec --- /dev/null +++ b/sci-physics/lammps/files/Makefile.gentoo-serial.patch @@ -0,0 +1,111 @@ +--- /dev/null 2013-04-18 18:31:27.695818552 -0600 ++++ src/MAKE/Makefile.gentoo-serial 2013-05-09 15:24:20.000000000 -0600 +@@ -0,0 +1,108 @@ ++# gentoo-serial = Gentoo, serial code ++ ++SHELL = /bin/sh ++ ++# --------------------------------------------------------------------- ++# compiler/linker settings ++# specify flags and libraries needed for your compiler ++ ++CC = g++ ++CCFLAGS = -g -O # -Wunused ++SHFLAGS = -fPIC ++DEPFLAGS = -M ++ ++LINK = g++ ++LINKFLAGS = -g -O ++LIB = ++SIZE = size ++ ++ARCHIVE = ar ++ARFLAGS = -rc ++SHLIBFLAGS = -shared ++ ++# --------------------------------------------------------------------- ++# LAMMPS-specific settings ++# specify settings for LAMMPS features you will use ++# if you change any -D setting, do full re-compile after "make clean" ++ ++# LAMMPS ifdef settings, OPTIONAL ++# see possible settings in doc/Section_start.html#2_2 (step 4) ++ ++LMP_INC = -DLAMMPS_GZIP ++ ++# MPI library, REQUIRED ++# see discussion in doc/Section_start.html#2_2 (step 5) ++# can point to dummy MPI library in src/STUBS as in Makefile.serial ++# INC = path for mpi.h, MPI compiler settings ++# PATH = path for MPI library ++# LIB = name of MPI library ++ ++MPI_INC = -I../STUBS ++MPI_PATH = -L../STUBS ++MPI_LIB = -lmpi_stubs ++ ++# FFT library, OPTIONAL ++# see discussion in doc/Section_start.html#2_2 (step 6) ++# can be left blank to use provided KISS FFT library ++# INC = -DFFT setting, e.g. -DFFT_FFTW, FFT compiler settings ++# PATH = path for FFT library ++# LIB = name of FFT library ++ ++FFT_INC = ++FFT_PATH = ++FFT_LIB = ++ ++# JPEG library, OPTIONAL ++# see discussion in doc/Section_start.html#2_2 (step 7) ++# only needed if -DLAMMPS_JPEG listed with LMP_INC ++# INC = path for jpeglib.h ++# PATH = path for JPEG library ++# LIB = name of JPEG library ++ ++JPG_INC = ++JPG_PATH = ++JPG_LIB = ++ ++# --------------------------------------------------------------------- ++# build rules and dependencies ++# no need to edit this section ++ ++include Makefile.package.settings ++include Makefile.package ++ ++EXTRA_INC = $(LMP_INC) $(PKG_INC) $(MPI_INC) $(FFT_INC) $(JPG_INC) $(PKG_SYSINC) ++EXTRA_PATH = $(PKG_PATH) $(MPI_PATH) $(FFT_PATH) $(JPG_PATH) $(PKG_SYSPATH) ++EXTRA_LIB = $(PKG_LIB) $(MPI_LIB) $(FFT_LIB) $(JPG_LIB) $(PKG_SYSLIB) ++ ++# Path to src files ++ ++vpath %.cpp .. ++vpath %.h .. ++ ++# Link target ++ ++$(EXE): $(OBJ) ++ $(LINK) $(LINKFLAGS) $(EXTRA_PATH) $(OBJ) $(EXTRA_LIB) $(LIB) -o $(EXE) ++ $(SIZE) $(EXE) ++ ++# Library targets ++ ++lib: $(OBJ) ++ $(ARCHIVE) $(ARFLAGS) $(EXE) $(OBJ) ++ ++shlib: $(OBJ) ++ $(CC) $(CCFLAGS) $(SHFLAGS) $(SHLIBFLAGS) $(EXTRA_PATH) -o $(EXE) \ ++ $(OBJ) $(EXTRA_LIB) $(LIB) ++ ++# Compilation rules ++ ++%.o:%.cpp ++ $(CC) $(CCFLAGS) $(SHFLAGS) $(EXTRA_INC) -c $< ++ ++%.d:%.cpp ++ $(CC) $(CCFLAGS) $(EXTRA_INC) $(DEPFLAGS) $< > $@ ++ ++# Individual dependencies ++ ++DEPENDS = $(OBJ:.o=.d) ++sinclude $(DEPENDS) diff --git a/sci-physics/lammps/lammps-20130512.ebuild b/sci-physics/lammps/lammps-20130512.ebuild new file mode 100644 index 000000000..328c94e69 --- /dev/null +++ b/sci-physics/lammps/lammps-20130512.ebuild @@ -0,0 +1,36 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 + +inherit eutils + +LAMMPSDATE="12May13" + +DESCRIPTION="Large-scale Atomic/Molecular Massively Parallel Simulator" +HOMEPAGE="http://lammps.sandia.gov/" +SRC_URI="http://lammps.sandia.gov/tars/lammps-${LAMMPSDATE}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +DEPEND="" +RDEPEND="${DEPEND}" + +S="${WORKDIR}/${PN}-${LAMMPSDATE}" + +src_prepare() { + epatch "${FILESDIR}/Makefile.gentoo-serial.patch" +} + +src_compile() { + emake -C src ARCHIVE=$(tc-getAR) CC=$(tc-getCXX) CCFLAGS="${CXXFLAGS}" LINKFLAGS="${LDFLAGS}" stubs + emake -C src ARCHIVE=$(tc-getAR) CC=$(tc-getCXX) CCFLAGS="${CXXFLAGS}" LINKFLAGS="${LDFLAGS}" gentoo-serial +} + +src_install() { + newbin "$S/src/lmp_gentoo-serial" "lmp-serial" +} diff --git a/sci-physics/lammps/metadata.xml b/sci-physics/lammps/metadata.xml new file mode 100644 index 000000000..69268b89f --- /dev/null +++ b/sci-physics/lammps/metadata.xml @@ -0,0 +1,19 @@ + + + + + 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. + + + -- cgit v1.2.3-65-gdbad