Centos 7 build

Qbox installation issues
Forum rules
You must be a registered user to post in this forum. Registered users may also post new topics if they consider that their subject do not correspond to any topic already present on the forum.

Centos 7 build

Postby fgygi » Tue Nov 25, 2014 8:07 am

Qbox 1.60.5 can be built on CentOS7 using the following steps:

1) Install the following packages using "yum install"
atlas atlas-devel xerces-c xerces-c-devel fftw fftw-devel openmpi openmpi-devel

2) Install scalapack-2.0.2 using the following script
Code: Select all
#!/bin/bash
# Install scalapack on a CentOS7 system
#
# It is assumed that the following packages are installed with yum
# blas, blas-devel
# lapack, lapack-devel
# openmpi, openmpi-devel

# choose where to install scalapack
SCALAPACKDIR=${HOME}/software/scalapack
mkdir -p $SCALAPACKDIR
cd $SCALAPACKDIR
wget http://www.netlib.org/scalapack/scalapack-2.0.2.tgz
tar zxf scalapack-2.0.2.tgz
cd scalapack-2.0.2
cp SLmake.inc.example SLmake.inc
# patch SLmake.inc to use OpenMPI MPI compilers
patch << EOF
--- SLmake.inc   2014-11-23 16:15:18.899263427 -0800
+++ ../SLmake.inc   2014-11-23 15:57:02.475807334 -0800
@@ -26,8 +26,8 @@
 #  The fortran and C compilers, loaders, and their flags
 #
 
-FC            = mpif90
-CC            = mpicc
+FC            = /usr/lib64/openmpi/bin/mpif90
+CC            = /usr/lib64/openmpi/bin/mpicc
 NOOPT         = -O0
 FCFLAGS       = -O3
 CCFLAGS       = -O3
EOF
# build
make


Build Qbox using the following include makefile (centos7.mk):
Code: Select all
#-------------------------------------------------------------------------------
#
# Copyright (c) 2008-2014 The Regents of the University of California
#
# This file is part of Qbox
#
# Qbox is distributed under the terms of the GNU General Public License
# as published by the Free Software Foundation, either version 2 of
# the License, or (at your option) any later version.
# See the file COPYING in the root directory of this distribution
# or <http://www.gnu.org/licenses/>.
#
#-------------------------------------------------------------------------------
#
#  centos7.mk
#
#-------------------------------------------------------------------------------
# The following packages must be installed using yum install:
#
# atlas atlas-devel fftw fftw-devel xerces-c xerces-c-devel
# openmpi openmpi-devel
#
# The scalapack library must be built using the install_scalapack.sh script
#

 SCALAPACKDIR = $(HOME)/software/scalapack/scalapack-2.0.2
 ATLASDIR=/usr/lib64/atlas

 PLTOBJECTS = readTSC.o

 CXX=/usr/lib64/openmpi/bin/mpicxx
 LD=$(CXX)

 PLTFLAGS += -DIA32 -D_LARGEFILE_SOURCE \
             -D_FILE_OFFSET_BITS=64 -DUSE_MPI -DSCALAPACK -DADD_ \
             -DAPP_NO_THREADS -DXML_USE_NO_THREADS -DUSE_XERCES \
             -DXERCESC_3 -DMPICH_IGNORE_CXX_SEEK

 PLTFLAGS += -DUSE_FFTW3
 PLTFLAGS += -DFFTWMEASURE
#PLTFLAGS += -DFFTW_TRANSPOSE
 PLTFLAGS += -DFFTW3_2D
 LIBS += -lfftw3

 CXXFLAGS= -g -O3 $(PLTFLAGS) $(DFLAGS)

 LIBPATH += -L$(XERCESCDIR)/lib \
            -L$(ATLASDIR) -L$(SCALAPACKDIR) -L/usr/lib64

 LIBS += -lxerces-c -lscalapack -lsatlas -lgfortran

 LDFLAGS = $(LIBPATH) $(LIBS)

#-------------------------------------------------------------------------------
fgygi
Site Admin
 
Posts: 119
Joined: Tue Jun 17, 2008 7:03 pm

Re: Centos 7 build

Postby fgygi » Sun May 03, 2015 7:12 am

The scalapack library can also be installed using:
Code: Select all
yum install scalapack-common scalapack-openmpi scalapack-openmpi-devel scalapack-openmpi-static
fgygi
Site Admin
 
Posts: 119
Joined: Tue Jun 17, 2008 7:03 pm

Re: Centos 7 build

Postby fgygi » Mon Oct 24, 2016 4:43 am

The scalapack packages are provided by the EPEL repository. The following steps may be required before invoking yum to install scalapack:
Code: Select all
# wget http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-8.noarch.rpm
# rpm -ivh epel-release-7-8.noarch.rpm
fgygi
Site Admin
 
Posts: 119
Joined: Tue Jun 17, 2008 7:03 pm


Return to Qbox Installation

cron