new OpenFOAM June 2017 release: OpenFOAM-v1706 (#4652)

- renamed develop version from 'plus' to 'develop'

- patches now prefixed by corresponding OpenFOAM version number.
  This makes it easier to sort and see what old/junk exists.

- remove MPI_BUFFER_SIZEk env variable (for all openfoam variants).
  The OpenFOAM shell setup addresses this and there is no reason
  to pollute the module environment at this stage.
This commit is contained in:
Mark Olesen 2017-07-03 23:54:50 +01:00 committed by Adam J. Stewart
parent 245eee7a56
commit 76b9563dc3
14 changed files with 26 additions and 22 deletions

View File

@ -143,7 +143,6 @@ def setup_environment(self, spack_env, run_env):
run_env.set('WM_PROJECT_DIR', self.projectdir)
for d in ['wmake', self.archbin]: # bin already added automatically
run_env.prepend_path('PATH', join_path(self.projectdir, d))
run_env.set('MPI_BUFFER_SIZE', "20000000")
def setup_dependent_environment(self, spack_env, run_env, dependent_spec):
"""Provide location of the OpenFOAM project.

View File

@ -54,6 +54,9 @@
# - Combining +zoltan with +int64 has not been tested, but probably won't work.
# - Combining +mgridgen with +int64 or +float32 probably won't work.
#
# The spack 'develop' version of openfoam-com retains the upstream
# WM_PROJECT_VERSION=plus naming internally.
#
##############################################################################
from spack import *
from spack.environment import *
@ -258,12 +261,14 @@ class OpenfoamCom(Package):
"""
homepage = "http://www.openfoam.com/"
baseurl = "https://sourceforge.net/projects/openfoamplus/files"
baseurl = "https://sourceforge.net/projects/openfoamplus/files/"
gitrepo = "https://develop.openfoam.com/Development/OpenFOAM-plus.git"
version('1706', '630d30770f7b54d6809efbf94b7d7c8f',
url=baseurl + 'v1706/OpenFOAM-v1706.tgz')
version('1612', 'ca02c491369150ab127cbb88ec60fbdf',
url=baseurl + '/v1612+/OpenFOAM-v1612+.tgz')
version('plus', branch='develop', # Note: needs user credentials
git='https://develop.openfoam.com/Development/OpenFOAM-plus.git')
url=baseurl + 'v1612+/OpenFOAM-v1612+.tgz')
version('develop', branch='develop', git=gitrepo) # Needs credentials
variant('int64', default=False,
description='Compile with 64-bit label')
@ -309,27 +314,29 @@ class OpenfoamCom(Package):
# Workaround: use preferred variants "+plugins +qt" in
# ~/.spack/packages.yaml
# 1706 ok with newer paraview but avoid pv-5.2, pv-5.3 readers
depends_on('paraview@5.4:', when='@1706:+paraview')
# 1612 plugins need older paraview
# The native reader in paraview 5.2 is broken, so start after that
depends_on('paraview@:5.0.1', when='@1612+paraview')
depends_on('paraview@5.3:', when='@1706:+paraview')
depends_on('paraview@5.3:', when='@plus+paraview')
# General patches
common = ['spack-Allwmake', 'README-spack']
assets = []
# Version-specific patches
patch('openfoam-bin-1612.patch', when='@1612')
patch('openfoam-etc-1612.patch', when='@1612')
patch('openfoam-site-1612.patch', when='@1612')
patch('openfoam-mpi-1612.patch', when='@1612')
patch('openfoam-build-1612.patch', when='@1612')
patch('mgridgen-lib-1612.patch', when='@1612')
patch('scotch-metis-lib-1612.patch', when='@1612')
patch('zoltan-lib-1612.patch', when='@1612')
patch('1612-bin.patch', when='@1612')
patch('1612-build.patch', when='@1612')
patch('1612-etc.patch', when='@1612')
patch('1612-site.patch', when='@1612')
patch('1612-mpi.patch', when='@1612')
patch('1612-mgridgen-lib.patch', when='@1612')
patch('1612-scotch-metis-lib.patch', when='@1612')
patch('1612-zoltan-lib.patch', when='@1612')
patch('openfoam-site-plus.patch', when='@plus')
# This patch is reasonably version-invariant
# 1) default site directly under WM_PROJECT_DIR
# 2) no FOAM_EXT_LIBBIN required
patch('openfoam-site.patch', when='@1706:')
# Some user config settings
# default: 'compile-option': 'RpathOpt',
@ -349,7 +356,7 @@ class OpenfoamCom(Package):
etc_config = {}
phases = ['configure', 'build', 'install']
build_script = './spack-Allwmake' # <- Added by patch() method.
build_script = './spack-Allwmake' # From patch() method.
#
# - End of definitions / setup -
@ -360,7 +367,6 @@ def setup_environment(self, spack_env, run_env):
run_env.set('WM_PROJECT_DIR', self.projectdir)
for d in ['wmake', self.archbin]: # bin already added automatically
run_env.prepend_path('PATH', join_path(self.projectdir, d))
run_env.set('MPI_BUFFER_SIZE', "20000000")
def setup_dependent_environment(self, spack_env, run_env, dependent_spec):
"""Provide location of the OpenFOAM project.

View File

@ -103,8 +103,8 @@ class OpenfoamOrg(Package):
assets = ['bin/foamEtcFile']
# Version-specific patches
patch('openfoam-etc-41.patch', when='@4.1')
patch('openfoam-site-41.patch', when='@4.1')
patch('41-etc.patch', when='@4.1')
patch('41-site.patch', when='@4.1')
# Some user config settings
config = {
@ -134,7 +134,6 @@ def setup_environment(self, spack_env, run_env):
run_env.set('WM_PROJECT_DIR', self.projectdir)
for d in ['wmake', self.archbin]: # bin already added automatically
run_env.prepend_path('PATH', join_path(self.projectdir, d))
run_env.set('MPI_BUFFER_SIZE', "20000000")
def setup_dependent_environment(self, spack_env, run_env, dependent_spec):
"""Provide location of the OpenFOAM project.