Merge branch 'mplegendre-multi_pkgsrc_roots' into develop
- This moves var/spack/packages to var/spack/repos/builtin/packages. - Packages that did not exist in the source branch, or were changed in develop, were moved into var/spack/repos/builtin/packages as part of the integration. Conflicts: lib/spack/spack/test/unit_install.py var/spack/repos/builtin/packages/clang/package.py
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
--- a/ompi/mca/io/romio/romio/adio/ad_lustre/ad_lustre_rwcontig.c 2013-12-10 12:05:44.806417000 -0800
|
||||
+++ b/ompi/mca/io/romio/romio/adio/ad_lustre/ad_lustre_rwcontig.c 2013-12-10 11:53:03.295622000 -0800
|
||||
@@ -8,7 +8,7 @@
|
||||
* Copyright (C) 2008 Sun Microsystems, Lustre group
|
||||
*/
|
||||
|
||||
-#define _XOPEN_SOURCE 600
|
||||
+//#define _XOPEN_SOURCE 600
|
||||
#include <stdlib.h>
|
||||
#include <malloc.h>
|
||||
#include "ad_lustre.h"
|
31
var/spack/repos/builtin/packages/openmpi/configure.patch
Normal file
31
var/spack/repos/builtin/packages/openmpi/configure.patch
Normal file
@@ -0,0 +1,31 @@
|
||||
This patch addresses <https://github.com/open-mpi/ompi/issues/576>.
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -301130,10 +301130,11 @@
|
||||
case ${prev}${p} in
|
||||
|
||||
-L* | -R* | -l*)
|
||||
- # Some compilers place space between "-{L,R}" and the path.
|
||||
+ # Some compilers place space between "-{L,R,l}" and the path.
|
||||
# Remove the space.
|
||||
if test $p = "-L" ||
|
||||
- test $p = "-R"; then
|
||||
+ test $p = "-R" ||
|
||||
+ test $p = "-l"; then
|
||||
prev=$p
|
||||
continue
|
||||
fi
|
||||
@@ -303036,10 +303037,11 @@
|
||||
case ${prev}${p} in
|
||||
|
||||
-L* | -R* | -l*)
|
||||
- # Some compilers place space between "-{L,R}" and the path.
|
||||
+ # Some compilers place space between "-{L,R,l}" and the path.
|
||||
# Remove the space.
|
||||
if test $p = "-L" ||
|
||||
- test $p = "-R"; then
|
||||
+ test $p = "-R" ||
|
||||
+ test $p = "-l"; then
|
||||
prev=$p
|
||||
continue
|
||||
fi
|
151
var/spack/repos/builtin/packages/openmpi/llnl-platforms.patch
Normal file
151
var/spack/repos/builtin/packages/openmpi/llnl-platforms.patch
Normal file
@@ -0,0 +1,151 @@
|
||||
diff -Nuar openmpi-1.6.5.orig/contrib/platform/llnl/optimized openmpi-1.6.5.llnl/contrib/platform/llnl/optimized
|
||||
--- openmpi-1.6.5.orig/contrib/platform/llnl/optimized 1969-12-31 16:00:00.000000000 -0800
|
||||
+++ openmpi-1.6.5.llnl/contrib/platform/llnl/optimized 2013-08-08 23:47:12.704029000 -0700
|
||||
@@ -0,0 +1,29 @@
|
||||
+enable_dlopen=no
|
||||
+enable_mem_debug=no
|
||||
+enable_mem_profile=no
|
||||
+enable_debug_symbols=no
|
||||
+enable_binaries=yes
|
||||
+enable_heterogeneous=no
|
||||
+enable_debug=no
|
||||
+enable_shared=yes
|
||||
+enable_static=yes
|
||||
+enable_memchecker=no
|
||||
+enable_ipv6=no
|
||||
+enable_mpi_f77=yes
|
||||
+enable_mpi_f90=yes
|
||||
+enable_mpi_cxx=yes
|
||||
+enable_mpi_cxx_seek=yes
|
||||
+enable_cxx_exceptions=no
|
||||
+enable_ft_thread=no
|
||||
+enable_per_user_config_files=no
|
||||
+enable_mca_no_build=carto,crs,filem,routed-linear,snapc,pml-dr,pml-crcp2,pml-crcpw,pml-v,pml-example,crcp,btl-tcp
|
||||
+enable_contrib_no_build=libnbc,vt
|
||||
+with_slurm=yes
|
||||
+with_pmi=yes
|
||||
+with_tm=no
|
||||
+with_openib=yes
|
||||
+with_psm=yes
|
||||
+with_devel_headers=yes
|
||||
+with_io_romio_flags=--with-file-system=ufs+nfs+lustre
|
||||
+with_memory_manager=ptmalloc2
|
||||
+with_valgrind=no
|
||||
diff -Nuar openmpi-1.6.5.orig/contrib/platform/llnl/optimized.conf openmpi-1.6.5.llnl/contrib/platform/llnl/optimized.conf
|
||||
--- openmpi-1.6.5.orig/contrib/platform/llnl/optimized.conf 1969-12-31 16:00:00.000000000 -0800
|
||||
+++ openmpi-1.6.5.llnl/contrib/platform/llnl/optimized.conf 2013-08-08 23:43:52.907553000 -0700
|
||||
@@ -0,0 +1,114 @@
|
||||
+#
|
||||
+# Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||||
+# University Research and Technology
|
||||
+# Corporation. All rights reserved.
|
||||
+# Copyright (c) 2004-2005 The University of Tennessee and The University
|
||||
+# of Tennessee Research Foundation. All rights
|
||||
+# reserved.
|
||||
+# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||||
+# University of Stuttgart. All rights reserved.
|
||||
+# Copyright (c) 2004-2005 The Regents of the University of California.
|
||||
+# All rights reserved.
|
||||
+# Copyright (c) 2006 Cisco Systems, Inc. All rights reserved.
|
||||
+# Copyright (c) 2011 Los Alamos National Security, LLC.
|
||||
+# All rights reserved.
|
||||
+# $COPYRIGHT$
|
||||
+#
|
||||
+# Additional copyrights may follow
|
||||
+#
|
||||
+# $HEADER$
|
||||
+#
|
||||
+
|
||||
+# This is the default system-wide MCA parameters defaults file.
|
||||
+# Specifically, the MCA parameter "mca_param_files" defaults to a
|
||||
+# value of
|
||||
+# "$HOME/.openmpi/mca-params.conf:$sysconf/openmpi-mca-params.conf"
|
||||
+# (this file is the latter of the two). So if the default value of
|
||||
+# mca_param_files is not changed, this file is used to set system-wide
|
||||
+# MCA parameters. This file can therefore be used to set system-wide
|
||||
+# default MCA parameters for all users. Of course, users can override
|
||||
+# these values if they want, but this file is an excellent location
|
||||
+# for setting system-specific MCA parameters for those users who don't
|
||||
+# know / care enough to investigate the proper values for them.
|
||||
+
|
||||
+# Note that this file is only applicable where it is visible (in a
|
||||
+# filesystem sense). Specifically, MPI processes each read this file
|
||||
+# during their startup to determine what default values for MCA
|
||||
+# parameters should be used. mpirun does not bundle up the values in
|
||||
+# this file from the node where it was run and send them to all nodes;
|
||||
+# the default value decisions are effectively distributed. Hence,
|
||||
+# these values are only applicable on nodes that "see" this file. If
|
||||
+# $sysconf is a directory on a local disk, it is likely that changes
|
||||
+# to this file will need to be propagated to other nodes. If $sysconf
|
||||
+# is a directory that is shared via a networked filesystem, changes to
|
||||
+# this file will be visible to all nodes that share this $sysconf.
|
||||
+
|
||||
+# The format is straightforward: one per line, mca_param_name =
|
||||
+# rvalue. Quoting is ignored (so if you use quotes or escape
|
||||
+# characters, they'll be included as part of the value). For example:
|
||||
+
|
||||
+# Disable run-time MPI parameter checking
|
||||
+# mpi_param_check = 0
|
||||
+
|
||||
+# Note that the value "~/" will be expanded to the current user's home
|
||||
+# directory. For example:
|
||||
+
|
||||
+# Change component loading path
|
||||
+# component_path = /usr/local/lib/openmpi:~/my_openmpi_components
|
||||
+
|
||||
+# See "ompi_info --param all all" for a full listing of Open MPI MCA
|
||||
+# parameters available and their default values.
|
||||
+#
|
||||
+
|
||||
+# Basic behavior to smooth startup
|
||||
+mca_component_show_load_errors = 0
|
||||
+orte_abort_timeout = 10
|
||||
+opal_set_max_sys_limits = 1
|
||||
+orte_report_launch_progress = 1
|
||||
+
|
||||
+# Define timeout for daemons to report back during launch
|
||||
+orte_startup_timeout = 10000
|
||||
+
|
||||
+## Protect the shared file systems
|
||||
+orte_no_session_dirs = /p,/usr/local,/usr/global,/nfs/tmp1,/nfs/tmp2
|
||||
+orte_tmpdir_base = /tmp
|
||||
+
|
||||
+## Require an allocation to run - protects the frontend
|
||||
+## from inadvertent job executions
|
||||
+orte_allocation_required = 1
|
||||
+
|
||||
+## MPI behavior
|
||||
+## Do NOT specify mpi_leave_pinned so system
|
||||
+## can figure out for itself whether or not
|
||||
+## it is supported and usable
|
||||
+orte_notifier = syslog
|
||||
+
|
||||
+## Add the interface for out-of-band communication
|
||||
+## and set it up
|
||||
+oob_tcp_if_include=ib0
|
||||
+oob_tcp_peer_retries = 1000
|
||||
+oob_tcp_disable_family = IPv6
|
||||
+oob_tcp_listen_mode = listen_thread
|
||||
+oob_tcp_sndbuf = 32768
|
||||
+oob_tcp_rcvbuf = 32768
|
||||
+
|
||||
+## Define the MPI interconnects
|
||||
+btl = sm,openib,self
|
||||
+
|
||||
+## We are using the PSM MTL by default
|
||||
+## There can only be one!
|
||||
+pml = cm
|
||||
+
|
||||
+## Setup OpenIB - just in case
|
||||
+btl_openib_want_fork_support = 0
|
||||
+btl_openib_cpc_include = oob
|
||||
+btl_openib_receive_queues = S,4096,1024:S,12288,512:S,65536,512
|
||||
+
|
||||
+## Enable cpu affinity
|
||||
+opal_paffinity_alone = 1
|
||||
+
|
||||
+## Setup MPI options
|
||||
+mpi_show_handle_leaks = 0
|
||||
+mpi_warn_on_fork = 1
|
||||
+mpi_abort_print_stack = 0
|
||||
+
|
136
var/spack/repos/builtin/packages/openmpi/package.py
Normal file
136
var/spack/repos/builtin/packages/openmpi/package.py
Normal file
@@ -0,0 +1,136 @@
|
||||
import os
|
||||
|
||||
from spack import *
|
||||
|
||||
|
||||
class Openmpi(Package):
|
||||
"""Open MPI is a project combining technologies and resources from
|
||||
several other projects (FT-MPI, LA-MPI, LAM/MPI, and PACX-MPI)
|
||||
in order to build the best MPI library available. A completely
|
||||
new MPI-2 compliant implementation, Open MPI offers advantages
|
||||
for system and software vendors, application developers and
|
||||
computer science researchers.
|
||||
"""
|
||||
|
||||
homepage = "http://www.open-mpi.org"
|
||||
url = "http://www.open-mpi.org/software/ompi/v1.10/downloads/openmpi-1.10.1.tar.bz2"
|
||||
list_url = "http://www.open-mpi.org/software/ompi/"
|
||||
list_depth = 3
|
||||
|
||||
version('1.10.1', 'f0fcd77ed345b7eafb431968124ba16e')
|
||||
version('1.10.0', '280cf952de68369cebaca886c5ce0304')
|
||||
version('1.8.8', '0dab8e602372da1425e9242ae37faf8c')
|
||||
version('1.6.5', '03aed2a4aa4d0b27196962a2a65fc475')
|
||||
|
||||
patch('ad_lustre_rwcontig_open_source.patch', when="@1.6.5")
|
||||
patch('llnl-platforms.patch', when="@1.6.5")
|
||||
patch('configure.patch', when="@1.10.0:")
|
||||
|
||||
variant('psm', default=False, description='Build support for the PSM library.')
|
||||
variant('verbs', default=False, description='Build support for OpenFabrics verbs.')
|
||||
|
||||
provides('mpi@:2.2', when='@1.6.5')
|
||||
provides('mpi@:3.0', when='@1.7.5:')
|
||||
|
||||
|
||||
depends_on('hwloc')
|
||||
|
||||
|
||||
def url_for_version(self, version):
|
||||
return "http://www.open-mpi.org/software/ompi/v%s/downloads/openmpi-%s.tar.bz2" % (version.up_to(2), version)
|
||||
|
||||
|
||||
def setup_dependent_environment(self, module, spec, dep_spec):
|
||||
"""For dependencies, make mpicc's use spack wrapper."""
|
||||
os.environ['OMPI_CC'] = 'cc'
|
||||
os.environ['OMPI_CXX'] = 'c++'
|
||||
os.environ['OMPI_FC'] = 'f90'
|
||||
os.environ['OMPI_F77'] = 'f77'
|
||||
|
||||
|
||||
def install(self, spec, prefix):
|
||||
config_args = ["--prefix=%s" % prefix,
|
||||
"--with-hwloc=%s" % spec['hwloc'].prefix,
|
||||
"--with-tm", # necessary for Torque support
|
||||
"--enable-shared",
|
||||
"--enable-static"]
|
||||
|
||||
# Variants
|
||||
if '+psm' in spec:
|
||||
config_args.append("--with-psm")
|
||||
|
||||
if '+verbs' in spec:
|
||||
# Up through version 1.6, this option was previously named --with-openib
|
||||
if spec.satisfies('@:1.6'):
|
||||
config_args.append("--with-openib")
|
||||
# In version 1.7, it was renamed to be --with-verbs
|
||||
elif spec.satisfies('@1.7:'):
|
||||
config_args.append("--with-verbs")
|
||||
|
||||
# TODO: use variants for this, e.g. +lanl, +llnl, etc.
|
||||
# use this for LANL builds, but for LLNL builds, we need:
|
||||
# "--with-platform=contrib/platform/llnl/optimized"
|
||||
if self.version == ver("1.6.5") and '+lanl' in spec:
|
||||
config_args.append("--with-platform=contrib/platform/lanl/tlcc2/optimized-nopanasas")
|
||||
|
||||
# TODO: Spack should make it so that you can't actually find
|
||||
# these compilers if they're "disabled" for the current
|
||||
# compiler configuration.
|
||||
if not self.compiler.f77 and not self.compiler.fc:
|
||||
config_args.append("--enable-mpi-fortran=no")
|
||||
|
||||
configure(*config_args)
|
||||
make()
|
||||
make("install")
|
||||
|
||||
self.filter_compilers()
|
||||
|
||||
|
||||
def filter_compilers(self):
|
||||
"""Run after install to make the MPI compilers use the
|
||||
compilers that Spack built the package with.
|
||||
|
||||
If this isn't done, they'll have CC, CXX and FC set
|
||||
to Spack's generic cc, c++ and f90. We want them to
|
||||
be bound to whatever compiler they were built with.
|
||||
"""
|
||||
kwargs = { 'ignore_absent' : True, 'backup' : False, 'string' : False }
|
||||
dir = os.path.join(self.prefix, 'share/openmpi/')
|
||||
|
||||
cc_wrappers = ['mpicc-vt-wrapper-data.txt', 'mpicc-wrapper-data.txt',
|
||||
'ortecc-wrapper-data.txt', 'shmemcc-wrapper-data.txt']
|
||||
|
||||
cxx_wrappers = ['mpic++-vt-wrapper-data.txt', 'mpic++-wrapper-data.txt',
|
||||
'ortec++-wrapper-data.txt']
|
||||
|
||||
fc_wrappers = ['mpifort-vt-wrapper-data.txt',
|
||||
'mpifort-wrapper-data.txt', 'shmemfort-wrapper-data.txt']
|
||||
|
||||
for wrapper in cc_wrappers:
|
||||
filter_file('compiler=.*', 'compiler=%s' % self.compiler.cc,
|
||||
os.path.join(dir, wrapper), **kwargs)
|
||||
|
||||
for wrapper in cxx_wrappers:
|
||||
filter_file('compiler=.*', 'compiler=%s' % self.compiler.cxx,
|
||||
os.path.join(dir, wrapper), **kwargs)
|
||||
|
||||
for wrapper in fc_wrappers:
|
||||
filter_file('compiler=.*', 'compiler=%s' % self.compiler.fc,
|
||||
os.path.join(dir, wrapper), **kwargs)
|
||||
|
||||
# These are symlinks in newer versions, so check that here
|
||||
f77_wrappers = ['mpif77-vt-wrapper-data.txt', 'mpif77-wrapper-data.txt']
|
||||
f90_wrappers = ['mpif90-vt-wrapper-data.txt', 'mpif90-wrapper-data.txt']
|
||||
|
||||
for wrapper in f77_wrappers:
|
||||
path = os.path.join(dir, wrapper)
|
||||
if not os.path.islink(path):
|
||||
filter_file('compiler=.*', 'compiler=%s' % self.compiler.f77,
|
||||
path, **kwargs)
|
||||
for wrapper in f90_wrappers:
|
||||
path = os.path.join(dir, wrapper)
|
||||
if not os.path.islink(path):
|
||||
filter_file('compiler=.*', 'compiler=%s' % self.compiler.fc,
|
||||
path, **kwargs)
|
||||
|
||||
|
Reference in New Issue
Block a user