Index: head/science/dftbplus/Makefile =================================================================== --- head/science/dftbplus/Makefile (revision 479689) +++ head/science/dftbplus/Makefile (revision 479690) @@ -1,70 +1,69 @@ # $FreeBSD$ PORTNAME= dftbplus DISTVERSION= 18.2 PORTREVISION= 1 CATEGORIES= science MAINTAINER= yuri@FreeBSD.org COMMENT= DFTB+: Package for performing fast atomistic simulations -LICENSE= LGPL3+ GPLv1 # main code is under LGPL3+, the bundled dftd3-lib is under GPLv1 -LICENSE_COMB= multi +LICENSE= GPLv3 # main code is under LGPL3+, the bundled dftd3-lib is under GPLv1+, this makes the result GPLv3 (based on https://www.gnu.org/licenses/gpl-faq.html#AllCompatibility) LIB_DEPENDS= libblas.so:math/blas \ liblapack.so:math/lapack \ libomp.so:devel/openmp RUN_DEPENDS= ${PYNUMPY} USES= fortran gmake python shebangfix SHEBANG_FILES= tools/dptools/bin/* tools/misc/* utils/srcmanip/* utils/build/* external/fypp/bin/* utils/get_opt_externals \ external/fypp/bin/fypp utils/test/testlist_to_fypp test/prog/dftb+/bin/tagdiff SHEBANG_GLOB= *.py USE_GITHUB= yes GH_TUPLE= dftbplus:mpifx:099ff75:mpifx/external/mpifx/origin \ dftbplus:scalapackfx:86cd6e4:scalapackfx/external/scalapackfx/origin \ dftbplus:dftd3-lib:00504a9:dftd3/external/dftd3/origin \ dftbplus:testparams:1601609:testparams/external/slakos/origin MAKEFILE= makefile TEST_TARGET= test FFLAGS+= -I${LOCALBASE}/include LDFLAGS+= -llapack -lblas ${LOCALBASE}/lib/gcc${GCC_DEFAULT}/libgcc_s.so ${LOCALBASE}/lib/gcc${GCC_DEFAULT}/libgfortran.so -lm ${LOCALBASE}/lib/libomp.so MAKE_ARGS= PYTHON=${PYTHON_CMD} FC=${FC} FXX=${FC} LN=${CC} \ INSTALLDIR=${STAGEDIR}${PREFIX} FREEBSD_PYDISTUTILS_INSTALLARGS="${PYDISTUTILS_INSTALLARGS} --root=${STAGEDIR}" OPTIONS_DEFINE= DFTD3 MPI SOCKETS ARPACK OPTIONS_DEFAULT= DFTD3 MPI SOCKETS DFTD3_DESC= Build with libdft3 DFTD3_MAKE_ARGS= WITH_DFTD3=1 DFTD3_MAKE_ARGS_OFF= WITH_DFTD3=0 MPI_MAKE_ARGS= WITH_MPI=1 MPI_MAKE_ARGS_OFF= WITH_MPI=0 MPI_LIB_DEPENDS= libmpich.so:net/mpich2 \ libscalapack.so:math/scalapack MPI_LDFLAGS= ${LOCALBASE}/lib/libmpich.so SOCKETS_DESC= Build with sockets library SOCKETS_MAKE_ARGS= WITH_SOCKETS=1 SOCKETS_MAKE_ARGS_OFF= WITH_SOCKETS=0 SOCKETS_BINARY_ALIAS= gcc=${CC} ARPACK_DESC= Build with ARPACK for large eigenvalue problems ARPACK_MAKE_ARGS= WITH_ARPACK=1 ARPACK_MAKE_ARGS_OFF= WITH_ARPACK=0 ARPACK_LIB_DEPENDS= libarpack.so:math/arpack ARPACK_PREVENTS= MPI # ARPACK is only used in a single-core application MAKE_JOBS_UNSAFE= yes # race conditions when some options are ON post-extract: @${RM} ${WRKSRC}/external/scalapackfx/origin/test/psyr_result.dat.orig @cd ${WRKSRC} && ${CP} sys/make.x86_64-linux-gnu make.arch post-install: @cd ${STAGEDIR}${PREFIX}/bin && ${STRIP_CMD} dftb+ modes waveplot .include Index: head/science/dftbplus/files/patch-external_xmlf90_make.dpbuild =================================================================== --- head/science/dftbplus/files/patch-external_xmlf90_make.dpbuild (revision 479689) +++ head/science/dftbplus/files/patch-external_xmlf90_make.dpbuild (nonexistent) @@ -1,11 +0,0 @@ ---- external/xmlf90/make.dpbuild.orig 2018-09-12 21:14:34 UTC -+++ external/xmlf90/make.dpbuild -@@ -31,7 +31,7 @@ clean: - rm -f *.o _mod_* *.mod - - %.o: %.f90 -- $(FXX) $(FXXOPT) -o $@ -c $< -+ $(FXX) -c $(FXXOPT) -o $@ -c $< - - _mod_%: - @[ -f $< ] && touch $@ Property changes on: head/science/dftbplus/files/patch-external_xmlf90_make.dpbuild ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/science/dftbplus/files/patch-make.arch =================================================================== --- head/science/dftbplus/files/patch-make.arch (revision 479689) +++ head/science/dftbplus/files/patch-make.arch (revision 479690) @@ -1,57 +1,57 @@ --- make.arch.orig 2018-09-12 23:49:19 UTC +++ make.arch @@ -13,17 +13,17 @@ FXX = mpif90 CC = gcc # Compiler options -FXXOPT = -O2 -funroll-all-loops -fopenmp -CCOPT = -O2 -funroll-all-loops -fall-intrinsics +FXXOPT = $(FFLAGS) -funroll-all-loops -fopenmp +CCOPT = $(CFLAGS) -funroll-all-loops -fall-intrinsics # Linker LN = $(FXX) -LNOPT = -fopenmp +LNOPT = $(LDFLAGS) -fopenmp # How to link specific libraries # ScaLAPACK -SCALAPACKDIR = /usr/lib -+SCALAPACKDIR = $(PREFIX) ++SCALAPACKDIR = $(PREFIX)/lib LIB_SCALAPACK = -L$(SCALAPACKDIR) -lscalapack # LAPACK/BLAS @@ -49,12 +49,12 @@ FXX = gfortran CC = gcc # Compiler options -FXXOPT = -O2 -funroll-all-loops -fopenmp -CCOPT = -O2 -funroll-all-loops -fall-intrinsics +FXXOPT = $(FFLAGS) -funroll-all-loops -fopenmp +CCOPT = $(CFLAGS) -funroll-all-loops -fall-intrinsics # Linker LN = $(FXX) -LNOPT = -fopenmp +LNOPT = $(LDFLAGS) -fopenmp # How to link specific libraries @@ -88,12 +88,12 @@ LIBOPT = # Override options for different DEBUG modes ifeq ($(strip $(DEBUG)),1) OTHERLIBS = - FXXOPT = -fopenmp -g -Wall -std=f2008 -pedantic - CCOPT = -g -Wall -pedantic -fall-intrinsics + FXXOPT = $(FFLAGS) -fopenmp -g -Wall -std=f2008 -pedantic + CCOPT = $(CFLAGS) -g -Wall -pedantic -fall-intrinsics endif ifeq ($(strip $(DEBUG)),2) OTHERLIBS = - FXXOPT = -fopenmp -g -Wall -std=f2008 -pedantic -fbounds-check - CCOPT = -g -Wall -pedantic -fall-intrinsics -fbounds-check + FXXOPT = $(FFLAGS) -fopenmp -g -Wall -std=f2008 -pedantic -fbounds-check + CCOPT = $(CFLAGS) -g -Wall -pedantic -fall-intrinsics -fbounds-check endif Index: head/science/dftbplus/files/patch-make.config =================================================================== --- head/science/dftbplus/files/patch-make.config (revision 479689) +++ head/science/dftbplus/files/patch-make.config (revision 479690) @@ -1,18 +1,13 @@ --- make.config.orig 2018-08-17 17:13:08 UTC +++ make.config -@@ -55,12 +55,12 @@ COMPILE_DFTD3 := 1 +@@ -55,8 +55,8 @@ COMPILE_DFTD3 := 1 # Set the compile time include and the link time library options for # dftd3-lib. Ignored if WITH_DFTD3 has been disabled or COMPILE_DFTD3 enabled. -DFTD3_INCS := -I/usr/local/include/dftd3-lib -DFTD3_LIBS := -L/usr/local/lib -ldftd3 +DFTD3_INCS := -I$(PREFIX)/include/dftd3-lib +DFTD3_LIBS := -L$(PREFIX)/lib -ldftd3 # Link time library options for linking ARPACK. Ignored if WITH_ARPACK was # disabled. --ARPACK_LIBS := -larpack -+ARPACK_LIBS := $(PREFIX)/lib/libarpack.so - - # Whether ARPACK depends on the external LAPACK and BLAS libraries - ARPACK_NEEDS_LAPACK := 0 Index: head/science/dftbplus/files/patch-makefile =================================================================== --- head/science/dftbplus/files/patch-makefile (revision 479689) +++ head/science/dftbplus/files/patch-makefile (revision 479690) @@ -1,27 +1,22 @@ --- makefile.orig 2018-08-17 17:13:08 UTC +++ makefile @@ -10,7 +10,9 @@ ROOT := $(PWD) .PHONY: default misc all default: dftb+ modes waveplot misc: misc_skderivs misc_slakovalue -all: default misc +all: print-WITH_DFTD3 print-WITH_MPI print-WITH_SOCKETS print-WITH_ARPACK default misc + +print-% : ; @echo "Build variable: " $* = $($*) .PHONY: install install_misc install_all install: install_dftb+ install_modes install_waveplot install_dptools -@@ -123,11 +125,11 @@ install_misc_skderivs install_misc_slako - ROOT=$(ROOT) BUILDROOT=$(BUILDDIR) install - - --PYTHON := python -+PYTHON ?= python +@@ -127,7 +129,7 @@ PYTHON := python .PHONY: install_dptools install_dptools: cd $(ROOT)/tools/dptools \ - && $(PYTHON) setup.py install --prefix $(INSTALLDIR) + && $(PYTHON) setup.py install $(FREEBSD_PYDISTUTILS_INSTALLARGS) ################################################################################ # Check targets