some more small changes, including bug fix in configure + relative linking in Makefile for spectral solver
This commit is contained in:
parent
4850e5987d
commit
656e3cc6ca
|
@ -6,6 +6,7 @@ if [ "$OSTYPE" == "linux-gnu" ] || [ "$OSTYPE" == 'linux' ]
|
|||
else
|
||||
STAT=$(stat "`dirname $BASH_SOURCE`")
|
||||
DAMASK_ROOT=${STAT##* }
|
||||
unset STAT
|
||||
fi
|
||||
|
||||
if [ -f $HOME/.damask/damask.conf ]; then
|
||||
|
@ -14,14 +15,6 @@ else
|
|||
source /etc/damask.conf
|
||||
fi
|
||||
|
||||
if [ "x$DAMASK_NUM_THREADS" != "x" ]
|
||||
then export DAMASK_NUM_THREADS=$DAMASK_NUM_THREADS
|
||||
fi
|
||||
|
||||
if [ "x$F90" != "x" ]
|
||||
then export F90=$F90
|
||||
fi
|
||||
|
||||
# disable output in case of scp
|
||||
if [ ! -z "$PS1" ]; then
|
||||
echo
|
||||
|
@ -29,13 +22,27 @@ if [ ! -z "$PS1" ]; then
|
|||
echo Max-Planck-Institut für Eisenforschung, Düsseldorf
|
||||
echo http://damask.mpie.de
|
||||
echo
|
||||
echo Preparing environment ...
|
||||
echo Using environment with ...
|
||||
echo "DAMASK installation in $DAMASK_ROOT"
|
||||
echo "DAMASK_NUM_THREADS=$DAMASK_NUM_THREADS"
|
||||
echo "F90=$F90"
|
||||
echo "FFTW_ROOT=$FFTW_ROOT"
|
||||
if [ "x$LAPACK_ROOT" != "x" ]; then
|
||||
echo "LAPACK_ROOT=$LAPACK_ROOT"
|
||||
fi
|
||||
if [ "x$ACML_ROOT" != "x" ]; then
|
||||
echo "ACML_ROOT=$ACML_ROOT"
|
||||
fi
|
||||
if [ "x$IMKL_ROOT" != "x" ]; then
|
||||
echo "IMKL_ROOT=$IMKL_ROOT"
|
||||
fi
|
||||
echo "MARC_ROOT=$MARC_ROOT"
|
||||
echo "HDF5_ROOT=$HDF5_ROOT (future use)"
|
||||
fi
|
||||
ulimit -s unlimited
|
||||
ulimit -c 0
|
||||
ulimit -v unlimited
|
||||
ulimit -m unlimited
|
||||
export PYTHONPATH=$PYTHONPATH:$DAMASK_ROOT/lib
|
||||
unset DAMASK_ROOT
|
||||
|
||||
|
|
|
@ -46,7 +46,7 @@ COMPILERNAME ?= $(F90)
|
|||
|
||||
INCLUDE_DIRS :=-I../lib
|
||||
LIBRARIES :=-lfftw3
|
||||
LIB_DIRS :=-L$(FFTW_ROOT)/lib
|
||||
LIB_DIRS :=-L$$FFTW_ROOT/lib
|
||||
|
||||
ifeq "$(FASTBUILD)" "YES"
|
||||
OPENMP := OFF
|
||||
|
@ -94,16 +94,16 @@ IMKL_ARCH =_sequential
|
|||
endif
|
||||
|
||||
ifneq "x$(IMKL_ROOT)" "x"
|
||||
LIB_DIRS :=-L$(IMKL_ROOT)/lib/intel64
|
||||
LIB_DIRS :=-L$$IMKL_ROOT/lib/intel64
|
||||
INCLUDE_DIRS +=-I$(IMKL_ROOT)/include
|
||||
LIBRARIES +=-lmkl_intel_lp64 -lmkl_core -lmkl$(ACML_ARCH) -lm -lpthread -liomp5
|
||||
else
|
||||
ifneq "x$(ACML_ROOT)" "x"
|
||||
LIB_DIRS +=-L$(ACML_ROOT)/$(F90)64$(ACML_ARCH)/lib
|
||||
LIB_DIRS +=-L$$ACML_ROOT/$(F90)64$(ACML_ARCH)/lib
|
||||
LIBRARIES +=-lacml$(ACML_ARCH)
|
||||
else
|
||||
ifneq "x$(LAPACK_ROOT)" "x"
|
||||
LIB_DIRS +=-L$(LAPACK_ROOT)/lib64 -L$(LAPACK_ROOT)/lib
|
||||
LIB_DIRS +=-L$$LAPACK_ROOT/lib64 -L$$LAPACK_ROOT/lib
|
||||
LIBRARIES +=-llapack
|
||||
endif
|
||||
endif
|
||||
|
@ -115,7 +115,7 @@ endif
|
|||
#hdf5
|
||||
ifeq "$(HDF5)" "ON"
|
||||
LIBRARIES +=-lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5
|
||||
LIB_DIRS +=-L$(HDF5ROOT)/lib
|
||||
LIB_DIRS +=-L$$HDF5ROOT/lib
|
||||
INCLUDE_DIRS +=-I$(HDF5ROOT)/include -DHDF
|
||||
endif
|
||||
|
||||
|
|
|
@ -232,7 +232,7 @@ for opt, value in options.__dict__.items():
|
|||
if opt == 'threads' and value !='':
|
||||
output.append('DAMASK_NUM_THREADS=%s\n'%value)
|
||||
if opt == 'blasType' and value !='':
|
||||
output.append('%s_ROOT=%s\n'%(blasType,options.blasRoot))
|
||||
output.append('%s_ROOT=%s\n'%(options.blasType,options.blasRoot))
|
||||
|
||||
for spectralOption in options.spectraloptions:
|
||||
output.append(spectralOption+'\n')
|
||||
|
|
|
@ -32,11 +32,11 @@ compileCommand = {
|
|||
|
||||
# see http://cens.ioc.ee/pipermail/f2py-users/2003-December/000621.html
|
||||
if options['IMKL_ROOT'] != '' and options['F90'] != 'gfortran':
|
||||
lib_lapack = '-L%s/lib/intel64 -I%s/include -lmkl_intel_lp64 -lmkl_core -lmkl_sequential -lpthread -lm -liomp5'%(options['IMKL_ROOT'],options['IMKL_ROOT'])
|
||||
lib_lapack = '-L$IMKL_ROOT/lib/intel64 -I%s/include -lmkl_intel_lp64 -lmkl_core -lmkl_sequential -lpthread -lm -liomp5'%options['IMKL_ROOT']
|
||||
elif options['ACML_ROOT'] != '':
|
||||
lib_lapack = '-L%s/%s64/lib -lacml'%(options['ACML_ROOT'],options['F90'])
|
||||
lib_lapack = '-L$ACML/%s64/lib -lacml'%options['F90']
|
||||
elif options['LAPACK_ROOT'] != '':
|
||||
lib_lapack = '-L%s/lib -L%s/lib64 -llapack'%(options['LAPACK_ROOT'],options['LAPACK_ROOT'])
|
||||
lib_lapack = '-L$LAPACK_ROOT/lib -L$LAPACK_ROOT/lib64 -llapack'
|
||||
|
||||
os.chdir(codeDir) # needed for compilation with gfortran and f2py
|
||||
try:
|
||||
|
@ -66,7 +66,7 @@ cmd = 'f2py damask.core.pyf' +\
|
|||
' FEsolving.f90'+\
|
||||
' mesh.f90'+\
|
||||
' core_quit.f90'+\
|
||||
' -L%s/lib -lfftw3'%(options['FFTW_ROOT'])+\
|
||||
' -L$FFTW_ROOT/lib -lfftw3'+\
|
||||
' %s'%lib_lapack
|
||||
|
||||
print('Executing: '+cmd)
|
||||
|
|
Loading…
Reference in New Issue