Difference between revisions of "Installation script for Z800"

From www.coria-cfd.fr
Jump to: navigation, search
m
 
(51 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Copy and paste the following lines in .bash_profile:
+
Install [https://software.intel.com/fr-fr/non-commercial-software-development Intel Parallel Studio]
 +
 
 +
Makefile_extlib:
 +
 +
INSTALL_DIR = /
 +
WGET = wget
 +
NPROCS = 8
 +
SHELL=/bin/bash
 +
 +
OPENMPI_NAME = openmpi
 +
OPENMPI_VERSION = 1.10.1
 +
OPENMPI_MAJOR_VERSION = 1.10
 +
OPENMPI_LOCATION = http://www.open-mpi.org/software/ompi/v$(OPENMPI_MAJOR_VERSION)/downloads
 +
OPENMPI_FILE = $(OPENMPI_NAME)-$(OPENMPI_VERSION).tar.bz2
 +
OPENMPI_CONFIGURE_OPTIONS = --enable-mpi-fortran --enable-static --enable-shared
 +
 +
ZLIB_NAME = zlib
 +
ZLIB_VERSION = 1.2.8
 +
ZLIB_LOCATION = http://zlib.net
 +
ZLIB_FILE = $(ZLIB_NAME)-$(ZLIB_VERSION).tar.gz
 +
ZLIB_CONFIGURE_OPTIONS =
 +
 +
FFTW_NAME = fftw
 +
FFTW_VERSION = 3.3.4
 +
FFTW_LOCATION = http://www.fftw.org
 +
FFTW_FILE = $(FFTW_NAME)-$(FFTW_VERSION).tar.gz
 +
FFTW_CONFIGURE_OPTIONS =
 +
 +
HDF5_NAME = hdf5
 +
HDF5_VERSION = 1.8.16
 +
HDF5_LOCATION = http://www.hdfgroup.org/ftp/HDF5/current/src
 +
HDF5_FILE = $(HDF5_NAME)-$(HDF5_VERSION).tar.bz2
 +
HDF5_CONFIGURE_OPTIONS = --enable-fortran --enable-cxx
 +
 +
PARMETIS_NAME = parmetis
 +
PARMETIS_VERSION = 4.0.3
 +
PARMETIS_LOCATION = http://glaros.dtc.umn.edu/gkhome/fetch/sw/parmetis
 +
PARMETIS_FILE = $(PARMETIS_NAME)-$(PARMETIS_VERSION).tar.gz
 +
PARMETIS_CONFIGURE_OPTIONS =
 +
 +
SCOTCH_NAME = scotch
 +
SCOTCH_VERSION = 6.0.4
 +
SCOTCH_LOCATION = https://gforge.inria.fr/frs/download.php/file/34618
 +
SCOTCH_FILE = $(SCOTCH_NAME)_$(SCOTCH_VERSION).tar.gz
 +
SCOTCH_CONFIGURE_OPTIONS =
 +
 +
LAPACK_NAME = lapack
 +
LAPACK_VERSION = 3.6.0
 +
LAPACK_LOCATION = http://www.netlib.org/lapack
 +
LAPACK_FILE = $(LAPACK_NAME)-$(LAPACK_VERSION).tgz
 +
LAPACK_CONFIGURE_OPTIONS =
 +
 +
MMG3D4_NAME = mmg3d4
 +
MMG3D4_VERSION = 4.0.3
 +
MMG3D4_LOCATION = https://gforge.inria.fr/frs/download.php/file/34531
 +
MMG3D4_FILE = $(MMG3D4_NAME)-$(MMG3D4_VERSION)-Source.tar.gz
 +
MMG3D4_CONFIGURE_OPTIONS =
 +
 +
PAPI_NAME = papi
 +
PAPI_VERSION = 5.4.1
 +
PAPI_LOCATION = http://icl.cs.utk.edu/projects/papi/downloads
 +
PAPI_FILE = $(PAPI_NAME)-$(PAPI_VERSION).tar.gz
 +
PAPI_CONFIGURE_OPTIONS =
 +
 +
PETSC_NAME = petsc
 +
PETSC_VERSION = 3.6.3
 +
PETSC_LOCATION = http://ftp.mcs.anl.gov/pub/petsc/release-snapshots
 +
PETSC_FILE = $(PETSC_NAME)-$(PETSC_VERSION).tar.gz
 +
PETSC_CONFIGURE_OPTIONS =
 +
 +
SLEPC_NAME = slepc
 +
SLEPC_VERSION = 3.6.2
 +
SLEPC_LOCATION = http://www.grycap.upv.es/slepc/download/distrib
 +
SLEPC_FILE = $(SLEPC_NAME)-$(SLEPC_VERSION).tar.gz
 +
SLEPC_CONFIGURE_OPTIONS =
 +
 +
COMPILER_FAMILY  = intel
 +
COMPILER_VERSION  = 15.0.0
 +
COMPILER_PATH    = /opt/intel/composerxe/bin
 +
COMPILER_MPI_PATH = $(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION)/bin
 +
COMPILER_CC      = $(COMPILER_PATH)/icc
 +
COMPILER_MPICC    = $(COMPILER_MPI_PATH)/mpicc
 +
COMPILER_CFLAGS  = "-O2 -g"
 +
COMPILER_CXX      = $(COMPILER_PATH)/icpc
 +
COMPILER_MPICXX  = $(COMPILER_MPI_PATH)/mpicxx
 +
COMPILER_CXXFLAGS = "-O2 -g"
 +
COMPILER_FC      = $(COMPILER_PATH)/ifort
 +
COMPILER_MPIFC    = $(COMPILER_MPI_PATH)/mpifort
 +
COMPILER_FCFLAGS  = "-O2 -g"
 +
COMPILER_FF      = $(COMPILER_PATH)/ifort
 +
COMPILER_MPIFF    = $(COMPILER_MPI_PATH)/mpifort
 +
COMPILER_FFLAGS  = "-O2 -g"
 +
 +
default: $(OPENMPI_NAME)-$(OPENMPI_VERSION) $(ZLIB_NAME)-$(ZLIB_VERSION) $(FFTW_NAME)-$(FFTW_VERSION) $(HDF5_NAME)-$(HDF5_VERSION) $(PARMETIS_NAME)-$(PARMETIS_VERSION) $(SCOTCH_NAME)-$(SCOTCH_VERSION) $(LAPACK_NAME)-$(LAPACK_VERSION) $(MMG3D4_NAME)-$(MMG3D4_VERSION) $(PAPI_NAME)-$(PAPI_VERSION) $(PETSC_NAME)-$(PETSC_VERSION) $(SLEPC_NAME)-$(SLEPC_VERSION)
 +
 +
$(OPENMPI_NAME)-$(OPENMPI_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(OPENMPI_FILE) ]; then $(WGET) $(OPENMPI_LOCATION)/$(OPENMPI_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_NAME)-$(OPENMPI_VERSION) &&\
 +
mkdir -p $(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(OPENMPI_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_NAME)-$(OPENMPI_VERSION) &&\
 +
./configure --prefix=$(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION) CC=$(COMPILER_CC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_CXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_FC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_FF) FFLAGS=$(COMPILER_FFLAGS) $(OPENMPI_CONFIGURE_OPTIONS)&&\
 +
make -j $(NPROCS) &&\
 +
rm -rf $(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION) &&\
 +
make install\
 +
)
 +
 +
$(ZLIB_NAME)-$(ZLIB_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(ZLIB_FILE) ]; then $(WGET) $(ZLIB_LOCATION)/$(ZLIB_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_NAME)-$(ZLIB_VERSION) &&\
 +
mkdir -p $(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(ZLIB_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_NAME)-$(ZLIB_VERSION) &&\
 +
./configure --prefix=$(INSTALL_DIR)/local/$(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_VERSION) &&\
 +
make -j $(NPROCS) &&\
 +
rm -rf $(INSTALL_DIR)/local/$(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_VERSION) &&\
 +
make install\
 +
)
 +
 +
$(FFTW_NAME)-$(FFTW_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(FFTW_FILE) ]; then $(WGET) $(FFTW_LOCATION)/$(FFTW_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_NAME)-$(FFTW_VERSION) &&\
 +
mkdir -p $(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(FFTW_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_NAME)-$(FFTW_VERSION) &&\
 +
./configure --prefix=$(INSTALL_DIR)/local/$(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_VERSION) CC=$(COMPILER_CC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_CXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_FC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_FF) FFLAGS=$(COMPILER_FFLAGS) $(FFTW_CONFIGURE_OPTIONS)&&\
 +
make -j $(NPROCS) &&\
 +
rm -rf $(INSTALL_DIR)/local/$(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_VERSION) &&\
 +
make install\
 +
)
 +
 +
$(HDF5_NAME)-$(HDF5_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(HDF5_FILE) ]; then $(WGET) $(HDF5_LOCATION)/$(HDF5_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_NAME)-$(HDF5_VERSION) &&\
 +
mkdir -p $(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(HDF5_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_NAME)-$(HDF5_VERSION) &&\
 +
./configure --prefix=$(INSTALL_DIR)/local/$(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_VERSION) CC=$(COMPILER_CC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_CXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_FC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_FF) FFLAGS=$(COMPILER_FFLAGS) $(HDF5_CONFIGURE_OPTIONS)&&\
 +
make -j $(NPROCS) &&\
 +
rm -rf $(INSTALL_DIR)/local/$(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_VERSION) &&\
 +
make install\
 +
)
 +
 +
$(PARMETIS_NAME)-$(PARMETIS_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
rm -rf  $(INSTALL_DIR)/local/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_VERSION) &&\
 +
rm -rf  $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_NAME)-$(PARMETIS_VERSION) &&\
 +
mkdir -p $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(PARMETIS_FILE) ]; then $(WGET) $(PARMETIS_LOCATION)/$(PARMETIS_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(PARMETIS_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_NAME)-$(PARMETIS_VERSION) &&\
 +
cd metis &&\
 +
sed -i 's/make -C $$(BUILDDIR) $$@ $$(MAKEFLAGS);/$$(MAKE) -C $$(BUILDDIR) $$@;/g' Makefile &&\
 +
make config prefix=$(INSTALL_DIR)/local/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_VERSION) CC=$(COMPILER_MPICC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_MPICXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_MPIFC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_MPIFF) FFLAGS=$(COMPILER_FFLAGS) $(PARMETIS_CONFIGURE_OPTIONS) &&\
 +
make &&\
 +
make install &&\
 +
cd .. &&\
 +
sed -i 's/make -C $$(BUILDDIR) $$@ $$(MAKEFLAGS);/$$(MAKE) -C $$(BUILDDIR) $$@;/g' Makefile &&\
 +
sed -i 's/cc        = mpicc/cc        = not-set/g' Makefile &&\
 +
sed -i 's/cxx        = mpicxx/cxx        = not-set/g' Makefile &&\
 +
make config prefix=$(INSTALL_DIR)/local/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_VERSION) CC=$(COMPILER_MPICC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_MPICXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_MPIFC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_MPIFF) FFLAGS=$(COMPILER_FFLAGS) $(PARMETIS_CONFIGURE_OPTIONS) &&\
 +
make &&\
 +
make install \
 +
)
 +
 +
$(SCOTCH_NAME)-$(SCOTCH_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(SCOTCH_FILE) ]; then $(WGET) $(SCOTCH_LOCATION)/$(SCOTCH_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)-$(SCOTCH_VERSION) &&\
 +
mkdir -p $(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(SCOTCH_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION) &&\
 +
rm -rf $(INSTALL_DIR)/local/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_VERSION) &&\
 +
echo "EXE            =" > $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "LIB            = .a" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "OBJ            = .o" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "MAKE            = make" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "AR              = ar" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "ARFLAGS        = -ruv" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "CAT            = cat" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "CCS            = $(COMPILER_MPICC)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "CCP            = $(COMPILER_MPICC)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "CCD            = $(COMPILER_MPICC)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "CFLAGS          = -O3 -DSCOTCH_PTHREAD -DCOMMON_TIMING_OLD -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME -DSCOTCH_RENAME_PARSER -Drestrict=__restrict -DIDXSIZE64 -I$(COMPILER_PATH)/include" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "CLIBFLAGS      =" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "LDFLAGS        = -lz -lm" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "CP              = cp" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "LEX            = flex -Pscotchyy -olex.yy.c" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "LN              = ln" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "MKDIR          = mkdir -p" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "MV              = mv" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "RANLIB          = ranlib" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "YACC            = bison -pscotchyy -y -b y" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
echo "prefix          = $(INSTALL_DIR)/local/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_VERSION)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
 +
cd $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src &&\
 +
make -j $(NPROCS) scotch &&\
 +
make -j $(NPROCS) ptscotch &&\
 +
make install\
 +
)
 +
 +
$(LAPACK_NAME)-$(LAPACK_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(LAPACK_FILE) ]; then $(WGET) $(LAPACK_LOCATION)/$(LAPACK_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_NAME)-$(LAPACK_VERSION) &&\
 +
mkdir -p $(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(LAPACK_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_NAME)-$(LAPACK_VERSION) &&\
 +
        rm -f make.inc &&\
 +
        touch make.inc &&\
 +
        echo "SHELL = /bin/sh" >> make.inc &&\
 +
        echo "FORTRAN    = $(COMPILER_MPIFC)" >> make.inc &&\
 +
        echo "OPTS      = $(COMPILER_FCFLAGS)" >> make.inc &&\
 +
        echo "LOADER    = $(COMPILER_MPIFC)" >> make.inc &&\
 +
        echo "DRVOPTS    = $(COMPILER_FCFLAGS)" >> make.inc &&\
 +
        echo "NOOPT      = -O0" >> make.inc &&\
 +
        echo "LOADOPTS  =" >> make.inc &&\
 +
        echo "TIMER      = EXT_ETIME" >> make.inc &&\
 +
        echo "CC        = $(COMPILER_MPICC)" >> make.inc &&\
 +
        echo "CFLAGS    = $(COMPILER_CFLAGS)" >> make.inc &&\
 +
        echo "ARCH      = ar" >> make.inc &&\
 +
        echo "ARCHFLAGS  = cr" >> make.inc &&\
 +
        echo "RANLIB    = ranlib" >> make.inc &&\
 +
        echo "XBLASLIB  =" >> make.inc &&\
 +
        echo "BLASLIB    = ../../librefblas.a" >> make.inc &&\
 +
        echo "LAPACKLIB  = liblapack.a" >> make.inc &&\
 +
        echo "TMGLIB    = libtmglib.a" >> make.inc &&\
 +
        echo "LAPACKELIB = liblapacke.a" >> make.inc &&\
 +
        make -j $(NPROCS) blaslib &&\
 +
        make -j $(NPROCS) lapacklib &&\
 +
        rm -rf $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION) &&\
 +
        mkdir -p $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION)/lib &&\
 +
        cp liblapack.a  $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION)/lib/liblapack.a &&\
 +
        cp librefblas.a $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION)/lib/libblas.a\
 +
)
 +
 +
 +
$(MMG3D4_NAME)-$(MMG3D4_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(MMG3D4_FILE) ]; then $(WGET) $(MMG3D4_LOCATION)/$(MMG3D4_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(MMG3D4_NAME)-$(MMG3D4_VERSION)-Source &&\
 +
mkdir -p $(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(MMG3D4_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(MMG3D4_NAME)-$(MMG3D4_VERSION)-Source &&\
 +
export SCOTCH_DIR=$(INSTALL_DIR)/local/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_VERSION) &&\
 +
export CC=$(COMPILER_MPICC) && \
 +
export CXX=$(COMPILER_MPICXX) && \
 +
mkdir build &&\
 +
cd build &&\
 +
cmake -DCMAKE_INSTALL_PREFIX=$(INSTALL_DIR)/local/$(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(MMG3D4_VERSION) .. &&\
 +
make &&\
 +
make install \
 +
)
 +
 +
$(PAPI_NAME)-$(PAPI_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/Builds &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(PAPI_FILE) ]; then $(WGET) $(PAPI_LOCATION)/$(PAPI_FILE); fi &&\
 +
cd $(INSTALL_DIR)/Builds &&\
 +
rm -rf $(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PAPI_NAME)-$(PAPI_VERSION) &&\
 +
mkdir -p $(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(PAPI_FILE) &&\
 +
cd $(INSTALL_DIR)/Builds/$(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PAPI_NAME)-$(PAPI_VERSION) &&\
 +
cd src &&\
 +
export F77=$(COMPILER_F77) && export CC=$(COMPILER_CC) && ./configure --prefix=$(INSTALL_DIR)/local/$(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PAPI_VERSION) &&\
 +
make -j $(NPROCS)&&\
 +
make install \
 +
)
 +
 +
$(PETSC_NAME)-$(PETSC_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(PETSC_FILE) ]; then $(WGET) $(PETSC_LOCATION)/$(PETSC_FILE); fi &&\
 +
cd $(INSTALL_DIR)/local &&\
 +
rm -rf $(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) &&\
 +
mkdir -p $(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(PETSC_FILE) &&\
 +
cd $(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
mv $(PETSC_NAME)-$(PETSC_VERSION) $(PETSC_VERSION) &&\
 +
cd $(PETSC_VERSION) &&\
 +
unset PETSC_DIR && ./configure PETSC_ARCH=linux-intel64 --with-mpi-dir=$(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION) --download-hypre --with-blas-lapack-dir=/opt/intel/mkl &&\
 +
make PETSC_DIR=$(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) PETSC_ARCH=linux-intel64 all \
 +
)
 +
 +
$(SLEPC_NAME)-$(SLEPC_VERSION):
 +
(\
 +
mkdir -p $(INSTALL_DIR)/Downloads &&\
 +
mkdir -p $(INSTALL_DIR)/local &&\
 +
cd $(INSTALL_DIR)/Downloads &&\
 +
if [ ! -f $(SLEPC_FILE) ]; then $(WGET) $(SLEPC_LOCATION)/$(SLEPC_FILE); fi &&\
 +
cd $(INSTALL_DIR)/local &&\
 +
rm -rf $(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SLEPC_VERSION) &&\
 +
mkdir -p $(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
cd $(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
tar -xvf $(INSTALL_DIR)/Downloads/$(SLEPC_FILE) &&\
 +
cd $(INSTALL_DIR)/local/$(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
 +
mv $(SLEPC_NAME)-$(SLEPC_VERSION) $(SLEPC_VERSION) &&\
 +
cd $(SLEPC_VERSION) &&\
 +
export PETSC_DIR=$(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) && export PETSC_ARCH=linux-intel64 && ./configure &&\
 +
make SLEPC_DIR=$(INSTALL_DIR)/local/$(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SLEPC_VERSION) PETSC_DIR=$(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) PETSC_ARCH=linux-intel64 \
 +
)
 +
 +
 
 +
.bash_profile / .bashrc:
 +
#==================#
 +
# SECTION 1: aliases
 +
 
  alias l='ls -l'
 
  alias l='ls -l'
  export PATH=$PATH:/home/admin/local/openmpi-1.4.4/bin
+
   
  export LD_LIBRARY_PATH="/home/admin/local/openmpi-1.4.4/lib:$LD_LIBRARY_PATH"
+
# end of SECTION 1
 +
#==================#
 +
 +
 +
#==================#
 +
# SECTION 2: compilers
 +
 +
# crt stuff
 +
export LD_LIBRARY_PATH="/usr/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH"
 +
  export LIBRARY_PATH="/usr/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH"
 +
 +
# compiler and libraries
 +
source ~/.bashrc_intel
 +
source ~/.bashrc_openmpi
 +
source ~/.bashrc_hdf5
 +
source ~/.bashrc_papi
 +
source ~/.bashrc_petsc
 +
source ~/.bashrc_slepc
 +
 +
# end of SECTION 2
 +
#==================#
 +
 +
#==================#
 +
# SECTION 3: applications
 +
 +
# yales2
 +
source ~/yales2/platforms/xxxx.bash.env
 +
 +
# end of SECTION 3
 +
#==================#
  
Copy and paste this in a file called Install.make:
 
  
  INSTALL_DIR = /home/admin
+
.bashrc_intel:
 +
 
 +
  # intel-15.0.0
 +
source /opt/intel/composerxe/bin/compilervars.sh intel64
 +
export INTEL_HOME="/opt/intel/composerxe"
 +
export INTEL_INC="$INTEL_HOME/include"
 +
export INTEL_LIB="$INTEL_HOME/lib"
 +
export INTEL_BIN="$INTEL_HOME/bin"
 +
export INTEL_MAN="$INTEL_HOME/man"
 +
export PATH="$INTEL_BIN:$PATH"
 +
export LIBRARY_PATH="$INTEL_LIB:$LIBRARY_PATH"
 +
export LD_LIBRARY_PATH="$INTEL_LIB:$LD_LIBRARY_PATH"
 +
export MANPATH="$INTEL_MAN:$MANPATH"
 +
 
 +
 
 +
.bashrc_openmpi:
 +
 
 +
export MPI_HOME="/local/openmpi/intel-15.0.0/1.10.1"
 +
export MPI_INC="$MPI_HOME/include"
 +
export MPI_LIB="$MPI_HOME/lib"
 +
export MPI_BIN="$MPI_HOME/bin"
 +
export MPI_MAN="$MPI_HOME/share/man"
 +
export PATH="$MPI_BIN:$PATH"
 +
export LIBRARY_PATH="$MPI_LIB:$LIBRARY_PATH"
 +
export LD_LIBRARY_PATH="$MPI_LIB:$LD_LIBRARY_PATH"
 +
export MANPATH="$MPI_MAN:$MANPATH"
 +
 
 +
 
 +
.bahsrc_hdf5:
 +
 
 +
export HDF5_HOME="/local/hdf5/intel-15.0.0/1.8.16"
 +
export HDF5_INC="$HDF5_HOME/include"
 +
export HDF5_BIN="$HDF5_HOME/bin"
 +
export HDF5_LIB="$HDF5_HOME/lib"
 +
export PATH="$HDF5_BIN:$PATH"
 +
export LIBRARY_PATH="$HDF5_LIB:$LIBRARY_PATH"
 +
export LD_LIBRARY_PATH="$HDF5_LIB:$LD_LIBRARY_PATH"
 +
 
 +
 
 +
.bashrc_papi:
 +
 
 +
export PAPI_HOME="/local/papi/intel-15.0.0/5.4.1"
 +
export PAPI_INC="$PAPI_HOME/include"
 +
export PAPI_BIN="$PAPI_HOME/bin"
 +
export PAPI_LIB="$PAPI_HOME/lib"
 +
export PATH="$PAPI_BIN:$PATH"
 +
export LIBRARY_PATH="$PAPI_LIB:$LIBRARY_PATH"
 +
export LD_LIBRARY_PATH="$PAPI_LIB:$LD_LIBRARY_PATH"
 +
 
 +
 
 +
.bashrc_petsc:
 +
 
 +
export PETSC_HOME="/local/petsc/intel-15.0.0/3.6.3/"
 +
export PETSC_INC="$PETSC_HOME/linux-intel64/include"
 +
export PETSC_BIN="$PETSC_HOME/linux-intel64/bin"
 +
export PETSC_LIB="$PETSC_HOME/linux-intel64/lib"
 +
export PATH="$PETSC_BIN:$PATH"
 +
export LIBRARY_PATH="$PETSC_LIB:$LIBRARY_PATH"
 +
export LD_LIBRARY_PATH="$PETSC_LIB:$LD_LIBRARY_PATH"
 +
 
 +
 
 +
.bashrc_slepc:
 +
 
 +
export SLEPC_HOME="/local/slepc/intel-15.0.0/3.6.2/"
 +
export SLEPC_INC="$SLEPC_HOME/linux-intel64/include"
 +
export SLEPC_BIN="$SLEPC_HOME/linux-intel64/bin"
 +
export SLEPC_LIB="$SLEPC_HOME/linux-intel64/lib"
 +
export PATH="$SLEPC_BIN:$PATH"
 +
export LIBRARY_PATH="$SLEPC_LIB:$LIBRARY_PATH"
 +
export LD_LIBRARY_PATH="$SLEPC_LIB:$LD_LIBRARY_PATH"
 +
 
 +
 
 +
For RHEL 7 platforms:
 +
 
 +
# Avant le premier boot
 +
# 1/ mettre les 4 disques de 4TB dans les 4 baies du bas
 +
# 2/ mettre le disque SSD de 256GB dans la baie du haut
 
   
 
   
  F77  = /usr/bin/gfortran
+
  # Au boot
  FC    = /usr/bin/gfortran
+
  # 1/ créer le raid matériel
  CC    = /usr/bin/gcc
+
  # 2/ boot UEFI sur le SSD
  CXX  = /usr/bin/g++
+
  # 3/ Désactiver HyperThreading
  CPP  = /usr/bin/cpp
+
  # 4/ Désactiver IntelBoost
CXXCPP = /usr/bin/cpp
+
 
   
 
   
  all: structure sed fftw3 openmpi hdf5 lapack ParMetis scotch petsc
+
  # finir l’install RHEL
 +
# créer admincoria/root avec un mdp toto (ATTENTION AU CLAVIER AMERICAIN)
 
   
 
   
  freenx-ocelot:
+
  # clavier francais au boot
sudo add-apt-repository ppa:freenx-team
+
localectl set-locale LANG=en_US.utf8
sudo sed -i 's/oneiric/lucid/g' /etc/apt/sources.list.d/freenx-team-ppa-oneiric.list
+
localectl set-x11-keymap fr
sudo apt-get update && sudo apt-get upgrade
+
localectl set-keymap fr
wget -P /tmp http://de.archive.ubuntu.com/ubuntu/pool/main/e/esound/esound-common_0.2.41-8_all.deb
+
wget -P /tmp http://de.archive.ubuntu.com/ubuntu/pool/main/e/esound/libesd0_0.2.41-8_amd64.deb
+
wget -P /tmp http://de.archive.ubuntu.com/ubuntu/pool/main/e/esound/esound-clients_0.2.41-8_amd64.deb
+
-sudo dpkg -i /tmp/esound-common_0.2.41-8_all.deb
+
-sudo dpkg -i /tmp/libesd0_0.2.41-8_amd64.deb
+
-sudo dpkg -i /tmp/esound-clients_0.2.41-8_amd64.deb
+
sudo apt-get -f -y install
+
sudo dpkg -i esound-common_0.2.41-8_all.deb
+
sudo dpkg -i libesd0_0.2.41-8_amd64.deb
+
sudo dpkg -i esound-clients_0.2.41-8_amd64.deb
+
rm -f /tmp/esound-common_0.2.41-8_all.deb /tmp/libesd0_0.2.41-8_amd64.deb /tmp/esound-lients_0.2.41-8_amd64.deb
+
sudo apt-get install -y freenx
+
 
   
 
   
  packages:
+
  # remettre les mdp classiques pour admincoria et root
sudo apt-get install -y tcsh
+
sudo apt-get install -y ssh
+
sudo apt-get install -y g++
+
sudo apt-get install -y gdb
+
sudo apt-get install -y gfortran
+
sudo apt-get install -y cmake
+
sudo apt-get install -y flex
+
sudo apt-get install -y bison
+
sudo apt-get install -y git
+
sudo apt-get install -y gitk
+
sudo apt-get install -y subversion
+
sudo apt-get install -y rapidsvn
+
sudo apt-get install -y vim-gnome
+
sudo apt-get install -y lib32z1-dev
+
sudo apt-get install -y zlib1g-dev
+
sudo apt-get install -y tkdiff
+
sudo apt-get install -y default-jre
+
sudo apt-get install -y gparted
+
sudo apt-get install -y synaptic
+
sudo apt-get install -y eclipse
+
sudo apt-get install -y paraview
+
sudo apt-get install -y gnash
+
 
   
 
   
  structure:
+
  # modifier le nom de la machine
mkdir -p $(INSTALL_DIR)/Downloads
+
vi /etc/hostname
mkdir -p $(INSTALL_DIR)/Builds
+
mkdir -p $(INSTALL_DIR)/local
+
 
   
 
   
  sed:
+
  # associer un numéro RHN
(cd $(INSTALL_DIR)/Downloads && wget http://ftp.gnu.org/gnu/sed/sed-4.2.tar.bz2)
+
subscription-manager register --username=admincoria --password=XXXXXXXX --auto-attach
(cd $(INSTALL_DIR)/Builds && tar -jxvf $(INSTALL_DIR)/Downloads/sed-4.2.tar.bz2)
+
(cd $(INSTALL_DIR)/Builds/sed-4.2 && ./configure --prefix=$(INSTALL_DIR)/local/sed-4.2 && make && make install)
+
 
   
 
   
  fftw3:
+
  # créer une table de partition gpt et une partition sur /dev/sda (RAID matériel)
(cd $(INSTALL_DIR)/Downloads && wget http://www.fftw.org/fftw-3.3.tar.gz)
+
parted /dev/sda
(cd $(INSTALL_DIR)/Builds && tar -zxvf $(INSTALL_DIR)/Downloads/fftw-3.3.tar.gz)
+
mktable gpt
(cd $(INSTALL_DIR)/Builds/fftw-3.3 && ./configure --prefix=$(INSTALL_DIR)/local/fftw-3.3 && make && make install)
+
mkpart primary xfs 64MB 100%
 
   
 
   
  openmpi:
+
  # créer un filesysteme pour /home
(cd $(INSTALL_DIR)/Downloads && wget http://www.open-mpi.org/software/ompi/v1.4/downloads/openmpi-1.4.4.tar.bz2)
+
mkfs -t xfs /dev/sda1
(cd $(INSTALL_DIR)/Builds && tar -jxvf $(INSTALL_DIR)/Downloads/openmpi-1.4.4.tar.bz2)
+
(cd $(INSTALL_DIR)/Builds/openmpi-1.4.4 && ./configure --prefix=$(INSTALL_DIR)/local/openmpi-1.4.4 --enable-mpi-f90 && make && make install)
+
 
   
 
   
  hdf5:
+
  # deménager l’ancien home et créer le nouveau
(cd $(INSTALL_DIR)/Downloads && wget http://www.hdfgroup.org/ftp/HDF5/current/src/hdf5-1.8.8.tar.bz2)
+
umount /home
(cd $(INSTALL_DIR)/Builds && tar -jxvf $(INSTALL_DIR)/Downloads/hdf5-1.8.8.tar.bz2)
+
mount /dev/sda1 /home
(cd $(INSTALL_DIR)/Builds/hdf5-1.8.8 && ./configure --prefix=$(INSTALL_DIR)/local/hdf5-1.8.8 --enable-fortran --enable-cxx && make && make install)
+
mkdir /home2
 +
mount /dev/rhel/home /home2
 +
mv /home2/admincoria /home/admincoria
 +
umount /home2
 
   
 
   
  lapack:
+
  # modifier /etc/fstab
(cd $(INSTALL_DIR)/Downloads && wget http://www.netlib.org/lapack/lapack-3.4.0.tgz)
+
/dev/sda1              /home                  xfs    defaults        1 2
(cd $(INSTALL_DIR)/Builds && tar -zxvf $(INSTALL_DIR)/Downloads/lapack-3.4.0.tgz)
+
#==> PENSER A ENLEVER LA LIGNE /dev/rhel/home
(cd $(INSTALL_DIR)/Builds/lapack-3.4.0 && cp make.inc.example make.inc && make blaslib && make lapacklib)
+
mkdir -p $(INSTALL_DIR)/local/blas/lib
+
mkdir -p $(INSTALL_DIR)/local/lapack/lib
+
ln -s $(INSTALL_DIR)/Builds/lapack-3.4.0/liblapack.a $(INSTALL_DIR)/local/lapack/lib/liblapack.a
+
ln -s $(INSTALL_DIR)/Builds/lapack-3.4.0/librefblas.a $(INSTALL_DIR)/local/blas/lib/libblas.a
+
 
   
 
   
  ParMetis:
+
  # commandes utils pour lvm
(cd $(INSTALL_DIR)/Downloads && wget http://glaros.dtc.umn.edu/gkhome/fetch/sw/parmetis/OLD/ParMetis-3.2.0.tar.gz)
+
lvmdiskscan
(cd $(INSTALL_DIR)/Builds && tar -zxvf $(INSTALL_DIR)/Downloads/ParMetis-3.2.0.tar.gz)
+
vgscan
echo "CC = $(INSTALL_DIR)/local/openmpi-1.4.4/bin/mpicc" > $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
vgdisplay
echo "OPTFLAGS = -O3" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
lvdisplay
echo "INCDIR =" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
echo "COPTIONS = -DNDEBUG" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
echo "LD = $(INSTALL_DIR)/local/openmpi-1.4.4/bin/mpicc" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
echo "LIBDIR =" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
echo "AR = ar rv" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
echo "RANLIB = ar -ts" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
echo "VERNUM = 3.2.0" >> $(INSTALL_DIR)/Builds/ParMetis-3.2.0/Makefile.in
+
(cd $(INSTALL_DIR)/Builds/ParMetis-3.2.0 && make)
+
mkdir -p $(INSTALL_DIR)/local/ParMetis-3.2.0/lib
+
mkdir -p $(INSTALL_DIR)/local/ParMetis-3.2.0/include
+
ln -s $(INSTALL_DIR)/Builds/ParMetis-3.2.0/*.a $(INSTALL_DIR)/local/ParMetis-3.2.0/lib/
+
ln -s $(INSTALL_DIR)/Builds/ParMetis-3.2.0/*.h $(INSTALL_DIR)/local/ParMetis-3.2.0/include/
+
 
   
 
   
  scotch:
+
  # enlever le volume logique de /home sur le SSD
(cd $(INSTALL_DIR)/Downloads && wget https://gforge.inria.fr/frs/download.php/28977/scotch_5.1.12b.tar.gz)
+
lvremove /dev/rhel/home
(cd $(INSTALL_DIR)/Builds && tar -zxvf $(INSTALL_DIR)/Downloads/scotch_5.1.12b.tar.gz)
+
echo "EXE            =" > $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "LIB            = .a" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "OBJ            = .o" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "MAKE            = make" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "AR              = ar" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "ARFLAGS        = -ruv" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "CAT            = cat" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "CCS            = $(CC)" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "CCP            = $(INSTALL_DIR)/local/openmpi-1.4.4/bin/mpicc" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "CCD            = $(CC)" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "CFLAGS          = -O3 -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_PTHREAD -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME -DSCOTCH_RENAME_PARSER -DSCOTCH_PTHREAD -Drestrict=__restrict -DIDXSIZE64 -I$(INSTALL_DIR)/local/openmpi-1.4.4/include" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "CLIBFLAGS      =" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "LDFLAGS        = -lz -lm -lrt" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "CP              = cp" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "LEX            = flex -Pscotchyy -olex.yy.c" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "LN              = ln" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "MKDIR          = mkdir -p" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "MV              = mv" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "RANLIB          = ranlib" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "YACC            = bison -pscotchyy -y -b y" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
echo "prefix          = $(INSTALL_DIR)/local/scotch_5.1.12" >> $(INSTALL_DIR)/Builds/scotch_5.1.12/src/Makefile.inc
+
(cd $(INSTALL_DIR)/Builds/scotch_5.1.12/src && make scotch && make ptscotch && make install)
+
 
   
 
   
  petsc:
+
  # augmenter la taille de / à 100% de la place dispo
(cd $(INSTALL_DIR)/Downloads && wget http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/petsc-lite-3.2-p6.tar.gz)
+
lvextend -l +100%FREE /dev/rhel/root
(cd $(INSTALL_DIR)/Builds && tar -zxvf $(INSTALL_DIR)/Downloads/petsc-lite-3.2-p6.tar.gz)
+
(cd $(INSTALL_DIR)/Builds/petsc-3.2-p6 && ./configure --prefix=$(INSTALL_DIR)/local/petsc-3.2-p6 --download-hypre=yes --with-mpi-dir=$(INSTALL_DIR)/local/openmpi-1.4.4 --with-blas-lib=$(INSTALL_DIR)/local/blas/lib/libblas.a --with-lapack-lib=$(INSTALL_DIR)/local/lapack/lib/liblapack.a && make PETSC_DIR=$(INSTALL_DIR)/Builds/petsc-3.2-p6 PETSC_ARCH=arch-linux2-c-debug all && make PETSC_DIR=$(INSTALL_DIR)/Builds/petsc-3.2-p6 PETSC_ARCH=arch-linux2-c-debug install)
+
 
   
 
   
  clean:
+
  # augmenter la taille de / jusqu’au maxi dispo
echo
+
df -k
 +
xfs_info /
 +
xfs_growfs /
 +
df -k
 +
 +
# ajouter le EPEL 7.2
 +
rpm -Uvh http://download.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm
 +
 +
# ajouter les bons repos
 +
subscription-manager repos --enable rhel-7-workstation-extras-rpms
 +
subscription-manager repos --enable rhel-7-workstation-optional-rpms
 +
subscription-manager repos --enable rhel-7-workstation-rhn-tools-rpms
 +
 +
# MaJ système
 +
yum update -y
 +
 +
# install
 +
yum install -y x2goserver
 +
yum install -y gparted
 +
yum install -y fail2ban
 +
yum install -y zlib
 +
yum install -y linuxdoc-tools
 +
yum install -y gnuplot
 +
yum install -y paraview
 +
yum install -y lzip
 +
yum install -y xorg-x11-fonts*
 +
yum install -y htop emacs xemacs
 +
 +
# rapatrier clé ssh admincoria puis chmod 700 .ssh
 +
 +
# modifier la config ssh et redémarrer ssh
 +
vi /etc/ssh/sshd_config
 +
RSAAuthentication yes
 +
PubkeyAuthentication yes
 +
#PasswordAuthentication yes
 +
PasswordAuthentication no
 +
KerberosAuthentication no
 +
GSSAPIAuthentication no
 +
 +
systemctl restart sshd.service
 +
 +
# set fail2ban
 +
vi /etc/fail2ban/jail.conf
 +
ignoreip = 127.0.0.1/8 194.254.16.0/24 88.184.97.196
 +
bantime  = 86400
 +
findtime  = 86400
 +
[sshd]
 +
enabled  = true
 +
port    = ssh
 +
logpath = %(sshd_log)s
 +
[sshd-ddos]
 +
enabled  = true
 +
port    = ssh
 +
logpath = %(sshd_log)s
 +
 +
fail2ban-server
 +
fail2ban-client reload
 +
chkconfig fail2ban on
 +
 +
# install intel dans /opt en tant qu'admincoria
 +
rsync azuv amdincoria@luis:/opt/intel /tmp
 +
mv /tmp/intel /opt
 +
chown -R root:root /opt/intel
 +
 +
# créer les .bashrc_* dans /etc/skel
 +
source .bashrc_intel
 +
 +
# Install librairies (Makefile sur coria-cfd)
 +
 +
# installer grace
 +
wget ftp://plasma-gate.weizmann.ac.il/pub/grace/src/stable/grace-5.1.24.tar.gz
 +
./configure --prefix=/local
 +
make -j 8
 +
make install
 +
 +
# créer les utilisateurs
 +
 +
# rapatrier maqao
 +
 +
# VLC & mencoder & ffmpeg
 +
rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-1.el7.nux.noarch.rpm
 +
yum -y update
 +
yum install -y vlc mencoder ffmpeg
  
  
Line 148: Line 618:
 
'''WARNING''':
 
'''WARNING''':
 
If you encounter any problem for installing freeNX, you should consider visiting [http://notepad2.blogspot.com/2011/05/install-freenx-server-on-ubuntu-1004.html this]  website...
 
If you encounter any problem for installing freeNX, you should consider visiting [http://notepad2.blogspot.com/2011/05/install-freenx-server-on-ubuntu-1004.html this]  website...
 
'''GAMBIT Installation''':
 
You must type the following lines to install some additional packages that are recquired by gambit:
 
 
wget -P /tmp http://ubuntu.mirror.cambrium.nl/ubuntu//pool/multiverse/o/openmotif/libmotif3_2.2.3-4_amd64.deb && dpkg -i /tmp/libmotif3_2.2.3-4_amd64.deb
 
sudo apt-get install libstdc++5 xfs xfstt xfonts-75dpi xfonts-100dpi
 
rm /tmp/libmotif3_2.2.3-4_amd64.deb
 

Latest revision as of 02:42, 5 December 2015

Install Intel Parallel Studio

Makefile_extlib:

INSTALL_DIR = /
WGET = wget
NPROCS = 8
SHELL=/bin/bash

OPENMPI_NAME = openmpi
OPENMPI_VERSION = 1.10.1
OPENMPI_MAJOR_VERSION = 1.10
OPENMPI_LOCATION = http://www.open-mpi.org/software/ompi/v$(OPENMPI_MAJOR_VERSION)/downloads
OPENMPI_FILE = $(OPENMPI_NAME)-$(OPENMPI_VERSION).tar.bz2
OPENMPI_CONFIGURE_OPTIONS = --enable-mpi-fortran --enable-static --enable-shared

ZLIB_NAME = zlib
ZLIB_VERSION = 1.2.8
ZLIB_LOCATION = http://zlib.net
ZLIB_FILE = $(ZLIB_NAME)-$(ZLIB_VERSION).tar.gz
ZLIB_CONFIGURE_OPTIONS =

FFTW_NAME = fftw
FFTW_VERSION = 3.3.4
FFTW_LOCATION = http://www.fftw.org
FFTW_FILE = $(FFTW_NAME)-$(FFTW_VERSION).tar.gz
FFTW_CONFIGURE_OPTIONS =

HDF5_NAME = hdf5
HDF5_VERSION = 1.8.16
HDF5_LOCATION = http://www.hdfgroup.org/ftp/HDF5/current/src
HDF5_FILE = $(HDF5_NAME)-$(HDF5_VERSION).tar.bz2
HDF5_CONFIGURE_OPTIONS = --enable-fortran --enable-cxx

PARMETIS_NAME = parmetis
PARMETIS_VERSION = 4.0.3
PARMETIS_LOCATION = http://glaros.dtc.umn.edu/gkhome/fetch/sw/parmetis
PARMETIS_FILE = $(PARMETIS_NAME)-$(PARMETIS_VERSION).tar.gz
PARMETIS_CONFIGURE_OPTIONS =

SCOTCH_NAME = scotch
SCOTCH_VERSION = 6.0.4
SCOTCH_LOCATION = https://gforge.inria.fr/frs/download.php/file/34618
SCOTCH_FILE = $(SCOTCH_NAME)_$(SCOTCH_VERSION).tar.gz
SCOTCH_CONFIGURE_OPTIONS =

LAPACK_NAME = lapack
LAPACK_VERSION = 3.6.0
LAPACK_LOCATION = http://www.netlib.org/lapack
LAPACK_FILE = $(LAPACK_NAME)-$(LAPACK_VERSION).tgz
LAPACK_CONFIGURE_OPTIONS =

MMG3D4_NAME = mmg3d4
MMG3D4_VERSION = 4.0.3
MMG3D4_LOCATION = https://gforge.inria.fr/frs/download.php/file/34531
MMG3D4_FILE = $(MMG3D4_NAME)-$(MMG3D4_VERSION)-Source.tar.gz
MMG3D4_CONFIGURE_OPTIONS =

PAPI_NAME = papi
PAPI_VERSION = 5.4.1
PAPI_LOCATION = http://icl.cs.utk.edu/projects/papi/downloads
PAPI_FILE = $(PAPI_NAME)-$(PAPI_VERSION).tar.gz
PAPI_CONFIGURE_OPTIONS =

PETSC_NAME = petsc
PETSC_VERSION = 3.6.3
PETSC_LOCATION = http://ftp.mcs.anl.gov/pub/petsc/release-snapshots
PETSC_FILE = $(PETSC_NAME)-$(PETSC_VERSION).tar.gz
PETSC_CONFIGURE_OPTIONS =

SLEPC_NAME = slepc
SLEPC_VERSION = 3.6.2
SLEPC_LOCATION = http://www.grycap.upv.es/slepc/download/distrib
SLEPC_FILE = $(SLEPC_NAME)-$(SLEPC_VERSION).tar.gz
SLEPC_CONFIGURE_OPTIONS =

COMPILER_FAMILY   = intel
COMPILER_VERSION  = 15.0.0
COMPILER_PATH     = /opt/intel/composerxe/bin
COMPILER_MPI_PATH = $(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION)/bin
COMPILER_CC       = $(COMPILER_PATH)/icc
COMPILER_MPICC    = $(COMPILER_MPI_PATH)/mpicc
COMPILER_CFLAGS   = "-O2 -g"
COMPILER_CXX      = $(COMPILER_PATH)/icpc
COMPILER_MPICXX   = $(COMPILER_MPI_PATH)/mpicxx
COMPILER_CXXFLAGS = "-O2 -g"
COMPILER_FC       = $(COMPILER_PATH)/ifort
COMPILER_MPIFC    = $(COMPILER_MPI_PATH)/mpifort
COMPILER_FCFLAGS  = "-O2 -g"
COMPILER_FF       = $(COMPILER_PATH)/ifort
COMPILER_MPIFF    = $(COMPILER_MPI_PATH)/mpifort
COMPILER_FFLAGS   = "-O2 -g"

default: $(OPENMPI_NAME)-$(OPENMPI_VERSION) $(ZLIB_NAME)-$(ZLIB_VERSION) $(FFTW_NAME)-$(FFTW_VERSION) $(HDF5_NAME)-$(HDF5_VERSION) $(PARMETIS_NAME)-$(PARMETIS_VERSION) $(SCOTCH_NAME)-$(SCOTCH_VERSION) $(LAPACK_NAME)-$(LAPACK_VERSION) $(MMG3D4_NAME)-$(MMG3D4_VERSION) $(PAPI_NAME)-$(PAPI_VERSION) $(PETSC_NAME)-$(PETSC_VERSION) $(SLEPC_NAME)-$(SLEPC_VERSION)

$(OPENMPI_NAME)-$(OPENMPI_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(OPENMPI_FILE) ]; then $(WGET) $(OPENMPI_LOCATION)/$(OPENMPI_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_NAME)-$(OPENMPI_VERSION) &&\
	mkdir -p $(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(OPENMPI_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_NAME)-$(OPENMPI_VERSION) &&\
	./configure --prefix=$(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION) CC=$(COMPILER_CC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_CXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_FC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_FF) FFLAGS=$(COMPILER_FFLAGS) $(OPENMPI_CONFIGURE_OPTIONS)&&\
	make -j $(NPROCS) &&\
	rm -rf $(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION) &&\
	make install\
	)

$(ZLIB_NAME)-$(ZLIB_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(ZLIB_FILE) ]; then $(WGET) $(ZLIB_LOCATION)/$(ZLIB_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_NAME)-$(ZLIB_VERSION) &&\
	mkdir -p $(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(ZLIB_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_NAME)-$(ZLIB_VERSION) &&\
	./configure --prefix=$(INSTALL_DIR)/local/$(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_VERSION) &&\
	make -j $(NPROCS) &&\
	rm -rf $(INSTALL_DIR)/local/$(ZLIB_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(ZLIB_VERSION) &&\
	make install\
	)

$(FFTW_NAME)-$(FFTW_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(FFTW_FILE) ]; then $(WGET) $(FFTW_LOCATION)/$(FFTW_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_NAME)-$(FFTW_VERSION) &&\
	mkdir -p $(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(FFTW_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_NAME)-$(FFTW_VERSION) &&\
	./configure --prefix=$(INSTALL_DIR)/local/$(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_VERSION) CC=$(COMPILER_CC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_CXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_FC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_FF) FFLAGS=$(COMPILER_FFLAGS) $(FFTW_CONFIGURE_OPTIONS)&&\
	make -j $(NPROCS) &&\
	rm -rf $(INSTALL_DIR)/local/$(FFTW_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(FFTW_VERSION) &&\
	make install\
	)

$(HDF5_NAME)-$(HDF5_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(HDF5_FILE) ]; then $(WGET) $(HDF5_LOCATION)/$(HDF5_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_NAME)-$(HDF5_VERSION) &&\
	mkdir -p $(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(HDF5_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_NAME)-$(HDF5_VERSION) &&\
	./configure --prefix=$(INSTALL_DIR)/local/$(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_VERSION) CC=$(COMPILER_CC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_CXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_FC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_FF) FFLAGS=$(COMPILER_FFLAGS) $(HDF5_CONFIGURE_OPTIONS)&&\
	make -j $(NPROCS) &&\
	rm -rf $(INSTALL_DIR)/local/$(HDF5_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(HDF5_VERSION) &&\
	make install\
	)

$(PARMETIS_NAME)-$(PARMETIS_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	rm -rf   $(INSTALL_DIR)/local/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_VERSION) &&\
	rm -rf   $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_NAME)-$(PARMETIS_VERSION) &&\
	mkdir -p $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(PARMETIS_FILE) ]; then $(WGET) $(PARMETIS_LOCATION)/$(PARMETIS_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(PARMETIS_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_NAME)-$(PARMETIS_VERSION) &&\
	cd metis &&\
	sed -i 's/make -C $$(BUILDDIR) $$@ $$(MAKEFLAGS);/$$(MAKE) -C $$(BUILDDIR) $$@;/g' Makefile &&\
	make config prefix=$(INSTALL_DIR)/local/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_VERSION) CC=$(COMPILER_MPICC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_MPICXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_MPIFC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_MPIFF) FFLAGS=$(COMPILER_FFLAGS) $(PARMETIS_CONFIGURE_OPTIONS) &&\
	make &&\
	make install &&\
	cd .. &&\
	sed -i 's/make -C $$(BUILDDIR) $$@ $$(MAKEFLAGS);/$$(MAKE) -C $$(BUILDDIR) $$@;/g' Makefile &&\
	sed -i 's/cc         = mpicc/cc         = not-set/g' Makefile &&\
	sed -i 's/cxx        = mpicxx/cxx        = not-set/g' Makefile &&\
	make config prefix=$(INSTALL_DIR)/local/$(PARMETIS_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PARMETIS_VERSION) CC=$(COMPILER_MPICC) CFLAGS=$(COMPILER_CFLAGS) CXX=$(COMPILER_MPICXX) CXXFLAGS=$(COMPILER_CXXFLAGS) FC=$(COMPILER_MPIFC) FCLAGS=$(COMPILER_FCFLAGS) FF=$(COMPILER_MPIFF) FFLAGS=$(COMPILER_FFLAGS) $(PARMETIS_CONFIGURE_OPTIONS) &&\
	make &&\
	make install \
	)

$(SCOTCH_NAME)-$(SCOTCH_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(SCOTCH_FILE) ]; then $(WGET) $(SCOTCH_LOCATION)/$(SCOTCH_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)-$(SCOTCH_VERSION) &&\
	mkdir -p $(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(SCOTCH_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION) &&\
	rm -rf $(INSTALL_DIR)/local/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_VERSION) &&\
	echo "EXE             =" > $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "LIB             = .a" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "OBJ             = .o" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "MAKE            = make" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "AR              = ar" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "ARFLAGS         = -ruv" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "CAT             = cat" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "CCS             = $(COMPILER_MPICC)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "CCP             = $(COMPILER_MPICC)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "CCD             = $(COMPILER_MPICC)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "CFLAGS          = -O3 -DSCOTCH_PTHREAD -DCOMMON_TIMING_OLD -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME -DSCOTCH_RENAME_PARSER -Drestrict=__restrict -DIDXSIZE64 -I$(COMPILER_PATH)/include" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "CLIBFLAGS       =" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "LDFLAGS         = -lz -lm" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "CP              = cp" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "LEX             = flex -Pscotchyy -olex.yy.c" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "LN              = ln" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "MKDIR           = mkdir -p" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "MV              = mv" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "RANLIB          = ranlib" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "YACC            = bison -pscotchyy -y -b y" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	echo "prefix          = $(INSTALL_DIR)/local/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_VERSION)" >> $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src/Makefile.inc &&\
	cd $(INSTALL_DIR)/Builds/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_NAME)_$(SCOTCH_VERSION)/src &&\
	make -j $(NPROCS) scotch &&\
	make -j $(NPROCS) ptscotch &&\
	make install\
	)

$(LAPACK_NAME)-$(LAPACK_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(LAPACK_FILE) ]; then $(WGET) $(LAPACK_LOCATION)/$(LAPACK_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_NAME)-$(LAPACK_VERSION) &&\
	mkdir -p $(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(LAPACK_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(LAPACK_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_NAME)-$(LAPACK_VERSION) &&\
        rm -f make.inc &&\
        touch make.inc &&\
        echo "SHELL = /bin/sh" >> make.inc &&\
        echo "FORTRAN    = $(COMPILER_MPIFC)" >> make.inc &&\
        echo "OPTS       = $(COMPILER_FCFLAGS)" >> make.inc &&\
        echo "LOADER     = $(COMPILER_MPIFC)" >> make.inc &&\
        echo "DRVOPTS    = $(COMPILER_FCFLAGS)" >> make.inc &&\
        echo "NOOPT      = -O0" >> make.inc &&\
        echo "LOADOPTS   =" >> make.inc &&\
        echo "TIMER      = EXT_ETIME" >> make.inc &&\
        echo "CC         = $(COMPILER_MPICC)" >> make.inc &&\
        echo "CFLAGS     = $(COMPILER_CFLAGS)" >> make.inc &&\
        echo "ARCH       = ar" >> make.inc &&\
        echo "ARCHFLAGS  = cr" >> make.inc &&\
        echo "RANLIB     = ranlib" >> make.inc &&\
        echo "XBLASLIB   =" >> make.inc &&\
        echo "BLASLIB    = ../../librefblas.a" >> make.inc &&\
        echo "LAPACKLIB  = liblapack.a" >> make.inc &&\
        echo "TMGLIB     = libtmglib.a" >> make.inc &&\
        echo "LAPACKELIB = liblapacke.a" >> make.inc &&\
        make -j $(NPROCS) blaslib &&\
        make -j $(NPROCS) lapacklib &&\
        rm -rf $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION) &&\
        mkdir -p $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION)/lib &&\
        cp liblapack.a  $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION)/lib/liblapack.a &&\
        cp librefblas.a $(INSTALL_DIR)/local/lapack/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(LAPACK_VERSION)/lib/libblas.a\
	)


$(MMG3D4_NAME)-$(MMG3D4_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(MMG3D4_FILE) ]; then $(WGET) $(MMG3D4_LOCATION)/$(MMG3D4_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(MMG3D4_NAME)-$(MMG3D4_VERSION)-Source &&\
	mkdir -p $(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(MMG3D4_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(MMG3D4_NAME)-$(MMG3D4_VERSION)-Source &&\
	export SCOTCH_DIR=$(INSTALL_DIR)/local/$(SCOTCH_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SCOTCH_VERSION) &&\
	export CC=$(COMPILER_MPICC) && \
	export CXX=$(COMPILER_MPICXX) && \
	mkdir build &&\
	cd build &&\
	cmake -DCMAKE_INSTALL_PREFIX=$(INSTALL_DIR)/local/$(MMG3D4_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(MMG3D4_VERSION) .. &&\
	make &&\
	make install \
	)

$(PAPI_NAME)-$(PAPI_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/Builds &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(PAPI_FILE) ]; then $(WGET) $(PAPI_LOCATION)/$(PAPI_FILE); fi &&\
	cd $(INSTALL_DIR)/Builds &&\
	rm -rf $(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PAPI_NAME)-$(PAPI_VERSION) &&\
	mkdir -p $(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(PAPI_FILE) &&\
	cd $(INSTALL_DIR)/Builds/$(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PAPI_NAME)-$(PAPI_VERSION) &&\
	cd src &&\
	export F77=$(COMPILER_F77) && export CC=$(COMPILER_CC) && ./configure --prefix=$(INSTALL_DIR)/local/$(PAPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PAPI_VERSION) &&\
	make -j $(NPROCS)&&\
	make install \
	)

$(PETSC_NAME)-$(PETSC_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(PETSC_FILE) ]; then $(WGET) $(PETSC_LOCATION)/$(PETSC_FILE); fi &&\
	cd $(INSTALL_DIR)/local &&\
	rm -rf $(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) &&\
	mkdir -p $(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(PETSC_FILE) &&\
	cd $(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	mv $(PETSC_NAME)-$(PETSC_VERSION) $(PETSC_VERSION) &&\
	cd $(PETSC_VERSION) &&\
	unset PETSC_DIR && ./configure PETSC_ARCH=linux-intel64 --with-mpi-dir=$(INSTALL_DIR)/local/$(OPENMPI_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(OPENMPI_VERSION) --download-hypre --with-blas-lapack-dir=/opt/intel/mkl &&\
	make PETSC_DIR=$(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) PETSC_ARCH=linux-intel64 all \
	)

$(SLEPC_NAME)-$(SLEPC_VERSION):
	(\
	mkdir -p $(INSTALL_DIR)/Downloads &&\
	mkdir -p $(INSTALL_DIR)/local &&\
	cd $(INSTALL_DIR)/Downloads &&\
	if [ ! -f $(SLEPC_FILE) ]; then $(WGET) $(SLEPC_LOCATION)/$(SLEPC_FILE); fi &&\
	cd $(INSTALL_DIR)/local &&\
	rm -rf $(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SLEPC_VERSION) &&\
	mkdir -p $(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	cd $(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	tar -xvf $(INSTALL_DIR)/Downloads/$(SLEPC_FILE) &&\
	cd $(INSTALL_DIR)/local/$(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION) &&\
	mv $(SLEPC_NAME)-$(SLEPC_VERSION) $(SLEPC_VERSION) &&\
	cd $(SLEPC_VERSION) &&\
	export PETSC_DIR=$(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) && export PETSC_ARCH=linux-intel64 && ./configure &&\
	make SLEPC_DIR=$(INSTALL_DIR)/local/$(SLEPC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(SLEPC_VERSION) PETSC_DIR=$(INSTALL_DIR)/local/$(PETSC_NAME)/$(COMPILER_FAMILY)-$(COMPILER_VERSION)/$(PETSC_VERSION) PETSC_ARCH=linux-intel64 \
	)

.bash_profile / .bashrc:

#==================#
# SECTION 1: aliases

alias l='ls -l'

# end of SECTION 1
#==================#


#==================#
# SECTION 2: compilers

# crt stuff
export LD_LIBRARY_PATH="/usr/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH"
export LIBRARY_PATH="/usr/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH"

# compiler and libraries
source ~/.bashrc_intel
source ~/.bashrc_openmpi
source ~/.bashrc_hdf5
source ~/.bashrc_papi
source ~/.bashrc_petsc
source ~/.bashrc_slepc

# end of SECTION 2
#==================#

#==================#
# SECTION 3: applications

# yales2
source ~/yales2/platforms/xxxx.bash.env

# end of SECTION 3
#==================#


.bashrc_intel:

# intel-15.0.0
source /opt/intel/composerxe/bin/compilervars.sh intel64
export INTEL_HOME="/opt/intel/composerxe"
export INTEL_INC="$INTEL_HOME/include"
export INTEL_LIB="$INTEL_HOME/lib"
export INTEL_BIN="$INTEL_HOME/bin"
export INTEL_MAN="$INTEL_HOME/man"
export PATH="$INTEL_BIN:$PATH"
export LIBRARY_PATH="$INTEL_LIB:$LIBRARY_PATH"
export LD_LIBRARY_PATH="$INTEL_LIB:$LD_LIBRARY_PATH"
export MANPATH="$INTEL_MAN:$MANPATH"


.bashrc_openmpi:

export MPI_HOME="/local/openmpi/intel-15.0.0/1.10.1"
export MPI_INC="$MPI_HOME/include"
export MPI_LIB="$MPI_HOME/lib"
export MPI_BIN="$MPI_HOME/bin"
export MPI_MAN="$MPI_HOME/share/man"
export PATH="$MPI_BIN:$PATH"
export LIBRARY_PATH="$MPI_LIB:$LIBRARY_PATH"
export LD_LIBRARY_PATH="$MPI_LIB:$LD_LIBRARY_PATH"
export MANPATH="$MPI_MAN:$MANPATH"


.bahsrc_hdf5:

export HDF5_HOME="/local/hdf5/intel-15.0.0/1.8.16"
export HDF5_INC="$HDF5_HOME/include"
export HDF5_BIN="$HDF5_HOME/bin"
export HDF5_LIB="$HDF5_HOME/lib"
export PATH="$HDF5_BIN:$PATH"
export LIBRARY_PATH="$HDF5_LIB:$LIBRARY_PATH"
export LD_LIBRARY_PATH="$HDF5_LIB:$LD_LIBRARY_PATH"


.bashrc_papi:

export PAPI_HOME="/local/papi/intel-15.0.0/5.4.1"
export PAPI_INC="$PAPI_HOME/include"
export PAPI_BIN="$PAPI_HOME/bin"
export PAPI_LIB="$PAPI_HOME/lib"
export PATH="$PAPI_BIN:$PATH"
export LIBRARY_PATH="$PAPI_LIB:$LIBRARY_PATH"
export LD_LIBRARY_PATH="$PAPI_LIB:$LD_LIBRARY_PATH"


.bashrc_petsc:

export PETSC_HOME="/local/petsc/intel-15.0.0/3.6.3/"
export PETSC_INC="$PETSC_HOME/linux-intel64/include"
export PETSC_BIN="$PETSC_HOME/linux-intel64/bin"
export PETSC_LIB="$PETSC_HOME/linux-intel64/lib"
export PATH="$PETSC_BIN:$PATH"
export LIBRARY_PATH="$PETSC_LIB:$LIBRARY_PATH"
export LD_LIBRARY_PATH="$PETSC_LIB:$LD_LIBRARY_PATH"


.bashrc_slepc:

export SLEPC_HOME="/local/slepc/intel-15.0.0/3.6.2/"
export SLEPC_INC="$SLEPC_HOME/linux-intel64/include"
export SLEPC_BIN="$SLEPC_HOME/linux-intel64/bin"
export SLEPC_LIB="$SLEPC_HOME/linux-intel64/lib"
export PATH="$SLEPC_BIN:$PATH"
export LIBRARY_PATH="$SLEPC_LIB:$LIBRARY_PATH"
export LD_LIBRARY_PATH="$SLEPC_LIB:$LD_LIBRARY_PATH"


For RHEL 7 platforms:

# Avant le premier boot
# 1/ mettre les 4 disques de 4TB dans les 4 baies du bas
# 2/ mettre le disque SSD de 256GB dans la baie du haut

# Au boot
# 1/ créer le raid matériel
# 2/ boot UEFI sur le SSD
# 3/ Désactiver HyperThreading
# 4/ Désactiver IntelBoost

# finir l’install RHEL
# créer admincoria/root avec un mdp toto (ATTENTION AU CLAVIER AMERICAIN)

# clavier francais au boot
localectl set-locale LANG=en_US.utf8
localectl set-x11-keymap fr
localectl set-keymap fr

# remettre les mdp classiques pour admincoria et root

# modifier le nom de la machine
vi /etc/hostname 

# associer un numéro RHN
subscription-manager register --username=admincoria --password=XXXXXXXX --auto-attach

# créer une table de partition gpt et une partition sur /dev/sda (RAID matériel)
parted /dev/sda
mktable gpt
mkpart primary xfs 64MB 100%

# créer un filesysteme pour /home
mkfs -t xfs /dev/sda1

# deménager l’ancien home et créer le nouveau
umount /home
mount /dev/sda1 /home
mkdir /home2
mount /dev/rhel/home /home2
mv /home2/admincoria /home/admincoria
umount /home2

# modifier /etc/fstab
/dev/sda1               /home                   xfs     defaults        1 2
#==> PENSER A ENLEVER LA LIGNE /dev/rhel/home

# commandes utils pour lvm
lvmdiskscan
vgscan
vgdisplay
lvdisplay

# enlever le volume logique de /home sur le SSD
lvremove /dev/rhel/home

# augmenter la taille de / à 100% de la place dispo
lvextend -l +100%FREE /dev/rhel/root

# augmenter la taille de / jusqu’au maxi dispo
df -k
xfs_info /
xfs_growfs /
df -k

# ajouter le EPEL 7.2
rpm -Uvh http://download.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm

# ajouter les bons repos
subscription-manager repos --enable rhel-7-workstation-extras-rpms
subscription-manager repos --enable rhel-7-workstation-optional-rpms
subscription-manager repos --enable rhel-7-workstation-rhn-tools-rpms

# MaJ système
yum update -y

# install
yum install -y x2goserver
yum install -y gparted
yum install -y fail2ban
yum install -y zlib
yum install -y linuxdoc-tools
yum install -y gnuplot
yum install -y paraview
yum install -y lzip
yum install -y xorg-x11-fonts*
yum install -y htop emacs xemacs

# rapatrier clé ssh admincoria puis chmod 700 .ssh

# modifier la config ssh et redémarrer ssh
vi /etc/ssh/sshd_config
RSAAuthentication yes
PubkeyAuthentication yes
#PasswordAuthentication yes
PasswordAuthentication no
KerberosAuthentication no
GSSAPIAuthentication no

systemctl restart sshd.service

# set fail2ban
vi /etc/fail2ban/jail.conf
ignoreip = 127.0.0.1/8 194.254.16.0/24 88.184.97.196
bantime  = 86400
findtime  = 86400
[sshd]
enabled  = true
port    = ssh
logpath = %(sshd_log)s
[sshd-ddos]
enabled  = true
port    = ssh
logpath = %(sshd_log)s

fail2ban-server
fail2ban-client reload
chkconfig fail2ban on

# install intel dans /opt en tant qu'admincoria
rsync azuv amdincoria@luis:/opt/intel /tmp
mv /tmp/intel /opt
chown -R root:root /opt/intel

# créer les .bashrc_* dans /etc/skel 
source .bashrc_intel

# Install librairies (Makefile sur coria-cfd)

# installer grace
wget ftp://plasma-gate.weizmann.ac.il/pub/grace/src/stable/grace-5.1.24.tar.gz
./configure --prefix=/local
make -j 8
make install

# créer les utilisateurs

# rapatrier maqao

# VLC & mencoder & ffmpeg
rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-1.el7.nux.noarch.rpm
yum -y update
yum install -y vlc mencoder ffmpeg


WARNING: If you encounter any problem for installing freeNX, you should consider visiting this website...