diff options
author | stephen <stephen@FreeBSD.org> | 2011-06-21 10:19:07 +0800 |
---|---|---|
committer | stephen <stephen@FreeBSD.org> | 2011-06-21 10:19:07 +0800 |
commit | d75ecbf491a3a677ae23eb4ebbb2304af5717b0b (patch) | |
tree | 9fe17a865ea313900e77abd3faa5831a18ac27a6 /science | |
parent | 7fa713f7d1daee23e198edae2d6ce4a757f2fcb4 (diff) | |
download | freebsd-ports-gnome-d75ecbf491a3a677ae23eb4ebbb2304af5717b0b.tar.gz freebsd-ports-gnome-d75ecbf491a3a677ae23eb4ebbb2304af5717b0b.tar.zst freebsd-ports-gnome-d75ecbf491a3a677ae23eb4ebbb2304af5717b0b.zip |
- Add optional dependency net/openmpi
- Add lib_depends textproc/gsed
- Make datadir safe
- Move pkgconfig from lib to libdata
- Make patches to configure prefix friendly
PR: ports/155655
Submitted by: Klaus Aehlig <aehlig@linta.de>
Approved by: maho (mentor) and
Stas Timokhin <devel@stasyan.com> (maintainer)
Diffstat (limited to 'science')
-rw-r--r-- | science/meep/Makefile | 42 | ||||
-rw-r--r-- | science/meep/distinfo | 1 | ||||
-rw-r--r-- | science/meep/files/patch-Makefile.in | 19 | ||||
-rw-r--r-- | science/meep/files/patch-configure | 42 | ||||
-rw-r--r-- | science/meep/pkg-plist | 20 |
5 files changed, 88 insertions, 36 deletions
diff --git a/science/meep/Makefile b/science/meep/Makefile index 6a8cb9f49dd6..19d927604f9e 100644 --- a/science/meep/Makefile +++ b/science/meep/Makefile @@ -7,31 +7,51 @@ PORTNAME= meep PORTVERSION= 1.1.1 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= science MASTER_SITES= http://ab-initio.mit.edu/meep/ MAINTAINER= devel@stasyan.com COMMENT= FDTD simulation software to model electromagnetic systems +BUILD_DEPENDS+= bash:${PORTSDIR}/shells/bash \ + harminv:${PORTSDIR}/science/harminv \ + gsed:${PORTSDIR}/textproc/gsed +LIB_DEPENDS+= guile.20:${PORTSDIR}/lang/guile \ + blas.2:${PORTSDIR}/math/blas \ + ctl.4:${PORTSDIR}/science/libctl \ + hdf5.0:${PORTSDIR}/science/hdf5 +RUN_DEPENDS+= harminv:${PORTSDIR}/science/harminv + USE_GMAKE= yes GNU_CONFIGURE= yes USE_FORTRAN= yes -USE_GCC= 4.4+ +USE_GCC= 4.5+ USE_ICONV= yes USE_GETTEXT= yes USE_AUTOTOOLS+= libltdl CPPFLAGS+= -I${LOCALBASE}/include LD_LIBRARY_PATH= -L${LOCALBASE}/lib -L/usr/lib LDFLAGS+= -L${LOCALBASE}/lib -CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" LD_LIBRARY_PATH="${LD_LIBRARY_PATH}" LDFLAGS="${LDFLAGS}" +CONFIGURE_ENV+= LD_LIBRARY_PATH="${LD_LIBRARY_PATH}" LDFLAGS="${LDFLAGS}" -BUILD_DEPENDS+= bash:${PORTSDIR}/shells/bash \ - harminv:${PORTSDIR}/science/harminv -LIB_DEPENDS+= guile.20:${PORTSDIR}/lang/guile \ - blas.2:${PORTSDIR}/math/blas \ - ctl.4:${PORTSDIR}/science/libctl \ - hdf5.0:${PORTSDIR}/science/hdf5 -RUN_DEPENDS+= harminv:${PORTSDIR}/science/harminv +OPTIONS= OPENMPI "Enable MPI support using openmpi" On + +.include <bsd.port.pre.mk> + +.if defined(WITH_OPENMPI) +BUILD_DEPENDS+= ${LOCALBASE}/mpi/openmpi/bin/mpiCC:${PORTSDIR}/net/openmpi +RUN_DEPENDS+= ${LOCALBASE}/mpi/openmpi/bin/mpirun:${PORTSDIR}/net/openmpi +CONFIGURE_ARGS+=--with-mpi +CONFIGURE_ENV+= MPICXX=${LOCALBASE}/mpi/openmpi/bin/mpiCC +PLIST_SUB+= MPI="" NOMPI="@comment " +.else +CONFIGURE_ARGS+=--without-mpi +PLIST_SUB+= MPI="@comment " NOMPI="" +.endif + +post-patch: + ${REINPLACE_CMD} -e 's+\#\! /bin/sh+\#\! ${PREFIX}/bin/bash+' \ + -e s+\$$\(SHELL\)+${PREFIX}/bin/bash+ ${WRKSRC}/configure -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/science/meep/distinfo b/science/meep/distinfo index 2e8ee0180c4a..4c7e391373eb 100644 --- a/science/meep/distinfo +++ b/science/meep/distinfo @@ -1,3 +1,2 @@ -MD5 (meep-1.1.1.tar.gz) = 415e0cd312b6caa22b5dd612490e1ccf SHA256 (meep-1.1.1.tar.gz) = 7a97b5555da1f9ea2ec6eed5c45bd97bcd6ddbd54bdfc181f46c696dffc169f2 SIZE (meep-1.1.1.tar.gz) = 751244 diff --git a/science/meep/files/patch-Makefile.in b/science/meep/files/patch-Makefile.in new file mode 100644 index 000000000000..375273bfb20a --- /dev/null +++ b/science/meep/files/patch-Makefile.in @@ -0,0 +1,19 @@ +--- Makefile.in.orig 2009-08-21 16:34:59.000000000 +0000 ++++ Makefile.in 2011-06-19 22:14:02.000000000 +0000 +@@ -264,6 +264,7 @@ + infodir = @infodir@ + install_sh = @install_sh@ + libdir = @libdir@ ++libdatadir = @libdatadir@ + libexecdir = @libexecdir@ + localedir = @localedir@ + localstatedir = @localstatedir@ +@@ -288,7 +289,7 @@ + ACLOCAL_AMFLAGS = -I m4 + SUBDIRS = src $(LIBCTL) tests examples + EXTRA_DIST = COPYRIGHT m4 meep-pkgconfig.in +-pkgconfigdir = $(libdir)/pkgconfig ++pkgconfigdir = $(libdatadir)/pkgconfig + pkgconfig_DATA = meep@MEEP_SUFFIX@.pc + DISTCLEANFILES = meep@MEEP_SUFFIX@.pc + all: config.h diff --git a/science/meep/files/patch-configure b/science/meep/files/patch-configure index 8fa222f9213e..32598264b014 100644 --- a/science/meep/files/patch-configure +++ b/science/meep/files/patch-configure @@ -1,17 +1,27 @@ ---- configure.orig 2009-08-21 23:35:00.000000000 +0700 -+++ configure 2009-12-26 13:21:45.000000000 +0600 -@@ -1,4 +1,4 @@ --#! /bin/sh -+#! /usr/local/bin/bash - # Guess values for system-dependent variables and create Makefiles. - # Generated by GNU Autoconf 2.63 for meep 1.1.1. - # -@@ -10318,7 +10318,7 @@ - LIBTOOL_DEPS="$ltmain" - - # Always use our own libtool. --LIBTOOL='$(SHELL) $(top_builddir)/libtool' -+LIBTOOL='/usr/local/bin/bash $(top_builddir)/libtool' - - +--- configure.orig 2009-08-21 16:35:00.000000000 +0000 ++++ configure 2011-06-19 22:08:46.000000000 +0000 +@@ -920,6 +920,7 @@ + datadir + datarootdir + libexecdir ++libdatadir + sbindir + bindir + program_transform_name +@@ -1002,6 +1003,7 @@ + bindir='${exec_prefix}/bin' + sbindir='${exec_prefix}/sbin' + libexecdir='${exec_prefix}/libexec' ++libdatadir='${exec_prefix}/libdata' + datarootdir='${prefix}/share' + datadir='${datarootdir}' + sysconfdir='${prefix}/etc' +@@ -1398,7 +1400,7 @@ + fi + # Check all directory arguments for consistency. +-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ ++for ac_var in exec_prefix prefix bindir sbindir libexecdir libdatadir datarootdir \ + datadir sysconfdir sharedstatedir localstatedir includedir \ + oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ + libdir localedir mandir diff --git a/science/meep/pkg-plist b/science/meep/pkg-plist index 2a0db0cf58a7..df1df70a9719 100644 --- a/science/meep/pkg-plist +++ b/science/meep/pkg-plist @@ -1,13 +1,17 @@ -bin/meep +%%NOMPI%%bin/meep +%%MPI%%bin/meep-mpi include/meep.hpp include/meep/mympi.hpp include/meep/vec.hpp -lib/libmeep.a -lib/libmeep.la -lib/pkgconfig/meep.pc -share/meep/casimir.scm -share/meep/meep-enums.scm -share/meep/meep.scm -@dirrm share/meep +%%NOMPI%%lib/libmeep.a +%%MPI%%lib/libmeep_mpi.a +%%NOMPI%%lib/libmeep.la +%%MPI%%lib/libmeep_mpi.la +%%NOMPI%%libdata/pkgconfig/meep.pc +%%MPI%%libdata/pkgconfig/meep_mpi.pc +%%DATADIR%%/casimir.scm +%%DATADIR%%/meep-enums.scm +%%DATADIR%%/meep.scm +@dirrm %%DATADIR%% @dirrmtry lib/pkgconfig @dirrm include/meep |