Skip to content

Instantly share code, notes, and snippets.

@nocollier
Created October 22, 2019 16:20
Show Gist options
  • Save nocollier/6c7281341433ed344d90693117696478 to your computer and use it in GitHub Desktop.
Save nocollier/6c7281341433ed344d90693117696478 to your computer and use it in GitHub Desktop.
My commonly used options for configuring PETSc
import sys
import os
sys.path.insert(0, os.path.abspath('config'))
import configure
mode = 'debug'
if len(sys.argv) == 2: mode = sys.argv[1]
configure_options = [
'--download-exodusii',
'--download-hdf5',
'--download-netcdf',
'--download-zlib',
'--download-pnetcdf',
]
if mode == "opt":
configure_options += [
'--with-debugging=0',
'COPTFLAGS=-O3',
'CXXOPTFLAGS=-O3',
'FOPTFLAGS=-O3',
]
configure_options += [
'PETSC_ARCH=arch-linux2-c-%s' % mode,
]
configure.petsc_configure(configure_options)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment