Building NFFT

Intel

module load intel/19.0.5
module load fftw3/intel/3.3.8
export CC=icc
export CXX=icpc
export F77=ifort
export COMPARCH="-xCORE-AVX512 -qopt-zmm-usage=high"
parentdir="$(dirname "$(pwd)")"
export BUILDDIR=$parentdir
echo "building in "$BUILDDIR
export PREFIX=$BUILDDIR
echo "building for "$PREFIX
echo "Press ENTER to configure";read aaa
export CFLAGS=" -fPIC -O3 $COMPARCH -Wl,-rpath=$LD_RUN_PATH" 
export CXXFLAGS="-fPIC -O3 $COMPARCH -Wl,-rpath=$LD_RUN_PATH" 
export LIBS="-L/sw/numerics/fftw3/intel/3.3.8/skl/lib/" 
./configure --prefix=$PREFIX --enable-all --enable-openmp \ 
  --with-fftw3=/sw/numerics/fftw3/intel/3.3.8/skl \ 
  --with-fftw3-libdir=/sw/numerics/fftw3/intel/3.3.8/skl/lib \ 
  --with-fftw3-includedir=/sw/numerics/fftw3/intel/3.3.8/skl/include 

echo "Press ENTER to compile"; read ttt 
make -j4 
make check 
echo "Press ENTER to install"; read ttt 
make install 
echo "Do not forget to make clean"

GCC

module load gcc/9.2.0
module load fftw3/gcc.9/3.3.8
export CC=gcc
export CXX=g++
export F77=gfortran
export COMPARCH="-march=skylake-avx512"

parentdir="$(dirname "$(pwd)")"
export BUILDDIR=$parentdir
echo "building in "$BUILDDIR

export PREFIX=$BUILDDIR
echo "building for "$PREFIX
echo "Press ENTER to configure";read aaa

export CFLAGS="  -fPIC -O3 $COMPARCH -Wl,-rpath=$LD_RUN_PATH"
export CXXFLAGS="-fPIC -O3 $COMPARCH -Wl,-rpath=$LD_RUN_PATH"
export LIBS="-L/sw/numerics/fftw3/gcc.9.2.0/3.3.8/skl/lib/"

./configure --prefix=$PREFIX --enable-all --enable-openmp \
--with-fftw3=/sw/numerics/fftw3/gcc.9.2.0/3.3.8/skl \
--with-fftw3-libdir=/sw/numerics/fftw3/gcc.9.2.0/3.3.8/skl/lib \
--with-fftw3-includedir=/sw/numerics/fftw3/gcc.9.2.0/3.3.8/skl/include

echo "Press ENTER to compile"; read ttt
make -j4
make check
echo "Press ENTER to install"; read ttt
make install