Skip to content

Commit

Permalink
Version 1.6.2
Browse files Browse the repository at this point in the history
Version 1.6.2 (April 20, 2017)
	* Added a simple makefile for library and no Gromacs (only GSL and
LAPACK dependencies)
	* Update "all" option for makefiles
	* Changes for GNU compiler compatability
	* Switch some linear algebra to CBLAS
  • Loading branch information
Jacob Wagner authored and Jacob Wagner committed Apr 20, 2017
1 parent b199cc3 commit 4934bbb
Show file tree
Hide file tree
Showing 15 changed files with 178 additions and 424 deletions.
4 changes: 4 additions & 0 deletions Install
Expand Up @@ -9,3 +9,7 @@ code was designed using is included in this distribution. The Gromacs features c
optionally excluded using the "no_gro" targets in the make file. Nonetheless, all
non-standard libraries available for download free of charge and are easy to find with an
internet search by name.

If you wish to use the library form and/or you do not need GROMACS support, consider
starting from the Makefile.g++_simple (for GNU compiliers and libraries) or
Makefile.intel_simple (for Intel compilers and libraries).
1 change: 1 addition & 0 deletions README_lammps.txt
Expand Up @@ -13,6 +13,7 @@ You must perform the following steps yourself.

2. compile MS-CG from within its home directory using your makefile choice
% make -f Makefile."name" lib_mscg.a
It is recommended that you start from Makefile.g++_simple or Makefile.intel_simple

3. There is no need to install MS-CG if you only wish
to use it from LAMMPS.
Expand Down
6 changes: 6 additions & 0 deletions ReleaseNotes.txt
@@ -1,6 +1,12 @@
Release Notes
=============

Version 1.6.2 (April 20, 2017)
* Added a simple makefile for library and no Gromacs (only GSL and LAPACK dependencies)
* Update "all" option for makefiles
* Changes for GNU compiler compatability
* Switch some linear algebra to CBLAS

Version 1.6.1 (April 9, 2017)
* Added version of Gromacs XTC files used when that part of the code was designed.
* Fixed typos in Manual.
Expand Down
104 changes: 104 additions & 0 deletions src/Make/Makefile.g++_simple
@@ -0,0 +1,104 @@
# This Makefile is meant for use after
# module load gsl/2.2.1+gcc-6.1
# module load gcc/6.1
# It also requires LAPACK
# Module names refer to those on any of RCC's clusters at UChicago.

# This makefile does NOT include GROMACS reading or MKL (sparse matrix)
# It uses the gcc/g++ compiler (v4.9+) for C++11 support

# 1) Try this first (as it is the easiest)
NO_GRO_LIBS = -lgsl -lgslcblas -llapack -lm

# 2) If it does not find your libraries automatically, you can specify them manually
# # A) Set the GSL_LIB to the location of your GSL library's lib directory (must be V2+)
GSL_LIB = /software/gsl-2.2.1-el6-x86_64+gcc-6.1/lib
# # B) Set the LAPACK_DIR to the location of your LAPACK library base directory
LAPACK_LIB = $(HOME)/local/lapack-3.7.0
# # C) Uncomment this next line and then run again (after cleaning up any object files)
#NO_GRO_LIBS = -L$(GSL_LIB) -L$(LAPACK_LIB) -lgsl -lgslcblas -llapack -lm

OPT = -O2 -std=c++11
NO_GRO_LDFLAGS = $(OPT)
NO_GRO_CFLAGS = $(OPT)
DIMENSION = 3
CC = g++

COMMON_SOURCE = control_input.h fm_output.h force_computation.h geometry.h interaction_hashing.h interaction_model.h matrix.h splines.h topology.h trajectory_input.h misc.h mscg.h
NO_GRO_COMMON_OBJECTS = control_input.o fm_output.o force_computation.o geometry.o interaction_hashing.o interaction_model.o matrix.o splines.o topology.o trajectory_input_no_gro.o misc.o

# Target executables
# The library for LAMMPS is lib_mscg.a
libmscg.a: mscg.o $(NO_GRO_COMMON_OBJECTS)
ar rvs libmscg.a *.o

newfm_no_gro.x: newfm.o $(NO_GRO_COMMON_OBJECTS)
$(CC) $(NO_GRO_LDFLAGS) -o $@ newfm.o $(NO_GRO_COMMON_OBJECTS) -D"_exclude_gromacs=1" $(NO_GRO_LIBS)

combinefm_no_gro.x: combinefm.o batch_fm_combination.o $(NO_GRO_COMMON_OBJECTS)
$(CC) $(NO_GRO_LDFLAGS) -o $@ combinefm.o batch_fm_combination.o $(NO_GRO_COMMON_OBJECTS) -D"_exclude_gromacs=1" $(NO_GRO_LIBS)

rangefinder_no_gro.x: rangefinder.o range_finding.o $(NO_GRO_COMMON_OBJECTS)
$(CC) $(NO_GRO_LDFLAGS) -o $@ rangefinder.o range_finding.o $(NO_GRO_COMMON_OBJECTS) -D"_exclude_gromacs=1" $(NO_GRO_LIBS)

# Target objects

mscg.o: mscg.cpp $(COMMON_SOURCE) range_finding.o
$(CC) $(NO_GRO_CFLAGS) -c mscg.cpp -o mscg.o $(NO_GRO_LIBS)

newfm.o: newfm.cpp $(COMMON_SOURCE)
$(CC) $(NO_GRO_CFLAGS) -c newfm.cpp

combinefm.o: combinefm.cpp batch_fm_combination.h $(COMMON_SOURCE)
$(CC) $(NO_GRO_CFLAGS) -c combinefm.cpp

rangefinder.o: rangefinder.cpp range_finding.h $(COMMON_SOURCE)
$(CC) $(NO_GRO_CFLAGS) -c rangefinder.cpp

scalarfm.o: scalarfm.cpp $(COMMON_SOURCE)
$(CC) $(NO_GRO_CFLAGS) -c scalarfm.cpp

batch_fm_combination.o: batch_fm_combination.cpp batch_fm_combination.h external_matrix_routines.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c batch_fm_combination.cpp

control_input.o: control_input.cpp control_input.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c control_input.cpp

geometry.o: geometry.h
$(CC) $(NO_GRO_CFLAGS) -c geometry.cpp -DDIMENSION=$(DIMENSION)

fm_output.o: fm_output.cpp fm_output.h force_computation.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c fm_output.cpp

force_computation.o: force_computation.cpp force_computation.h interaction_model.h matrix.h trajectory_input.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c force_computation.cpp -DDIMENSION=$(DIMENSION)

interaction_hashing.o: interaction_hashing.cpp interaction_hashing.h
$(CC) $(NO_GRO_CFLAGS) -c interaction_hashing.cpp

interaction_model.o: interaction_model.cpp interaction_model.h control_input.h interaction_hashing.h topology.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c interaction_model.cpp -DDIMENSION=$(DIMENSION)

matrix.o: matrix.cpp matrix.h control_input.h external_matrix_routines.h interaction_model.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c matrix.cpp -DDIMENSION=$(DIMENSION)

misc.o: misc.cpp misc.h
$(CC) $(NO_GRO_CFLAGS) -c misc.cpp

range_finding.o: range_finding.cpp range_finding.h force_computation.h interaction_model.h matrix.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c range_finding.cpp -DDIMENSION=$(DIMENSION)

splines.o: splines.h interaction_model.h
$(CC) $(NO_GRO_CFLAGS) -c splines.cpp -DDIMENSION=$(DIMENSION)

topology.o: topology.cpp topology.h interaction_model.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c topology.cpp -DDIMENSION=$(DIMENSION)

trajectory_input_no_gro.o: trajectory_input.cpp trajectory_input.h control_input.h misc.h
$(CC) $(NO_GRO_CFLAGS) -c trajectory_input.cpp -D"_exclude_gromacs=1" -o trajectory_input_no_gro.o

# Other convenient commands
clean:
rm *.[o]

all: newfm_no_gro.x rangefinder_no_gro.x combinefm_no_gro.x libmscg.a
Expand Up @@ -82,9 +82,6 @@ combinefm.o: combinefm.cpp batch_fm_combination.h $(COMMON_SOURCE)
rangefinder.o: rangefinder.cpp range_finding.h $(COMMON_SOURCE)
$(CC) $(CFLAGS) -c rangefinder.cpp

scalarfm.o: scalarfm.cpp $(COMMON_SOURCE)
$(CC) $(CFLAGS) -c scalarfm.cpp

batch_fm_combination.o: batch_fm_combination.cpp batch_fm_combination.h external_matrix_routines.h misc.h
$(CC) $(CFLAGS) -c batch_fm_combination.cpp

Expand Down Expand Up @@ -137,7 +134,4 @@ trajectory_input_no_gro.o: trajectory_input.cpp trajectory_input.h control_input
clean:
rm *.[o]

all:
make newfm.x; \
make rangefinder.x; \
make combinefm.x;
all: newfm.x rangefinder.x combinefm.x libmscg.a
2 changes: 1 addition & 1 deletion src/Make/Makefile.lapack
Expand Up @@ -107,4 +107,4 @@ trajectory_input_no_gro.o: trajectory_input.cpp trajectory_input.h control_input
clean:
rm *.[o]

all: newfm.x rangefinder.x combinefm.x
all: newfm.x rangefinder.x combinefm.x libmscg.a
2 changes: 1 addition & 1 deletion src/Make/Makefile.mac
Expand Up @@ -105,4 +105,4 @@ trajectory_input_no_gro.o: trajectory_input.cpp trajectory_input.h control_input
clean:
rm *.[o]

all: newfm.x rangefinder.x combinefm.x
all: newfm.x rangefinder.x combinefm.x libmscg.a
137 changes: 0 additions & 137 deletions src/Make/Makefile.makena_cpp

This file was deleted.

0 comments on commit 4934bbb

Please sign in to comment.