1#!/usr/bin/python 2 3import os 4petsc_hash_pkgs=os.path.join(os.getenv('HOME'),'petsc-hash-pkgs') 5 6import platform 7if platform.node() == 'instinct': 8 opts = [ 9 '--with-mpi-dir=/home/users/balay/soft/mpich-4.0', 10 '--with-blaslapack-dir=/home/users/balay/soft/fblaslapack', 11 '--with-make-np=24', 12 '--with-make-test-np=8', 13 ] 14else: 15 opts = [ 16 'LDFLAGS=-L/opt/rh/devtoolset-7/root/usr/lib/gcc/x86_64-redhat-linux/7/lib -lquadmath', 17 '--with-mpi-dir=/scratch/soft/mpich', 18 '--download-fblaslapack', 19 '--download-hypre', 20 ] 21 22if __name__ == '__main__': 23 import sys 24 import os 25 sys.path.insert(0, os.path.abspath('config')) 26 import configure 27 configure_options = opts + [ 28 '--package-prefix-hash='+petsc_hash_pkgs, 29 '--download-cmake', 30 'COPTFLAGS=-g -O', 31 'FOPTFLAGS=-g -O', 32 'CXXOPTFLAGS=-g -O', 33 'HIPOPTFLAGS=-g -O', 34 '--with-cuda=0', 35 '--with-hip=1', 36 '--with-hipc=/opt/rocm/bin/hipcc', 37 '--with-hip-dir=/opt/rocm', 38 '--with-precision=double', 39 '--with-clanguage=c', 40 '--download-kokkos', 41 '--download-kokkos-kernels', 42 '--download-hypre-configure-arguments=--enable-unified-memory', 43 '--download-magma', 44 '--with-magma-fortran-bindings=0', 45 ] 46 47 configure.petsc_configure(configure_options) 48