diff --git a/lib/atc/LammpsInterface.cpp b/lib/atc/LammpsInterface.cpp index 4959ce0855c7d2e48d678bba17d277c0b02cc9d7..a6a054b060d976d5593a8b7fa95c395bade3e838 100644 --- a/lib/atc/LammpsInterface.cpp +++ b/lib/atc/LammpsInterface.cpp @@ -3,6 +3,7 @@ // LAMMPS includes #include "lammps.h" +#include "lmptype.h" #include "atom.h" // x, v, f #include "domain.h" // for basing locations on regions #include "region.h" // region bounding box and style @@ -609,7 +610,7 @@ void LammpsInterface::atomPE_init(void) } } -void LammpsInterface::atomPE_addstep(int step) +void LammpsInterface::atomPE_addstep(LAMMPS_NS::bigint step) { atomPE_->addstep(step); } diff --git a/lib/atc/Makefile.g++ b/lib/atc/Makefile.g++ index 66361ebc5d07f15112bcc6585425e00cad9e9735..5b12e403ab47c17571c366c7cd7a2329f3fe36b6 100644 --- a/lib/atc/Makefile.g++ +++ b/lib/atc/Makefile.g++ @@ -131,4 +131,4 @@ DEPENDS = $(OBJ:.o=.d) # ------ CLEAN ------ clean: - rm *.o *.d *~ $(LIB) + -rm *.o *.d *~ $(LIB) diff --git a/lib/atc/Makefile.lammps b/lib/atc/Makefile.lammps new file mode 100644 index 0000000000000000000000000000000000000000..c8cd66af26957af7143783f533aa30683df0c3d9 --- /dev/null +++ b/lib/atc/Makefile.lammps @@ -0,0 +1,5 @@ +# Settings that the LAMMPS build will import when this package library is used + +user-atc_SYSINC = +user-atc_SYSLIB = -lblas -llapack +user-atc_SYSPATH = diff --git a/lib/atc/Makefile.lammps.linalg b/lib/atc/Makefile.lammps.linalg index 742b09f781f3d32e316089411d526bd76eb87531..5d92fd8cfb2a798fee127638f2b1319e5611da25 100644 --- a/lib/atc/Makefile.lammps.linalg +++ b/lib/atc/Makefile.lammps.linalg @@ -2,4 +2,5 @@ user-atc_SYSINC = user-atc_SYSLIB = -llinalg -lgfortran -user-atc_SYSPATH = -L../../lib/linalg +user-atc_SYSPATH = -L../../lib/linalg$(LIBOBJDIR) + diff --git a/lib/atc/Makefile.mingw32-cross b/lib/atc/Makefile.mingw32-cross new file mode 100644 index 0000000000000000000000000000000000000000..6834410408d429d9eef2bac47815f573551b1eb3 --- /dev/null +++ b/lib/atc/Makefile.mingw32-cross @@ -0,0 +1,149 @@ +# library build -*- makefile -*- +SHELL = /bin/sh + +# ------ FILES ------ + +SRC = ATC_HardyKernel.cpp \ +ATC_Transfer.cpp \ +ATC_TransferHardy.cpp \ +ATC_TransferThermal.cpp \ +ATC_TransferUtility.cpp \ +AtomicRegulator.cpp \ +ElasticTimeIntegrator.cpp \ +ElectronFlux.cpp \ +ElectronHeatCapacity.cpp \ +ElectronHeatFlux.cpp \ +ElectronPhononExchange.cpp \ +ExtrinsicModel.cpp \ +ExtrinsicModelTwoTemperature.cpp \ +FE_Element.cpp \ +FE_Engine.cpp \ +FE_Mesh.cpp \ +FieldEulerIntegrator.cpp \ +ImplicitSolveOperator.cpp \ +Kinetostat.cpp \ +LammpsInterface.cpp \ +Material.cpp \ +Matrix.cpp \ +OutputManager.cpp \ +PhysicsModelThermal.cpp \ +PhysicsModelTwoTemperature.cpp \ +PrescribedDataManager.cpp \ +Solver.cpp \ +Thermostat.cpp \ +TimeFilter.cpp \ +TimeIntegrator.cpp \ +Vector.cpp \ +XT_Function.cpp + +INC = Array2D.h \ +Array.h \ +ATC_Error.h \ +ATC_HardyKernel.h \ +ATC_Transfer.h \ +ATC_TransferHardy.h \ +ATC_TransferThermal.h \ +ATC_TypeDefs.h \ \ +AtomicRegulator.h \ +CG.h \ +CloneVector.h \ +DenseMatrix.h \ +DenseVector.h \ +DiagonalMatrix.h \ +ElasticTimeIntegrator.h \ +ElectronFlux.h \ +ElectronHeatCapacity.h \ +ElectronHeatFlux.h \ +ElectronPhononExchange.h \ +ExtrinsicModel.h \ +ExtrinsicModelTwoTemperature.h \ +FE_Element.h \ +FE_Engine.h \ +FE_Mesh.h \ +FieldEulerIntegrator.h \ +GMRES.h \ +ImplicitSolveOperator.h \ +Kinetostat.h \ +LammpsInterface.h \ +Material.h \ +MatrixDef.h \ +Matrix.h \ +MatrixLibrary.h \ +OutputManager.h \ +PhysicsModel.h \ +PhysicsModelThermal.h \ +PhysicsModelTwoTemperature.h \ +PrescribedDataManager.h \ +Quadrature.h \ +Solver.h \ +SparseMatrix.h \ +SparseMatrix-inl.h \ +SparseVector.h \ +SparseVector-inl.h \ +StringManip.h \ +Thermostat.h \ +TimeFilter.h \ +TimeIntegrator.h \ +Utility.h \ +Vector.h \ +XT_Function.h + +# ------ DEFINITIONS ------ +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.linalg + +DIR = Obj_mingw32/ +LIB = $(DIR)libatc.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +# include any MPI settings needed for the ATC library to build with +# the same MPI library that LAMMPS is built with + +CC = i686-w64-mingw32-g++ +CCFLAGS = -I../../src -I../../src/STUBS -DMPICH_IGNORE_CXX_SEEK \ + -O3 -march=i686 -mtune=generic -mfpmath=387 -mpc64 \ + -ffast-math -funroll-loops -fstrict-aliasing \ + -DLAMMPS_SMALLSMALL -Wno-uninitialized +ARCHIVE = i686-w64-mingw32-ar +ARCHFLAG = -rcs +DEPFLAGS = -M +LINK = i686-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) Makefile.lammps + +$(DIR): + mkdir $(DIR) + +Makefile.lammps: + @cp $(EXTRAMAKE) Makefile.lammps + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + rm $(DIR)*.o $(DIR)*.d *~ $(LIB) + +$(DEPENDS) : $(DIR) +sinclude $(DEPENDS) diff --git a/lib/atc/Makefile.mingw32-cross-mpi b/lib/atc/Makefile.mingw32-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..4c372edf380fe994cdf2cdfde3052098b1057168 --- /dev/null +++ b/lib/atc/Makefile.mingw32-cross-mpi @@ -0,0 +1,150 @@ +# library build -*- makefile -*- +SHELL = /bin/sh + +# ------ FILES ------ + +SRC = ATC_HardyKernel.cpp \ +ATC_Transfer.cpp \ +ATC_TransferHardy.cpp \ +ATC_TransferThermal.cpp \ +ATC_TransferUtility.cpp \ +AtomicRegulator.cpp \ +ElasticTimeIntegrator.cpp \ +ElectronFlux.cpp \ +ElectronHeatCapacity.cpp \ +ElectronHeatFlux.cpp \ +ElectronPhononExchange.cpp \ +ExtrinsicModel.cpp \ +ExtrinsicModelTwoTemperature.cpp \ +FE_Element.cpp \ +FE_Engine.cpp \ +FE_Mesh.cpp \ +FieldEulerIntegrator.cpp \ +ImplicitSolveOperator.cpp \ +Kinetostat.cpp \ +LammpsInterface.cpp \ +Material.cpp \ +Matrix.cpp \ +OutputManager.cpp \ +PhysicsModelThermal.cpp \ +PhysicsModelTwoTemperature.cpp \ +PrescribedDataManager.cpp \ +Solver.cpp \ +Thermostat.cpp \ +TimeFilter.cpp \ +TimeIntegrator.cpp \ +Vector.cpp \ +XT_Function.cpp + +INC = Array2D.h \ +Array.h \ +ATC_Error.h \ +ATC_HardyKernel.h \ +ATC_Transfer.h \ +ATC_TransferHardy.h \ +ATC_TransferThermal.h \ +ATC_TypeDefs.h \ \ +AtomicRegulator.h \ +CG.h \ +CloneVector.h \ +DenseMatrix.h \ +DenseVector.h \ +DiagonalMatrix.h \ +ElasticTimeIntegrator.h \ +ElectronFlux.h \ +ElectronHeatCapacity.h \ +ElectronHeatFlux.h \ +ElectronPhononExchange.h \ +ExtrinsicModel.h \ +ExtrinsicModelTwoTemperature.h \ +FE_Element.h \ +FE_Engine.h \ +FE_Mesh.h \ +FieldEulerIntegrator.h \ +GMRES.h \ +ImplicitSolveOperator.h \ +Kinetostat.h \ +LammpsInterface.h \ +Material.h \ +MatrixDef.h \ +Matrix.h \ +MatrixLibrary.h \ +OutputManager.h \ +PhysicsModel.h \ +PhysicsModelThermal.h \ +PhysicsModelTwoTemperature.h \ +PrescribedDataManager.h \ +Quadrature.h \ +Solver.h \ +SparseMatrix.h \ +SparseMatrix-inl.h \ +SparseVector.h \ +SparseVector-inl.h \ +StringManip.h \ +Thermostat.h \ +TimeFilter.h \ +TimeIntegrator.h \ +Utility.h \ +Vector.h \ +XT_Function.h + +# ------ DEFINITIONS ------ +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.linalg + +DIR = Obj_mingw32-mpi/ +LIB = $(DIR)libatc.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +# include any MPI settings needed for the ATC library to build with +# the same MPI library that LAMMPS is built with + +CC = i686-w64-mingw32-g++ +CCFLAGS = -I../../tools/mingw-cross/mpich2-win32/include/ \ + -I../../src -I../../src/STUBS -DMPICH_IGNORE_CXX_SEEK \ + -O3 -march=i686 -mtune=generic -mfpmath=387 -mpc64 \ + -ffast-math -funroll-loops -fstrict-aliasing \ + -DLAMMPS_SMALLSMALL -Wno-uninitialized +ARCHIVE = i686-w64-mingw32-ar +ARCHFLAG = -rcs +DEPFLAGS = -M +LINK = i686-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) Makefile.lammps + +$(DIR): + mkdir $(DIR) + +Makefile.lammps: + @cp $(EXTRAMAKE) Makefile.lammps + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + rm $(DIR)*.o $(DIR)*.d *~ $(LIB) + +$(DEPENDS) : $(DIR) +sinclude $(DEPENDS) diff --git a/lib/atc/Makefile.mingw64-cross b/lib/atc/Makefile.mingw64-cross new file mode 100644 index 0000000000000000000000000000000000000000..997cbcd35cb0481152f6dca4fd55369c5b237ec0 --- /dev/null +++ b/lib/atc/Makefile.mingw64-cross @@ -0,0 +1,149 @@ +# library build -*- makefile -*- +SHELL = /bin/sh + +# ------ FILES ------ + +SRC = ATC_HardyKernel.cpp \ +ATC_Transfer.cpp \ +ATC_TransferHardy.cpp \ +ATC_TransferThermal.cpp \ +ATC_TransferUtility.cpp \ +AtomicRegulator.cpp \ +ElasticTimeIntegrator.cpp \ +ElectronFlux.cpp \ +ElectronHeatCapacity.cpp \ +ElectronHeatFlux.cpp \ +ElectronPhononExchange.cpp \ +ExtrinsicModel.cpp \ +ExtrinsicModelTwoTemperature.cpp \ +FE_Element.cpp \ +FE_Engine.cpp \ +FE_Mesh.cpp \ +FieldEulerIntegrator.cpp \ +ImplicitSolveOperator.cpp \ +Kinetostat.cpp \ +LammpsInterface.cpp \ +Material.cpp \ +Matrix.cpp \ +OutputManager.cpp \ +PhysicsModelThermal.cpp \ +PhysicsModelTwoTemperature.cpp \ +PrescribedDataManager.cpp \ +Solver.cpp \ +Thermostat.cpp \ +TimeFilter.cpp \ +TimeIntegrator.cpp \ +Vector.cpp \ +XT_Function.cpp + +INC = Array2D.h \ +Array.h \ +ATC_Error.h \ +ATC_HardyKernel.h \ +ATC_Transfer.h \ +ATC_TransferHardy.h \ +ATC_TransferThermal.h \ +ATC_TypeDefs.h \ \ +AtomicRegulator.h \ +CG.h \ +CloneVector.h \ +DenseMatrix.h \ +DenseVector.h \ +DiagonalMatrix.h \ +ElasticTimeIntegrator.h \ +ElectronFlux.h \ +ElectronHeatCapacity.h \ +ElectronHeatFlux.h \ +ElectronPhononExchange.h \ +ExtrinsicModel.h \ +ExtrinsicModelTwoTemperature.h \ +FE_Element.h \ +FE_Engine.h \ +FE_Mesh.h \ +FieldEulerIntegrator.h \ +GMRES.h \ +ImplicitSolveOperator.h \ +Kinetostat.h \ +LammpsInterface.h \ +Material.h \ +MatrixDef.h \ +Matrix.h \ +MatrixLibrary.h \ +OutputManager.h \ +PhysicsModel.h \ +PhysicsModelThermal.h \ +PhysicsModelTwoTemperature.h \ +PrescribedDataManager.h \ +Quadrature.h \ +Solver.h \ +SparseMatrix.h \ +SparseMatrix-inl.h \ +SparseVector.h \ +SparseVector-inl.h \ +StringManip.h \ +Thermostat.h \ +TimeFilter.h \ +TimeIntegrator.h \ +Utility.h \ +Vector.h \ +XT_Function.h + +# ------ DEFINITIONS ------ +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.linalg + +DIR = Obj_mingw64/ +LIB = $(DIR)libatc.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +# include any MPI settings needed for the ATC library to build with +# the same MPI library that LAMMPS is built with + +CC = x86_64-w64-mingw32-g++ +CCFLAGS = -I../../src -I../../src/STUBS -DMPICH_IGNORE_CXX_SEEK \ + -O3 -march=core2 -mtune=core2 -mpc64 -msse2 \ + -ffast-math -funroll-loops -fstrict-aliasing \ + -DLAMMPS_SMALLBIG -Wno-uninitialized +ARCHIVE = x86_64-w64-mingw32-ar +ARCHFLAG = -rcs +DEPFLAGS = -M +LINK = x86_64-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) Makefile.lammps + +$(DIR): + mkdir $(DIR) + +Makefile.lammps: + @cp $(EXTRAMAKE) Makefile.lammps + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + rm $(DIR)*.o $(DIR)*.d *~ $(LIB) + +$(DEPENDS) : $(DIR) +sinclude $(DEPENDS) diff --git a/lib/atc/Makefile.mingw64-cross-mpi b/lib/atc/Makefile.mingw64-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..81b4ee207e1e4299e81d685e48e9d33863fac90e --- /dev/null +++ b/lib/atc/Makefile.mingw64-cross-mpi @@ -0,0 +1,150 @@ +# library build -*- makefile -*- +SHELL = /bin/sh + +# ------ FILES ------ + +SRC = ATC_HardyKernel.cpp \ +ATC_Transfer.cpp \ +ATC_TransferHardy.cpp \ +ATC_TransferThermal.cpp \ +ATC_TransferUtility.cpp \ +AtomicRegulator.cpp \ +ElasticTimeIntegrator.cpp \ +ElectronFlux.cpp \ +ElectronHeatCapacity.cpp \ +ElectronHeatFlux.cpp \ +ElectronPhononExchange.cpp \ +ExtrinsicModel.cpp \ +ExtrinsicModelTwoTemperature.cpp \ +FE_Element.cpp \ +FE_Engine.cpp \ +FE_Mesh.cpp \ +FieldEulerIntegrator.cpp \ +ImplicitSolveOperator.cpp \ +Kinetostat.cpp \ +LammpsInterface.cpp \ +Material.cpp \ +Matrix.cpp \ +OutputManager.cpp \ +PhysicsModelThermal.cpp \ +PhysicsModelTwoTemperature.cpp \ +PrescribedDataManager.cpp \ +Solver.cpp \ +Thermostat.cpp \ +TimeFilter.cpp \ +TimeIntegrator.cpp \ +Vector.cpp \ +XT_Function.cpp + +INC = Array2D.h \ +Array.h \ +ATC_Error.h \ +ATC_HardyKernel.h \ +ATC_Transfer.h \ +ATC_TransferHardy.h \ +ATC_TransferThermal.h \ +ATC_TypeDefs.h \ \ +AtomicRegulator.h \ +CG.h \ +CloneVector.h \ +DenseMatrix.h \ +DenseVector.h \ +DiagonalMatrix.h \ +ElasticTimeIntegrator.h \ +ElectronFlux.h \ +ElectronHeatCapacity.h \ +ElectronHeatFlux.h \ +ElectronPhononExchange.h \ +ExtrinsicModel.h \ +ExtrinsicModelTwoTemperature.h \ +FE_Element.h \ +FE_Engine.h \ +FE_Mesh.h \ +FieldEulerIntegrator.h \ +GMRES.h \ +ImplicitSolveOperator.h \ +Kinetostat.h \ +LammpsInterface.h \ +Material.h \ +MatrixDef.h \ +Matrix.h \ +MatrixLibrary.h \ +OutputManager.h \ +PhysicsModel.h \ +PhysicsModelThermal.h \ +PhysicsModelTwoTemperature.h \ +PrescribedDataManager.h \ +Quadrature.h \ +Solver.h \ +SparseMatrix.h \ +SparseMatrix-inl.h \ +SparseVector.h \ +SparseVector-inl.h \ +StringManip.h \ +Thermostat.h \ +TimeFilter.h \ +TimeIntegrator.h \ +Utility.h \ +Vector.h \ +XT_Function.h + +# ------ DEFINITIONS ------ +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.linalg + +DIR = Obj_mingw64-mpi/ +LIB = $(DIR)libatc.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +# include any MPI settings needed for the ATC library to build with +# the same MPI library that LAMMPS is built with + +CC = x86_64-w64-mingw32-g++ +CCFLAGS = -I../../tools/mingw-cross/mpich2-win64/include/ \ + -I../../src -I../../src/STUBS -DMPICH_IGNORE_CXX_SEEK \ + -O3 -march=core2 -mtune=core2 -mpc64 -msse2 \ + -ffast-math -funroll-loops -fstrict-aliasing \ + -DLAMMPS_SMALLBIG -Wno-uninitialized +ARCHIVE = x86_64-w64-mingw32-ar +ARCHFLAG = -rcs +DEPFLAGS = -M +LINK = x86_64-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) Makefile.lammps + +$(DIR): + mkdir $(DIR) + +Makefile.lammps: + @cp $(EXTRAMAKE) Makefile.lammps + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + rm $(DIR)*.o $(DIR)*.d *~ $(LIB) + +$(DEPENDS) : $(DIR) +sinclude $(DEPENDS) diff --git a/lib/awpmd/Makefile.lammps.linalg b/lib/awpmd/Makefile.lammps.linalg index a5c4e9b9f0f855ea4afa87961839c085a4ac614c..a30f4a821d21a632a80617adcbcd58cb2bf99968 100644 --- a/lib/awpmd/Makefile.lammps.linalg +++ b/lib/awpmd/Makefile.lammps.linalg @@ -2,4 +2,4 @@ user-awpmd_SYSINC = user-awpmd_SYSLIB = -llinalg -lgfortran -user-awpmd_SYSPATH = -L../../lib/linalg +user-awpmd_SYSPATH = -L../../lib/linalg$(LIBOBJDIR) diff --git a/lib/awpmd/Makefile.mingw32-cross b/lib/awpmd/Makefile.mingw32-cross new file mode 100644 index 0000000000000000000000000000000000000000..af66187b89762ef3cc8677fbfc4fec25de4fadd5 --- /dev/null +++ b/lib/awpmd/Makefile.mingw32-cross @@ -0,0 +1,80 @@ +# library build -*- makefile -*- +SHELL = /bin/sh + +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.linalg + +# ------ FILES ------ + +SRC = logexc.cpp wpmd.cpp wpmd_split.cpp +vpath %.cpp ivutils/src +vpath %.cpp systems/interact/TCP + +INC = \ + cerf.h \ + cerf2.h \ + cerf_octave.h \ + cvector_3.h \ + lapack_inter.h \ + logexc.h \ + pairhash.h \ + refobj.h \ + tcpdefs.h \ + vector_3.h \ + wavepacket.h \ + wpmd.h \ + wpmd_split.h + +# ------ DEFINITIONS ------ +DIR = Obj_mingw32/ +LIB = $(DIR)libawpmd.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +# include any MPI settings needed for the ATC library to build with +# the same MPI library that LAMMPS is built with + +CC = i686-w64-mingw32-g++ +CCFLAGS = -O2 -march=i686 -mtune=generic -mfpmath=387 -mpc64 \ + -finline-functions \ + -ffast-math -funroll-loops -fstrict-aliasing \ + -Wall -W -Wno-uninitialized -Isystems/interact/TCP/ -Isystems/interact -Iivutils/include +ARCHIVE = i686-w64-mingw32-ar +ARCHFLAG = -rscv +DEPFLAGS = -M +#LINK = +#LINKFLAGS = +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) Makefile.lammps + +$(DIR): + mkdir $(DIR) + +Makefile.lammps: + @cp $(EXTRAMAKE) Makefile.lammps + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + rm *.d *~ $(OBJ) $(LIB) diff --git a/lib/awpmd/Makefile.mingw32-cross-mpi b/lib/awpmd/Makefile.mingw32-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..cc2a76111a555bb51d002be8c286b1823f745284 --- /dev/null +++ b/lib/awpmd/Makefile.mingw32-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw32-cross + rm -f Obj_mingw32-mpi + ln -s Obj_mingw32 Obj_mingw32-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw32-cross + rm -f Obj_mingw32-mpi + diff --git a/lib/awpmd/Makefile.mingw64-cross b/lib/awpmd/Makefile.mingw64-cross new file mode 100644 index 0000000000000000000000000000000000000000..f1df999bab102a838c6523ca891e2c2ab1cc87b9 --- /dev/null +++ b/lib/awpmd/Makefile.mingw64-cross @@ -0,0 +1,79 @@ +# library build -*- makefile -*- +SHELL = /bin/sh + +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.linalg + +# ------ FILES ------ + +SRC = logexc.cpp wpmd.cpp wpmd_split.cpp +vpath %.cpp ivutils/src +vpath %.cpp systems/interact/TCP + +INC = \ + cerf.h \ + cerf2.h \ + cerf_octave.h \ + cvector_3.h \ + lapack_inter.h \ + logexc.h \ + pairhash.h \ + refobj.h \ + tcpdefs.h \ + vector_3.h \ + wavepacket.h \ + wpmd.h \ + wpmd_split.h + +# ------ DEFINITIONS ------ +DIR = Obj_mingw64/ +LIB = $(DIR)libawpmd.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +# include any MPI settings needed for the ATC library to build with +# the same MPI library that LAMMPS is built with + +CC = x86_64-w64-mingw32-g++ +CCFLAGS = -O3 -march=core2 -mtune=core2 -mpc64 -msse2 \ + -ffast-math -funroll-loops -fstrict-aliasing \ + -Wall -W -Wno-uninitialized -Isystems/interact/TCP/ -Isystems/interact -Iivutils/include +ARCHIVE = x86_64-w64-mingw32-ar +ARCHFLAG = -rscv +DEPFLAGS = -M +#LINK = +#LINKFLAGS = +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) Makefile.lammps + +$(DIR): + mkdir $(DIR) + +Makefile.lammps: + @cp $(EXTRAMAKE) Makefile.lammps + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + rm *.d *~ $(OBJ) $(LIB) diff --git a/lib/awpmd/Makefile.mingw64-cross-mpi b/lib/awpmd/Makefile.mingw64-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..1ec1a0995b1a8180c0ea3ba35cce6a66252495aa --- /dev/null +++ b/lib/awpmd/Makefile.mingw64-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw64-cross + rm -f Obj_mingw64-mpi + ln -s Obj_mingw64 Obj_mingw64-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw64-cross + rm -f Obj_mingw64-mpi + diff --git a/lib/awpmd/ivutils/include/lapack_inter.h b/lib/awpmd/ivutils/include/lapack_inter.h index 743c5e60594bbb4d74a4505c23c9e4d64d3dace7..e4497fc840a05a97cc028e86c7cffce4df0d8d03 100644 --- a/lib/awpmd/ivutils/include/lapack_inter.h +++ b/lib/awpmd/ivutils/include/lapack_inter.h @@ -8,7 +8,7 @@ typedef int lapack_int; typedef complex<float> lapack_complex_float; typedef complex<double> lapack_complex_double; -#ifdef _WIN32 +#if defined(_WIN32) && !defined(__MINGW32__) //#define MKL_Complex8 lapack_complex_float //#define MKL_Complex16 lapack_complex_double diff --git a/lib/awpmd/ivutils/include/logexc.h b/lib/awpmd/ivutils/include/logexc.h index e8b8ab3c58e50462ba57b7843e742c2233066443..68af8cd256d01c397d187d5e302624581955213f 100644 --- a/lib/awpmd/ivutils/include/logexc.h +++ b/lib/awpmd/ivutils/include/logexc.h @@ -7,9 +7,9 @@ #include <stdexcept> #include <string> -# ifndef _WIN32 +#if !defined(_WIN32) || defined(__MINGW32__) # include <typeinfo> -# endif +#endif /// this specifies whether to put file/line info in error messages diff --git a/lib/awpmd/ivutils/include/wavepacket.h b/lib/awpmd/ivutils/include/wavepacket.h index dc203f74bf517ef281fde76b771fdd3196bad4ee..e24ac4e23744b741cc82ae30b9320705c0fe7d0d 100644 --- a/lib/awpmd/ivutils/include/wavepacket.h +++ b/lib/awpmd/ivutils/include/wavepacket.h @@ -220,7 +220,8 @@ public: }; - /*double w=wk.get_width(); +#if 0 + double w=wk.get_width(); Vector_3 r=wk.get_r(); double t=3/(2*w*w*w); fe_w[ic1+k1]+= t*E_der[s1][indw1+8*k1]+imag(wk.a)*E_der[s1][indw1+8*k1+1]/w; @@ -230,7 +231,8 @@ public: fe_p[ic1+k1][i]+= (-E_der[s1][indw1+8*k1+2+2*i+1])*(m_electron/h_plank); //*(h_plank/m_electron); fe_pw[ic1+k1]+=(r[i]*E_der[s1][indw1+8*k1+2+2*i+1]/w)/h_plank; fe_w[ic1+k1]+=2*r[i]*(t*E_der[s1][indw1+8*k1+2+2*i]+imag(wk.a)*E_der[s1][indw1+8*k1+2+2*i+1]/w); - }*/ + } +#endif /// constructs a conjugate packet @@ -239,4 +241,4 @@ inline WavePacket conj(const WavePacket &wp){ } -# endif // WAVEPACKET_H \ No newline at end of file +# endif // WAVEPACKET_H diff --git a/lib/gpu/Makefile.lammps b/lib/gpu/Makefile.lammps new file mode 100644 index 0000000000000000000000000000000000000000..05651c5d76817843b30048d4c2171c45e8d13ad2 --- /dev/null +++ b/lib/gpu/Makefile.lammps @@ -0,0 +1,5 @@ +# Settings that the LAMMPS build will import when this package library is used + +gpu_SYSINC = +gpu_SYSLIB = -lcudart -lcuda +gpu_SYSPATH = -L/usr/local/cuda/lib64 diff --git a/lib/gpu/Makefile.lammps.mingw-cross b/lib/gpu/Makefile.lammps.mingw-cross new file mode 100644 index 0000000000000000000000000000000000000000..e92c3e9d0da918117bd7b44572cc8b9c7d54d162 --- /dev/null +++ b/lib/gpu/Makefile.lammps.mingw-cross @@ -0,0 +1,6 @@ +# Settings that the LAMMPS build will import when this package library is used +# settings for OpenCL builds +gpu_SYSINC = +gpu_SYSLIB = -Wl,--enable-stdcall-fixup -L../../tools/mingw-cross$(LIBOBJDIR) -lOpenCL +gpu_SYSPATH = + diff --git a/lib/gpu/Makefile.mingw32-cross b/lib/gpu/Makefile.mingw32-cross new file mode 100644 index 0000000000000000000000000000000000000000..3f1240af1ad4f841a1e84feb756546b1eae21d37 --- /dev/null +++ b/lib/gpu/Makefile.mingw32-cross @@ -0,0 +1,17 @@ +CUDA_HOME = ../../tools/mingw-cross/OpenCL + +OCL_CPP = i686-w64-mingw32-g++ -O2 -march=i686 -mtune=generic -mfpmath=387 \ + -mpc64 -DMPI_GERYON -DUCL_NO_EXIT -I../../src/STUBS \ + -I$(CUDA_HOME)/include +OCL_LINK = -Wl,--enable-stdcall-fixup -L$(CUDA_HOME)/../Obj_mingw32 -lOpenCL -L../../src/STUBS -lmpi_mingw32 +OCL_PREC = -D_SINGLE_DOUBLE +OCL_TUNE = -DFERMI_OCL +EXTRAMAKE = Makefile.lammps.mingw-cross + +BIN_DIR = Obj_mingw32 +OBJ_DIR = Obj_mingw32 +LIB_DIR = Obj_mingw32 +AR = i686-w64-mingw32-ar +BSH = /bin/sh + +include Opencl.makefile diff --git a/lib/gpu/Makefile.mingw32-cross-mpi b/lib/gpu/Makefile.mingw32-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..6dae2d06042e81ef478be60bd01f31fba32f4668 --- /dev/null +++ b/lib/gpu/Makefile.mingw32-cross-mpi @@ -0,0 +1,19 @@ +CUDA_HOME = ../../tools/mingw-cross/OpenCL + +OCL_CPP = i686-w64-mingw32-g++ -O2 -march=i686 -mtune=generic -mfpmath=387 \ + -mpc64 -DMPI_GERYON -DUCL_NO_EXIT -I$(CUDA_HOME)/include \ + -I../../tools/mingw-cross/mpich2-win32/include/ \ + -DMPICH_IGNORE_CXX_SEEK +OCL_LINK = -Wl,--enable-stdcall-fixup -L$(CUDA_HOME)/../Obj_mingw32 -lOpenCL \ + -L../../tools/mingw-cross/mpich2-win32/lib -lmpi +OCL_PREC = -D_SINGLE_DOUBLE +OCL_TUNE = -DFERMI_OCL +EXTRAMAKE = Makefile.lammps.mingw-cross + +BIN_DIR = Obj_mingw32-mpi +OBJ_DIR = Obj_mingw32-mpi +LIB_DIR = Obj_mingw32-mpi +AR = i686-w64-mingw32-ar +BSH = /bin/sh + +include Opencl.makefile diff --git a/lib/gpu/Makefile.mingw64-cross b/lib/gpu/Makefile.mingw64-cross new file mode 100644 index 0000000000000000000000000000000000000000..606b0309cb5483aa3c10ce3e33fc6b676d6c6ef4 --- /dev/null +++ b/lib/gpu/Makefile.mingw64-cross @@ -0,0 +1,18 @@ +CUDA_HOME = ../../tools/mingw-cross/OpenCL + +OCL_CPP = x86_64-w64-mingw32-g++ -O3 -march=core2 -mtune=core2 -mpc64 \ + -msse2 -DMPI_GERYON -DUCL_NO_EXIT -I../../src/STUBS \ + -I$(CUDA_HOME)/include +OCL_LINK = -Wl,--enable-stdcall-fixup -L$(CUDA_HOME)/../Obj_mingw64 -lOpenCL \ + -L../../src/STUBS -lmpi_mingw64 +OCL_PREC = -D_SINGLE_DOUBLE +OCL_TUNE = -DFERMI_OCL +EXTRAMAKE = Makefile.lammps.mingw-cross + +BIN_DIR = Obj_mingw64 +OBJ_DIR = Obj_mingw64 +LIB_DIR = Obj_mingw64 +AR = x86_64-w64-mingw32-ar +BSH = /bin/sh + +include Opencl.makefile diff --git a/lib/gpu/Makefile.mingw64-cross-mpi b/lib/gpu/Makefile.mingw64-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..cea8155efd38d0fca342ee6b3f56ee0bc54f11c9 --- /dev/null +++ b/lib/gpu/Makefile.mingw64-cross-mpi @@ -0,0 +1,20 @@ +CUDA_HOME = ../../tools/mingw-cross/OpenCL + +OCL_CPP = x86_64-w64-mingw32-g++ -O3 -march=core2 -mtune=core2 -mpc64 \ + -msse2 -DMPI_GERYON -DUCL_NO_EXIT -I$(CUDA_HOME)/include \ + -I../../tools/mingw-cross/mpich2-win64/include/ \ + -DMPICH_IGNORE_CXX_SEEK + +OCL_LINK = -Wl,--enable-stdcall-fixup -L$(CUDA_HOME)/../Obj_mingw64 -lOpenCL \ + -L../../tools/mingw-cross/mpich2-win64/lib -lmpi +OCL_PREC = -D_SINGLE_DOUBLE +OCL_TUNE = -DFERMI_OCL +EXTRAMAKE = Makefile.lammps.mingw-cross + +BIN_DIR = Obj_mingw64-mpi +OBJ_DIR = Obj_mingw64-mpi +LIB_DIR = Obj_mingw64-mpi +AR = x86_64-w64-mingw32-ar +BSH = /bin/sh + +include Opencl.makefile diff --git a/lib/gpu/Nvidia.makefile b/lib/gpu/Nvidia.makefile index 2a279ca0cf31df80132b34fe865c78d2b0bb37c1..ce6132dd5636b75d2fadf638aa39db7036854786 100644 --- a/lib/gpu/Nvidia.makefile +++ b/lib/gpu/Nvidia.makefile @@ -101,7 +101,10 @@ CBNS = $(OBJ_DIR)/device.cubin $(OBJ_DIR)/device_cubin.h \ $(OBJ_DIR)/lj_coul_debye.cubin $(OBJ_DIR)/lj_coul_debye_cubin.h \ $(OBJ_DIR)/coul_dsf.cubin $(OBJ_DIR)/coul_dsf_cubin.h -all: $(GPU_LIB) $(EXECS) +all: $(OBJ_DIR) $(GPU_LIB) $(EXECS) + +$(OBJ_DIR): + mkdir -p $@ $(OBJ_DIR)/cudpp.o: cudpp_mini/cudpp.cpp $(CUDR) -o $@ -c cudpp_mini/cudpp.cpp -Icudpp_mini diff --git a/lib/gpu/Opencl.makefile b/lib/gpu/Opencl.makefile index e66accfe706ff6c458f837fd2a13749f6f1cf455..b476003ecdc0e33a0d5cd8023fe35854ea8bf278 100644 --- a/lib/gpu/Opencl.makefile +++ b/lib/gpu/Opencl.makefile @@ -73,7 +73,10 @@ KERS = $(OBJ_DIR)/device_cl.h $(OBJ_DIR)/atom_cl.h \ OCL_EXECS = $(BIN_DIR)/ocl_get_devices -all: $(OCL_LIB) $(EXECS) +all: $(OBJ_DIR) $(OCL_LIB) $(EXECS) + +$(OBJ_DIR): + mkdir -p $@ $(OBJ_DIR)/atom_cl.h: lal_atom.cu lal_preprocessor.h $(BSH) ./geryon/file_to_cstr.sh atom lal_preprocessor.h lal_atom.cu $(OBJ_DIR)/atom_cl.h diff --git a/lib/linalg/Makefile.mingw32-cross b/lib/linalg/Makefile.mingw32-cross new file mode 100755 index 0000000000000000000000000000000000000000..3facd2b009687304dc61fe9519e315fddb92a264 --- /dev/null +++ b/lib/linalg/Makefile.mingw32-cross @@ -0,0 +1,85 @@ +# * +# *_________________________________________________________________________* +# * Minimal BLAS/LAPACK Library for ATC and AWPMD + +# To compile and link LAMMPS to the linalg library generated by this Makefile, +# adjust the corresponding definitions in the library's Makefile.lammps file. +# +# for lib/atc/Makefile.lammps use: +# user-atc_SYSINC = +# user-atc_SYSLIB = ../../lib/linalg/$(LIBOBJDIR)liblinalg.a -lgfortran +# user-atc_SYSPATH = +# +# for lib/awpmd/Makefile.lammps use: +# user-awpmd_SYSINC = +# user-awpmd_SYSLIB = ../../lib/linalg/$(LIBOBJDIR)liblinalg.a -lgfortran +# user-awpmd_SYSPATH = + +SHELL = /bin/sh + +# ------ FILES ------ + +SRC = dasum.f daxpy.f dcopy.f ddot.f dgecon.f dgemm.f dgemv.f dger.f \ + dgetf2.f dgetrf.f dgetri.f disnan.f dlabad.f dlaisnan.f dlamch.f\ + dlacn2.f dlange.f dlassq.f dlaswp.f dlatrs.f drscl.f dscal.f \ + dswap.f dtrmm.f dtrmv.f dtrsm.f dtrsv.f dtrti2.f dtrtri.f \ + idamax.f ieeeck.f ilaenv.f iparmq.f lsame.f xerbla.f zdotc.f \ + zdscal.f zhpr.f zpptrf.f zpptri.f zscal.f ztpmv.f ztpsv.f ztptri.f + +FILES = $(SRC) Makefile.* README + +# ------ DEFINITIONS ------ + +DIR = Obj_mingw32/ +LIB = $(DIR)liblinalg.a +OBJ = $(SRC:%.f=$(DIR)%.o) + +# ------ SETTINGS ------ + +FC = i686-w64-mingw32-gfortran +FFLAGS = -O3 -march=i686 -mtune=generic -mfpmath=387 -mpc64 \ + -ffast-math -funroll-loops -fstrict-aliasing -Wall -W \ + -Wno-uninitialized -fno-second-underscore +FFLAGS0 = -O0 -march=i686 -mtune=generic -mfpmath=387 -mpc64 \ + -Wall -W -Wno-uninitialized -fno-second-underscore +ARCHIVE = i686-w64-mingw32-ar +AR = i686-w64-mingw32-ar +ARCHFLAG = -rcs +USRLIB = +SYSLIB = + +.PHONY: default clean tar + +.SUFFIXES: +.SUFFIXES: .F .f .o + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + +$(DIR): + mkdir $(DIR) + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.F + $(F90) $(F90FLAGS) -c $< -o $@ + +$(DIR)%.o:%.f + $(FC) $(FFLAGS) -c $< -o $@ + +$(DIR)dlamch.o: dlamch.f + $(FC) $(FFLAGS0) -c $< -o $@ + +# ------ CLEAN ------ + +clean: + -rm $(DIR)*.o $(DIR)*.mod *~ $(LIB) + -rmdir $(DIR) + +tar: + -tar -czvf ../linalg.tar.gz $(FILES) + diff --git a/lib/linalg/Makefile.mingw32-cross-mpi b/lib/linalg/Makefile.mingw32-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..cc2a76111a555bb51d002be8c286b1823f745284 --- /dev/null +++ b/lib/linalg/Makefile.mingw32-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw32-cross + rm -f Obj_mingw32-mpi + ln -s Obj_mingw32 Obj_mingw32-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw32-cross + rm -f Obj_mingw32-mpi + diff --git a/lib/linalg/Makefile.mingw64-cross b/lib/linalg/Makefile.mingw64-cross new file mode 100755 index 0000000000000000000000000000000000000000..fa918a228753eb811c3c465234231630620d4153 --- /dev/null +++ b/lib/linalg/Makefile.mingw64-cross @@ -0,0 +1,85 @@ +# * +# *_________________________________________________________________________* +# * Minimal BLAS/LAPACK Library for ATC and AWPMD + +# To compile and link LAMMPS to the linalg library generated by this Makefile, +# adjust the corresponding definitions in the library's Makefile.lammps file. +# +# for lib/atc/Makefile.lammps use: +# user-atc_SYSINC = +# user-atc_SYSLIB = ../../lib/linalg/$(LIBOBJDIR)liblinalg.a -lgfortran +# user-atc_SYSPATH = +# +# for lib/awpmd/Makefile.lammps use: +# user-awpmd_SYSINC = +# user-awpmd_SYSLIB = ../../lib/linalg/$(LIBOBJDIR)liblinalg.a -lgfortran +# user-awpmd_SYSPATH = + +SHELL = /bin/sh + +# ------ FILES ------ + +SRC = dasum.f daxpy.f dcopy.f ddot.f dgecon.f dgemm.f dgemv.f dger.f \ + dgetf2.f dgetrf.f dgetri.f disnan.f dlabad.f dlaisnan.f dlamch.f\ + dlacn2.f dlange.f dlassq.f dlaswp.f dlatrs.f drscl.f dscal.f \ + dswap.f dtrmm.f dtrmv.f dtrsm.f dtrsv.f dtrti2.f dtrtri.f \ + idamax.f ieeeck.f ilaenv.f iparmq.f lsame.f xerbla.f zdotc.f \ + zdscal.f zhpr.f zpptrf.f zpptri.f zscal.f ztpmv.f ztpsv.f ztptri.f + +FILES = $(SRC) Makefile.* README + +# ------ DEFINITIONS ------ + +DIR = Obj_mingw64/ +LIB = $(DIR)liblinalg.a +OBJ = $(SRC:%.f=$(DIR)%.o) + +# ------ SETTINGS ------ + +FC = x86_64-w64-mingw32-gfortran +FFLAGS = -O3 -march=core2 -mtune=generic -msse2 -mpc64 \ + -ffast-math -funroll-loops -fstrict-aliasing -Wall -W \ + -Wno-uninitialized -fno-second-underscore +FFLAGS0 = -O0 -march=core2 -mtune=generic -msse2 -mpc64 \ + -Wall -W -Wno-uninitialized -fno-second-underscore +ARCHIVE = x86_64-w64-mingw32-ar +AR = x86_64-w64-mingw32-ar +ARCHFLAG = -rcs +USRLIB = +SYSLIB = + +.PHONY: default clean tar + +.SUFFIXES: +.SUFFIXES: .F .f .o + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + +$(DIR): + mkdir $(DIR) + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.F + $(F90) $(F90FLAGS) -c $< -o $@ + +$(DIR)%.o:%.f + $(FC) $(FFLAGS) -c $< -o $@ + +$(DIR)dlamch.o: dlamch.f + $(FC) $(FFLAGS0) -c $< -o $@ + +# ------ CLEAN ------ + +clean: + -rm $(DIR)*.o $(DOR)*.mod *~ $(LIB) + -rmdir $(DIR) + +tar: + -tar -czvf ../linalg.tar.gz $(FILES) + diff --git a/lib/linalg/Makefile.mingw64-cross-mpi b/lib/linalg/Makefile.mingw64-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..1ec1a0995b1a8180c0ea3ba35cce6a66252495aa --- /dev/null +++ b/lib/linalg/Makefile.mingw64-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw64-cross + rm -f Obj_mingw64-mpi + ln -s Obj_mingw64 Obj_mingw64-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw64-cross + rm -f Obj_mingw64-mpi + diff --git a/lib/meam/Makefile.mingw32-cross b/lib/meam/Makefile.mingw32-cross new file mode 100644 index 0000000000000000000000000000000000000000..ee6516d2002e6687e730a5146efe23b989452131 --- /dev/null +++ b/lib/meam/Makefile.mingw32-cross @@ -0,0 +1,65 @@ +# * -*- makefile -*- +# *_________________________________________________________________________* +# * MEAM: MODEFIED EMBEDDED ATOM METHOD * +# * DESCRIPTION: SEE READ-ME * +# * FILE NAME: Makefile * +# * AUTHORS: Greg Wagner, Sandia National Laboratories * +# * CONTACT: gjwagne@sandia.gov * +# *_________________________________________________________________________*/ + +SHELL = /bin/sh + +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.gfortran + +# ------ FILES ------ + +SRC = meam_data.F meam_setup_done.F meam_setup_global.F meam_setup_param.F meam_dens_init.F meam_dens_final.F meam_force.F meam_cleanup.F + +FILES = $(SRC) Makefile + +# ------ DEFINITIONS ------ + +DIR = Obj_mingw32/ +LIB = $(DIR)libmeam.a +OBJ = $(SRC:%.F=$(DIR)%.o) + +# ------ SETTINGS ------ + +F90 = i686-w64-mingw32-gfortran +F90FLAGS = -O3 -march=i686 -mtune=generic -mfpmath=387 -mpc64 \ + -ffast-math -funroll-loops -fstrict-aliasing -J$(DIR) \ + -Wall -W -Wno-uninitialized -fno-second-underscore +#F90FLAGS = -O +ARCHIVE = i686-w64-mingw32-ar +ARCHFLAG = -rcs +LINK = i686-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) + +$(DIR): + -mkdir $(DIR) + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.F + $(F90) $(F90FLAGS) -c $< -o $@ + +# ------ CLEAN ------ + +clean: + -rm $(DIR)*.o $(DIR)*.mod *~ $(LIB) + -rmdir $(DIR) + +tar: + -tar -cvf ../MEAM.tar $(FILES) diff --git a/lib/meam/Makefile.mingw32-cross-mpi b/lib/meam/Makefile.mingw32-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..cc2a76111a555bb51d002be8c286b1823f745284 --- /dev/null +++ b/lib/meam/Makefile.mingw32-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw32-cross + rm -f Obj_mingw32-mpi + ln -s Obj_mingw32 Obj_mingw32-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw32-cross + rm -f Obj_mingw32-mpi + diff --git a/lib/meam/Makefile.mingw64-cross b/lib/meam/Makefile.mingw64-cross new file mode 100644 index 0000000000000000000000000000000000000000..4cfccc80c9281c285279d86d1fe7283548d3e511 --- /dev/null +++ b/lib/meam/Makefile.mingw64-cross @@ -0,0 +1,65 @@ +# * -*- makefile -*- +# *_________________________________________________________________________* +# * MEAM: MODEFIED EMBEDDED ATOM METHOD * +# * DESCRIPTION: SEE READ-ME * +# * FILE NAME: Makefile * +# * AUTHORS: Greg Wagner, Sandia National Laboratories * +# * CONTACT: gjwagne@sandia.gov * +# *_________________________________________________________________________*/ + +SHELL = /bin/sh + +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.gfortran + +# ------ FILES ------ + +SRC = meam_data.F meam_setup_done.F meam_setup_global.F meam_setup_param.F meam_dens_init.F meam_dens_final.F meam_force.F meam_cleanup.F + +FILES = $(SRC) Makefile + +# ------ DEFINITIONS ------ + +DIR = Obj_mingw64/ +LIB = $(DIR)libmeam.a +OBJ = $(SRC:%.F=$(DIR)%.o) + +# ------ SETTINGS ------ + +F90 = x86_64-w64-mingw32-gfortran +F90FLAGS = -O3 -march=core2 -mtune=core2 -msse2 -mpc64 \ + -ffast-math -funroll-loops -fstrict-aliasing -J$(DIR) \ + -Wall -W -Wno-uninitialized -fno-second-underscore +#F90FLAGS = -O +ARCHIVE = x86_64-w64-mingw32-ar +ARCHFLAG = -rcs +LINK = x86_64-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) + +$(DIR): + -mkdir $(DIR) + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.F + $(F90) $(F90FLAGS) -c $< -o $@ + +# ------ CLEAN ------ + +clean: + -rm $(DIR)*.o $(DIR)*.mod *~ $(LIB) + -rmdir $(DIR) + +tar: + -tar -cvf ../MEAM.tar $(FILES) diff --git a/lib/meam/Makefile.mingw64-cross-mpi b/lib/meam/Makefile.mingw64-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..1ec1a0995b1a8180c0ea3ba35cce6a66252495aa --- /dev/null +++ b/lib/meam/Makefile.mingw64-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw64-cross + rm -f Obj_mingw64-mpi + ln -s Obj_mingw64 Obj_mingw64-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw64-cross + rm -f Obj_mingw64-mpi + diff --git a/lib/poems/Makefile.mingw32-cross b/lib/poems/Makefile.mingw32-cross new file mode 100644 index 0000000000000000000000000000000000000000..3a32f059552b6a809bedff2590ebd1c4eb3b1dba --- /dev/null +++ b/lib/poems/Makefile.mingw32-cross @@ -0,0 +1,113 @@ +# * +# *_________________________________________________________________________* +# * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * +# * DESCRIPTION: SEE READ-ME * +# * FILE NAME: Makefile * +# * AUTHORS: See Author List * +# * GRANTS: See Grants List * +# * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * +# * LICENSE: Please see License Agreement * +# * DOWNLOAD: Free at www.rpi.edu/~anderk5 * +# * ADMINISTRATOR: Prof. Kurt Anderson * +# * Computational Dynamics Lab * +# * Rensselaer Polytechnic Institute * +# * 110 8th St. Troy NY 12180 * +# * CONTACT: anderk5@rpi.edu * +# *_________________________________________________________________________*/ + +SHELL = /bin/sh + +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.empty + +# ------ FILES ------ + +SRC_MAIN = workspace.cpp system.cpp poemsobject.cpp +INC_MAIN = workspace.h system.h poemsobject.h + +SRC_BODY = body.cpp rigidbody.cpp particle.cpp inertialframe.cpp +INC_BODY = bodies.h body.h rigidbody.h particle.h inertialframe.h + + +SRC_JOINT = joint.cpp revolutejoint.cpp prismaticjoint.cpp sphericaljoint.cpp \ + freebodyjoint.cpp body23joint.cpp mixedjoint.cpp +INC_JOINT = joints.h joint.h revolutejoint.h prismaticjoint.h sphericaljoint.h \ + freebodyjoint.h body23joint.h mixedjoint.h + +SRC_POINT = point.cpp fixedpoint.cpp +INC_POINT = points.h point.h fixedpoint.h + +SRC_SOLVE = solver.cpp +INC_SOLVE = solver.h + +SRC_ORDERN = onsolver.cpp onfunctions.cpp onbody.cpp +INC_ORDERN = onsolver.h onfunctions.h onbody.h + +SRC_MAT = virtualmatrix.cpp matrix.cpp matrixfun.cpp mat3x3.cpp virtualcolmatrix.cpp \ + colmatrix.cpp vect3.cpp virtualrowmatrix.cpp rowmatrix.cpp mat6x6.cpp vect6.cpp \ + fastmatrixops.cpp colmatmap.cpp eulerparameters.cpp vect4.cpp norm.cpp mat4x4.cpp \ + +INC_MAT = matrices.h virtualmatrix.h matrix.h matrixfun.h mat3x3.h virtualcolmatrix.h \ + colmatrix.h vect3.h virtualrowmatrix.h rowmatrix.h mat6x6.h vect6.h \ + fastmatrixops.h colmatmap.h eulerparameters.h vect4.h norm.h mat4x4.h + +SRC_MISC = poemstreenode.cpp +INC_MISC = poemslist.h poemstreenode.h poemstree.h poemsnodelib.h SystemProcessor.h defines.h POEMSChain.h + +SRC = $(SRC_MAIN) $(SRC_BODY) $(SRC_JOINT) $(SRC_POINT) $(SRC_SOLVE) $(SRC_ORDERN) $(SRC_MAT) $(SRC_MISC) +INC = $(INC_MAIN) $(INC_BODY) $(INC_JOINT) $(INC_POINT) $(INC_SOLVE) $(INC_ORDERN) $(INC_MAT) $(INC_MISC) + +FILES = $(SRC) $(INC) Makefile Authors_List.txt Grants_List.txt POEMS_License.txt README Copyright_Notice + +# ------ DEFINITIONS ------ + +DIR = Obj_mingw32/ +LIB = $(DIR)libpoems.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +CC = i686-w64-mingw32-g++ +CCFLAGS = -O2 -march=i686 -mtune=generic -mfpmath=387 -mpc64 \ + -ffast-math -funroll-loops -finline-functions -fno-rtti \ + -fno-exceptions -fstrict-aliasing \ + -Wall -W -Wno-uninitialized +ARCHIVE = i686-w64-mingw32-ar +ARCHFLAG = -rcs +DEPFLAGS = -M +LINK = i686-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) + +$(DIR): + -mkdir $(DIR) + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ + +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + -rm $(DIR)*.o $(DIR)*.d *~ $(LIB) + +tar: + -tar -cvf ../POEMS.tar $(FILES) diff --git a/lib/poems/Makefile.mingw32-cross-mpi b/lib/poems/Makefile.mingw32-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..cc2a76111a555bb51d002be8c286b1823f745284 --- /dev/null +++ b/lib/poems/Makefile.mingw32-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw32-cross + rm -f Obj_mingw32-mpi + ln -s Obj_mingw32 Obj_mingw32-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw32-cross + rm -f Obj_mingw32-mpi + diff --git a/lib/poems/Makefile.mingw64-cross b/lib/poems/Makefile.mingw64-cross new file mode 100644 index 0000000000000000000000000000000000000000..4fcbe1d23ae5dece3fcb5411013d900f425db1ac --- /dev/null +++ b/lib/poems/Makefile.mingw64-cross @@ -0,0 +1,113 @@ +# * +# *_________________________________________________________________________* +# * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * +# * DESCRIPTION: SEE READ-ME * +# * FILE NAME: Makefile * +# * AUTHORS: See Author List * +# * GRANTS: See Grants List * +# * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * +# * LICENSE: Please see License Agreement * +# * DOWNLOAD: Free at www.rpi.edu/~anderk5 * +# * ADMINISTRATOR: Prof. Kurt Anderson * +# * Computational Dynamics Lab * +# * Rensselaer Polytechnic Institute * +# * 110 8th St. Troy NY 12180 * +# * CONTACT: anderk5@rpi.edu * +# *_________________________________________________________________________*/ + +SHELL = /bin/sh + +# which file will be copied to Makefile.lammps + +EXTRAMAKE = Makefile.lammps.empty + +# ------ FILES ------ + +SRC_MAIN = workspace.cpp system.cpp poemsobject.cpp +INC_MAIN = workspace.h system.h poemsobject.h + +SRC_BODY = body.cpp rigidbody.cpp particle.cpp inertialframe.cpp +INC_BODY = bodies.h body.h rigidbody.h particle.h inertialframe.h + + +SRC_JOINT = joint.cpp revolutejoint.cpp prismaticjoint.cpp sphericaljoint.cpp \ + freebodyjoint.cpp body23joint.cpp mixedjoint.cpp +INC_JOINT = joints.h joint.h revolutejoint.h prismaticjoint.h sphericaljoint.h \ + freebodyjoint.h body23joint.h mixedjoint.h + +SRC_POINT = point.cpp fixedpoint.cpp +INC_POINT = points.h point.h fixedpoint.h + +SRC_SOLVE = solver.cpp +INC_SOLVE = solver.h + +SRC_ORDERN = onsolver.cpp onfunctions.cpp onbody.cpp +INC_ORDERN = onsolver.h onfunctions.h onbody.h + +SRC_MAT = virtualmatrix.cpp matrix.cpp matrixfun.cpp mat3x3.cpp virtualcolmatrix.cpp \ + colmatrix.cpp vect3.cpp virtualrowmatrix.cpp rowmatrix.cpp mat6x6.cpp vect6.cpp \ + fastmatrixops.cpp colmatmap.cpp eulerparameters.cpp vect4.cpp norm.cpp mat4x4.cpp \ + +INC_MAT = matrices.h virtualmatrix.h matrix.h matrixfun.h mat3x3.h virtualcolmatrix.h \ + colmatrix.h vect3.h virtualrowmatrix.h rowmatrix.h mat6x6.h vect6.h \ + fastmatrixops.h colmatmap.h eulerparameters.h vect4.h norm.h mat4x4.h + +SRC_MISC = poemstreenode.cpp +INC_MISC = poemslist.h poemstreenode.h poemstree.h poemsnodelib.h SystemProcessor.h defines.h POEMSChain.h + +SRC = $(SRC_MAIN) $(SRC_BODY) $(SRC_JOINT) $(SRC_POINT) $(SRC_SOLVE) $(SRC_ORDERN) $(SRC_MAT) $(SRC_MISC) +INC = $(INC_MAIN) $(INC_BODY) $(INC_JOINT) $(INC_POINT) $(INC_SOLVE) $(INC_ORDERN) $(INC_MAT) $(INC_MISC) + +FILES = $(SRC) $(INC) Makefile Authors_List.txt Grants_List.txt POEMS_License.txt README Copyright_Notice + +# ------ DEFINITIONS ------ + +DIR = Obj_mingw64/ +LIB = $(DIR)libpoems.a +OBJ = $(SRC:%.cpp=$(DIR)%.o) + +# ------ SETTINGS ------ + +CC = x86_64-w64-mingw32-g++ +CCFLAGS = -O2 -march=core2 -mtune=core2 -msse2 -mpc64 \ + -ffast-math -funroll-loops -finline-functions -fno-rtti \ + -fno-exceptions -fstrict-aliasing \ + -Wall -W -Wno-uninitialized +ARCHIVE = x86_64-w64-mingw32-ar +ARCHFLAG = -rcs +DEPFLAGS = -M +LINK = x86_64-w64-mingw32-g++ +LINKFLAGS = -O +USRLIB = +SYSLIB = + +# ------ MAKE PROCEDURE ------ + +default: $(DIR) $(LIB) + +$(DIR): + -mkdir $(DIR) + +$(LIB): $(OBJ) + $(ARCHIVE) $(ARFLAGS) $(LIB) $(OBJ) + @cp $(EXTRAMAKE) Makefile.lammps + +# ------ COMPILE RULES ------ + +$(DIR)%.o:%.cpp + $(CC) $(CCFLAGS) -c $< -o $@ + +$(DIR)%.d:%.cpp + $(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@ + +# ------ DEPENDENCIES ------ + +DEPENDS = $(OBJ:.o=.d) + +# ------ CLEAN ------ + +clean: + -rm $(DIR)*.o $(DIR)*.d *~ $(LIB) + +tar: + -tar -cvf ../POEMS.tar $(FILES) diff --git a/lib/poems/Makefile.mingw64-cross-mpi b/lib/poems/Makefile.mingw64-cross-mpi new file mode 100644 index 0000000000000000000000000000000000000000..1ec1a0995b1a8180c0ea3ba35cce6a66252495aa --- /dev/null +++ b/lib/poems/Makefile.mingw64-cross-mpi @@ -0,0 +1,13 @@ +# -*- makefile -*- wrapper for non-MPI libraries + +SHELL=/bin/sh + +all: + $(MAKE) $(MFLAGS) mingw64-cross + rm -f Obj_mingw64-mpi + ln -s Obj_mingw64 Obj_mingw64-mpi + +clean: + $(MAKE) $(MFLAGS) clean-mingw64-cross + rm -f Obj_mingw64-mpi +