Spack updates to three Krell packages (#4765)
* Update the krell institute products to use the latest features of spack for building on cluster platforms. * Address travis error messages and resubmit the pull request. * Update the contents of openspeedshop package.py so it passes the flake8 tests. * Fix flake8 error-whitespack issue in mrnet package.py file. * Add updates based on spack reviewer feedback. * More fixes based on comments from reviewers. Switch using extend to using append, remove additional setting of PATH and LD_LIBRARY_PATH that should not be required due to RPATH. * More review related changes. Update MPIOption.append lines and take out xercesc references. * Create a base options function for common openspeedshop base cmake options to reduce redundencies. * Add libxml2+python depends on to get around issues with the libxml2 package file. * Using boost over 1.60.0 causes compile errors. This is a known boost bug. Also, dyninst-9.2.0 is set to be the vesrion of dyninst to use with OSS, as of now. The newer version fails to build. * Fix bad syntax in specifying the boost version range. * Update the version numbers for the krell institute components and tools: cbtf and openspeedshop. * Do not build glib for qt3, it is not needed and causes build problems at this time anyway. * A fix was added for setting LD_LIBRARY_PATH in the qt3 build, but if LD_LIBRARY_PATH is not set the qt build fails. So so check and set LD_LIBRARY_PATH if not set, update if it is set. * Update the fix for qt3 build by setting LD_LIBRARY_PATH instead of checking for whether it is set or not per Adams comment that spack clears LD_LIBRARY_PATH. * A fix was added for setting LD_LIBRARY_PATH in the qt3 build, but if LD_LIBRARY_PATH is not set the qt build fails. So so check and set LD_LIBRARY_PATH if not set, update if it is set. * Trim comments to fit more concisely. * Fix tabs versus spaces and swap if and else clause check from a negative to a positive check. * Fix issues with the cbtf-argonavis build, update to use dyninst-9.3.2, fixes to openspeedshop package build. * Fix issues with the cbtf-argonavis package.py files related to comments. * Add changes for changing the krell packages from Package to CMakePackage. * Add better changes for changing the krell packages from Package to CMakePackage. * Add more modifications for changing the krell packages from Package to CMakePackage. * Add additional modifications for changing the krell packages from Package to CMakePackage and fixing Travis erros * Fix new travis errors. * Fix new travis errors. * Add more changes for PR 4765. * Add more refinements to the conversion from Package to CMakePackage. * Fix new travis errors. * Add dependencies for MPI to be passed to cbtf-krell, so it can build the MPI collectors requested by the builder of openspeedshop. * Remove extra unnecessary routine to adjust build arguments. Fix if-else clause issue. * Fix more flake issues caused by last changes.
This commit is contained in:
parent
5f0e1514ac
commit
5173a8bef9
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
|
||||
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
|
||||
# Produced at the Lawrence Livermore National Laboratory.
|
||||
#
|
||||
# This file is part of Spack.
|
||||
@ -23,7 +23,7 @@
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
##############################################################################
|
||||
##########################################################################
|
||||
# Copyright (c) 2015-2016 Krell Institute. All Rights Reserved.
|
||||
# Copyright (c) 2015-2017 Krell Institute. All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU General Public License as published by the Free Software
|
||||
@ -43,17 +43,13 @@
|
||||
from spack import *
|
||||
|
||||
|
||||
class CbtfArgonavis(Package):
|
||||
class CbtfArgonavis(CMakePackage):
|
||||
"""CBTF Argo Navis project contains the CUDA collector and supporting
|
||||
libraries that was done as a result of a DOE SBIR grant.
|
||||
|
||||
"""
|
||||
homepage = "http://sourceforge.net/p/cbtf/wiki/Home/"
|
||||
|
||||
# Mirror access template example
|
||||
# url = "file:/home/jeg/OpenSpeedShop_ROOT/SOURCES/cbtf-argonavis-1.6.tar.gz"
|
||||
# version('1.6', '0fafa0008478405c2c2319450f174ed4')
|
||||
|
||||
version('1.8', branch='master',
|
||||
git='https://github.com/OpenSpeedShop/cbtf-argonavis.git')
|
||||
|
||||
@ -67,73 +63,30 @@ class CbtfArgonavis(Package):
|
||||
|
||||
parallel = False
|
||||
|
||||
def adjustBuildTypeParams_cmakeOptions(self, spec, cmakeOptions):
|
||||
# Sets build type parameters into cmakeOptions the options that will
|
||||
# enable the cbtf-krell built type settings
|
||||
build_directory = 'build_cbtf_argonavis'
|
||||
|
||||
def build_type(self):
|
||||
return 'None'
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
compile_flags = "-O2 -g"
|
||||
BuildTypeOptions = []
|
||||
|
||||
# Set CMAKE_BUILD_TYPE to what cbtf-krell wants it to be, not the
|
||||
# stdcmakeargs
|
||||
for word in cmakeOptions[:]:
|
||||
if word.startswith('-DCMAKE_BUILD_TYPE'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_CXX_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_C_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_VERBOSE_MAKEFILE'):
|
||||
cmakeOptions.remove(word)
|
||||
BuildTypeOptions.extend([
|
||||
'-DCMAKE_VERBOSE_MAKEFILE=ON',
|
||||
'-DCMAKE_BUILD_TYPE=None',
|
||||
cmake_args = [
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags
|
||||
])
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DCUDA_DIR=%s' % spec['cuda'].prefix,
|
||||
'-DCUDA_INSTALL_PATH=%s' % spec['cuda'].prefix,
|
||||
'-DCUDA_TOOLKIT_ROOT_DIR=%s' % spec['cuda'].prefix,
|
||||
'-DCUPTI_DIR=%s' % spec['cuda'].prefix.extras.CUPTI,
|
||||
'-DCUPTI_ROOT=%s' % spec['cuda'].prefix.extras.CUPTI,
|
||||
'-DPAPI_ROOT=%s' % spec['papi'].prefix,
|
||||
'-DCBTF_DIR=%s' % spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s' % spec['cbtf-krell'].prefix,
|
||||
'-DBOOST_ROOT=%s' % spec['boost'].prefix,
|
||||
'-DBoost_DIR=%s' % spec['boost'].prefix,
|
||||
'-DBOOST_LIBRARYDIR=%s' % spec['boost'].prefix.lib,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DBoost_NO_SYSTEM_PATHS=ON']
|
||||
|
||||
cmakeOptions.extend(BuildTypeOptions)
|
||||
|
||||
def install(self, spec, prefix):
|
||||
|
||||
# Look for package installation information in the cbtf and cbtf-krell
|
||||
# prefixes
|
||||
cmake_prefix_path = join_path(
|
||||
spec['cbtf'].prefix) + ':' + join_path(spec['cbtf-krell'].prefix)
|
||||
|
||||
with working_dir('CUDA'):
|
||||
with working_dir('build', create=True):
|
||||
|
||||
cmakeOptions = []
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s' % prefix,
|
||||
'-DCMAKE_PREFIX_PATH=%s' % cmake_prefix_path,
|
||||
'-DCUDA_DIR=%s' % spec['cuda'].prefix,
|
||||
'-DCUDA_INSTALL_PATH=%s' % spec['cuda'].prefix,
|
||||
'-DCUDA_TOOLKIT_ROOT_DIR=%s' % spec['cuda'].prefix,
|
||||
'-DCUPTI_DIR=%s' % join_path(
|
||||
spec['cuda'].prefix + '/extras/CUPTI'),
|
||||
'-DCUPTI_ROOT=%s' % join_path(
|
||||
spec['cuda'].prefix + '/extras/CUPTI'),
|
||||
'-DPAPI_ROOT=%s' % spec['papi'].prefix,
|
||||
'-DCBTF_DIR=%s' % spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s' % spec['cbtf-krell'].prefix,
|
||||
'-DBOOST_ROOT=%s' % spec['boost'].prefix,
|
||||
'-DBoost_DIR=%s' % spec['boost'].prefix,
|
||||
'-DBOOST_LIBRARYDIR=%s' % spec['boost'].prefix.lib,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DBoost_NO_SYSTEM_PATHS=ON'])
|
||||
|
||||
# Add in the standard cmake arguments
|
||||
cmakeOptions.extend(std_cmake_args)
|
||||
|
||||
# Adjust the standard cmake arguments to what we want the build
|
||||
# type, etc to be
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
# Invoke cmake
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
return cmake_args
|
||||
|
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
|
||||
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
|
||||
# Produced at the Lawrence Livermore National Laboratory.
|
||||
#
|
||||
# This file is part of Spack.
|
||||
@ -23,7 +23,7 @@
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
##############################################################################
|
||||
##########################################################################
|
||||
# Copyright (c) 2015-2016 Krell Institute. All Rights Reserved.
|
||||
# Copyright (c) 2015-2017 Krell Institute. All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU General Public License as published by the Free Software
|
||||
@ -43,7 +43,7 @@
|
||||
from spack import *
|
||||
|
||||
|
||||
class CbtfKrell(Package):
|
||||
class CbtfKrell(CMakePackage):
|
||||
"""CBTF Krell project contains the Krell Institute contributions to the
|
||||
CBTF project. These contributions include many performance data
|
||||
collectors and support libraries as well as some example tools
|
||||
@ -52,10 +52,6 @@ class CbtfKrell(Package):
|
||||
"""
|
||||
homepage = "http://sourceforge.net/p/cbtf/wiki/Home/"
|
||||
|
||||
# optional mirror access template
|
||||
# url = "file:/home/jeg/cbtf-krell-1.6.tar.gz"
|
||||
# version('1.6', 'edeb61cd488f16e7b124f77db9ce762d')
|
||||
|
||||
version('1.8', branch='master',
|
||||
git='https://github.com/OpenSpeedShop/cbtf-krell.git')
|
||||
|
||||
@ -81,7 +77,7 @@ class CbtfKrell(Package):
|
||||
|
||||
# collectionTool
|
||||
depends_on("boost@1.50.0:1.59.0")
|
||||
depends_on("dyninst@9.2.0")
|
||||
depends_on("dyninst@9.3.2")
|
||||
depends_on("mrnet@5.0.1:+lwthreads")
|
||||
|
||||
depends_on("xerces-c@3.1.1:")
|
||||
@ -104,31 +100,7 @@ class CbtfKrell(Package):
|
||||
|
||||
parallel = False
|
||||
|
||||
def adjustBuildTypeParams_cmakeOptions(self, spec, cmakeOptions):
|
||||
# Sets build type parameters into cmakeOptions the options that will
|
||||
# enable the cbtf-krell built type settings
|
||||
|
||||
compile_flags = "-O2 -g"
|
||||
BuildTypeOptions = []
|
||||
# Set CMAKE_BUILD_TYPE to what cbtf-krell wants it to be, not the
|
||||
# stdcmakeargs
|
||||
for word in cmakeOptions[:]:
|
||||
if word.startswith('-DCMAKE_BUILD_TYPE'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_CXX_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_C_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_VERBOSE_MAKEFILE'):
|
||||
cmakeOptions.remove(word)
|
||||
BuildTypeOptions.extend([
|
||||
'-DCMAKE_VERBOSE_MAKEFILE=ON',
|
||||
'-DCMAKE_BUILD_TYPE=None',
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags
|
||||
])
|
||||
|
||||
cmakeOptions.extend(BuildTypeOptions)
|
||||
build_directory = 'build_cbtf_krell'
|
||||
|
||||
def set_mpi_cmakeOptions(self, spec, cmakeOptions):
|
||||
# Appends to cmakeOptions the options that will enable the appropriate
|
||||
@ -157,135 +129,30 @@ def set_mpi_cmakeOptions(self, spec, cmakeOptions):
|
||||
|
||||
cmakeOptions.extend(MPIOptions)
|
||||
|
||||
def install(self, spec, prefix):
|
||||
def build_type(self):
|
||||
return 'None'
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
|
||||
compile_flags = "-O2 -g"
|
||||
|
||||
# Add in paths for finding package config files that tell us
|
||||
# where to find these packages
|
||||
# cmake_prefix_path = \
|
||||
# join_path(spec['cbtf'].prefix) + ':' + \
|
||||
# join_path(spec['dyninst'].prefix)
|
||||
# '-DCMAKE_PREFIX_PATH=%s' % cmake_prefix_path
|
||||
cmake_args = [
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DCBTF_DIR=%s' % spec['cbtf'].prefix,
|
||||
'-DBINUTILS_DIR=%s' % spec['binutils'].prefix,
|
||||
'-DLIBMONITOR_DIR=%s' % spec['libmonitor'].prefix,
|
||||
'-DLIBUNWIND_DIR=%s' % spec['libunwind'].prefix,
|
||||
'-DPAPI_DIR=%s' % spec['papi'].prefix,
|
||||
'-DBOOST_DIR=%s' % spec['boost'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DDYNINST_DIR=%s' % spec['dyninst'].prefix,
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix]
|
||||
|
||||
# Build cbtf-krell with cmake
|
||||
with working_dir('build_cbtf_krell', create=True):
|
||||
cmakeOptions = []
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s' % prefix,
|
||||
'-DCBTF_DIR=%s' % spec['cbtf'].prefix,
|
||||
'-DBINUTILS_DIR=%s' % spec['binutils'].prefix,
|
||||
'-DLIBMONITOR_DIR=%s' % spec['libmonitor'].prefix,
|
||||
'-DLIBUNWIND_DIR=%s' % spec['libunwind'].prefix,
|
||||
'-DPAPI_DIR=%s' % spec['papi'].prefix,
|
||||
'-DBOOST_DIR=%s' % spec['boost'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DDYNINST_DIR=%s' % spec['dyninst'].prefix,
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix])
|
||||
# Add any MPI implementations coming from variant settings
|
||||
self.set_mpi_cmakeOptions(spec, cmake_args)
|
||||
|
||||
# Add any MPI implementations coming from variant settings
|
||||
self.set_mpi_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
# Add in the standard cmake arguments
|
||||
cmakeOptions.extend(std_cmake_args)
|
||||
|
||||
# Adjust the standard cmake arguments to what we want the build
|
||||
# type, etc to be
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
# Invoke cmake
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
|
||||
# if '+cray' in spec:
|
||||
# if 'cray' in self.spec.architecture:
|
||||
# if '+runtime' in spec:
|
||||
# with working_dir('build_cbtf_cray_runtime', create=True):
|
||||
# python_vers='%d.%d' % spec['python'].version[:2]
|
||||
# cmake .. \
|
||||
# -DCMAKE_BUILD_TYPE=Debug \
|
||||
# -DTARGET_OS="cray" \
|
||||
# -DRUNTIME_ONLY="true" \
|
||||
# -DCMAKE_INSTALL_PREFIX=${CBTF_KRELL_PREFIX} \
|
||||
# -DCMAKE_PREFIX_PATH=${CBTF_ROOT} \
|
||||
# -DCBTF_DIR=${CBTF_ROOT} \
|
||||
# -DBOOST_ROOT=${BOOST_INSTALL_PREFIX} \
|
||||
# -DXERCESC_DIR=${XERCESC_INSTALL_PREFIX} \
|
||||
# -DBINUTILS_DIR=${KRELL_ROOT} \
|
||||
# -DLIBMONITOR_DIR=${KRELL_ROOT_COMPUTE} \
|
||||
# -DLIBUNWIND_DIR=${KRELL_ROOT_COMPUTE} \
|
||||
# -DPAPI_DIR=${PAPI_ROOT} \
|
||||
# -DDYNINST_DIR=${DYNINST_CN_ROOT} \
|
||||
# -DMRNET_DIR=${MRNET_INSTALL_PREFIX} \
|
||||
# -DMPICH2_DIR=/opt/cray/mpt/7.0.1/gni/mpich2-gnu/48
|
||||
# else:
|
||||
# with working_dir('build_cbtf_cray_frontend', create=True):
|
||||
# python_vers='%d.%d' % spec['python'].version[:2]
|
||||
# cmake .. \
|
||||
# -DCMAKE_BUILD_TYPE=Debug \
|
||||
# -DCMAKE_INSTALL_PREFIX=${CBTF_KRELL_PREFIX} \
|
||||
# -DCMAKE_PREFIX_PATH=${CBTF_ROOT} \
|
||||
# -DCBTF_DIR=${CBTF_ROOT} \
|
||||
# -DRUNTIME_TARGET_OS="cray" \
|
||||
# -DCBTF_KRELL_CN_RUNTIME_DIR=${CBTF_KRELL_CN_RUNTIME_ROOT} \
|
||||
# -DCBTF_CN_RUNTIME_DIR=${CBTF_CN_RUNTIME_ROOT} \
|
||||
# -DLIBMONITOR_CN_RUNTIME_DIR=${LIBMONITOR_CN_ROOT} \
|
||||
# -DLIBUNWIND_CN_RUNTIME_DIR=${LIBUNWIND_CN_ROOT} \
|
||||
# -DPAPI_CN_RUNTIME_DIR=${PAPI_CN_ROOT} \
|
||||
# -DXERCESC_CN_RUNTIME_DIR=/${XERCESC_CN_ROOT} \
|
||||
# -DMRNET_CN_RUNTIME_DIR=${MRNET_CN_ROOT} \
|
||||
# -DBOOST_CN_RUNTIME_DIR=${BOOST_CN_ROOT} \
|
||||
# -DDYNINST_CN_RUNTIME_DIR=${DYNINST_CN_ROOT} \
|
||||
# -DBOOST_ROOT=/${KRELL_ROOT} \
|
||||
# -DXERCESC_DIR=/${KRELL_ROOT} \
|
||||
# -DBINUTILS_DIR=/${KRELL_ROOT} \
|
||||
# -DLIBMONITOR_DIR=${KRELL_ROOT} \
|
||||
# -DLIBUNWIND_DIR=${KRELL_ROOT} \
|
||||
# -DPAPI_DIR=${PAPI_ROOT} \
|
||||
# -DDYNINST_DIR=${KRELL_ROOT} \
|
||||
# -DMRNET_DIR=${KRELL_ROOT} \
|
||||
# -DMPICH2_DIR=/opt/cray/mpt/7.0.1/gni/mpich2-gnu/48
|
||||
# fi
|
||||
#
|
||||
# make("clean")
|
||||
# make()
|
||||
# make("install")
|
||||
#
|
||||
# elif '+mic' in spec:
|
||||
# if '+runtime' in spec:
|
||||
# with working_dir('build_cbtf_mic_runtime', create=True):
|
||||
# python_vers='%d.%d' % spec['python'].version[:2]
|
||||
# cmake .. \
|
||||
#
|
||||
# else:
|
||||
# with working_dir('build_cbtf_cray_frontend', create=True):
|
||||
# python_vers='%d.%d' % spec['python'].version[:2]
|
||||
# cmake .. \
|
||||
# fi
|
||||
#
|
||||
# else:
|
||||
# # Build cbtf-krell with cmake
|
||||
# with working_dir('build_cbtf_krell', create=True):
|
||||
# cmake('..',
|
||||
# '-DCMAKE_BUILD_TYPE=Debug',
|
||||
# '-DCMAKE_INSTALL_PREFIX=%s' % prefix,
|
||||
# '-DCBTF_DIR=%s' % spec['cbtf'].prefix,
|
||||
# '-DBINUTILS_DIR=%s' % spec['binutils'].prefix,
|
||||
# '-DLIBMONITOR_DIR=%s' % spec['libmonitor'].prefix,
|
||||
# '-DLIBUNWIND_DIR=%s'% spec['libunwind'].prefix,
|
||||
# '-DPAPI_DIR=%s' % spec['papi'].prefix,
|
||||
# '-DBOOST_DIR=%s' % spec['boost'].prefix,
|
||||
# '-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
# '-DDYNINST_DIR=%s' % spec['dyninst'].prefix,
|
||||
# '-DXERCESC_DIR=%s' % spec['xerces-c'].prefix,
|
||||
# '-DOPENMPI_DIR=%s' % openmpi_prefix_path,
|
||||
# '-DCMAKE_PREFIX_PATH=%s' % cmake_prefix_path,
|
||||
# *std_cmake_args)
|
||||
#
|
||||
# make("clean")
|
||||
# make()
|
||||
# make("install")
|
||||
#
|
||||
# fi
|
||||
#
|
||||
return cmake_args
|
||||
|
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
|
||||
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
|
||||
# Produced at the Lawrence Livermore National Laboratory.
|
||||
#
|
||||
# This file is part of Spack.
|
||||
@ -23,7 +23,7 @@
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
##############################################################################
|
||||
##########################################################################
|
||||
# Copyright (c) 2015-2016 Krell Institute. All Rights Reserved.
|
||||
# Copyright (c) 2015-2017 Krell Institute. All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU General Public License as published by the Free Software
|
||||
@ -43,15 +43,11 @@
|
||||
from spack import *
|
||||
|
||||
|
||||
class CbtfLanl(Package):
|
||||
class CbtfLanl(CMakePackage):
|
||||
"""CBTF LANL project contains a memory tool and data center type system
|
||||
command monitoring tool."""
|
||||
homepage = "http://sourceforge.net/p/cbtf/wiki/Home/"
|
||||
|
||||
# Mirror access template example
|
||||
# url = "file:/g/g24/jeg/cbtf-lanl-1.6.tar.gz"
|
||||
# version('1.6', 'c3f78f967b0a42c6734ce4be0e602426')
|
||||
|
||||
version('1.8', branch='master',
|
||||
git='http://git.code.sf.net/p/cbtf-lanl/cbtf-lanl')
|
||||
|
||||
@ -64,61 +60,24 @@ class CbtfLanl(Package):
|
||||
|
||||
parallel = False
|
||||
|
||||
def adjustBuildTypeParams_cmakeOptions(self, spec, cmakeOptions):
|
||||
# Sets build type parameters into cmakeOptions the options that will
|
||||
# enable the cbtf-krell built type settings
|
||||
build_directory = 'build_cbtf_lanl'
|
||||
|
||||
def build_type(self):
|
||||
return 'None'
|
||||
|
||||
def cmake_args(self):
|
||||
|
||||
spec = self.spec
|
||||
compile_flags = "-O2 -g"
|
||||
BuildTypeOptions = []
|
||||
# Set CMAKE_BUILD_TYPE to what cbtf-krell wants it to be, not the
|
||||
# stdcmakeargs
|
||||
for word in cmakeOptions[:]:
|
||||
if word.startswith('-DCMAKE_BUILD_TYPE'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_CXX_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_C_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_VERBOSE_MAKEFILE'):
|
||||
cmakeOptions.remove(word)
|
||||
BuildTypeOptions.extend([
|
||||
'-DCMAKE_VERBOSE_MAKEFILE=ON',
|
||||
'-DCMAKE_BUILD_TYPE=None',
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags
|
||||
])
|
||||
|
||||
cmakeOptions.extend(BuildTypeOptions)
|
||||
cmake_args = [
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DCBTF_DIR=%s' % spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s' % spec['cbtf-krell'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix,
|
||||
'-DCMAKE_MODULE_PATH=%s' % join_path(
|
||||
prefix.share, 'KrellInstitute', 'cmake')]
|
||||
|
||||
def install(self, spec, prefix):
|
||||
|
||||
# Add in paths for finding package config files that tell us where to
|
||||
# find these packages
|
||||
cmake_prefix_path = join_path(
|
||||
spec['cbtf'].prefix) + ':' + join_path(spec['cbtf-krell'].prefix)
|
||||
|
||||
with working_dir('build', create=True):
|
||||
cmakeOptions = []
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s' % prefix,
|
||||
'-DCBTF_DIR=%s' % spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s' % spec['cbtf-krell'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix,
|
||||
'-DCMAKE_PREFIX_PATH=%s' % cmake_prefix_path,
|
||||
'-DCMAKE_MODULE_PATH=%s' % join_path(
|
||||
prefix.share, 'KrellInstitute', 'cmake')])
|
||||
|
||||
# Add in the standard cmake arguments
|
||||
cmakeOptions.extend(std_cmake_args)
|
||||
|
||||
# Adjust the standard cmake arguments to what we want the build
|
||||
# type, etc to be
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
# Invoke cmake
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
return cmake_args
|
||||
|
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
|
||||
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
|
||||
# Produced at the Lawrence Livermore National Laboratory.
|
||||
#
|
||||
# This file is part of Spack.
|
||||
@ -23,7 +23,7 @@
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
##############################################################################
|
||||
##########################################################################
|
||||
# Copyright (c) 2015-2016 Krell Institute. All Rights Reserved.
|
||||
# Copyright (c) 2015-2017 Krell Institute. All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU General Public License as published by the Free Software
|
||||
@ -43,7 +43,7 @@
|
||||
from spack import *
|
||||
|
||||
|
||||
class Cbtf(Package):
|
||||
class Cbtf(CMakePackage):
|
||||
"""CBTF project contains the base code for CBTF that supports creating
|
||||
components, component networks and the support to connect these
|
||||
components and component networks into sequential and distributed
|
||||
@ -52,10 +52,6 @@ class Cbtf(Package):
|
||||
"""
|
||||
homepage = "http://sourceforge.net/p/cbtf/wiki/Home"
|
||||
|
||||
# Mirror access template example
|
||||
# url = "file:/home/jeg/cbtf-1.6.tar.gz"
|
||||
# version('1.6', 'c1ef4e5aa4e470dffb042abdba0b9987')
|
||||
|
||||
# Use when the git repository is available
|
||||
version('1.8', branch='master',
|
||||
git='https://github.com/OpenSpeedShop/cbtf.git')
|
||||
@ -72,82 +68,45 @@ class Cbtf(Package):
|
||||
|
||||
parallel = False
|
||||
|
||||
def adjustBuildTypeParams_cmakeOptions(self, spec, cmakeOptions):
|
||||
# Sets build type parameters into cmakeOptions the options that will
|
||||
# enable the cbtf-krell built type settings
|
||||
build_directory = 'build_cbtf'
|
||||
|
||||
def build_type(self):
|
||||
return 'None'
|
||||
|
||||
def cmake_args(self):
|
||||
|
||||
spec = self.spec
|
||||
|
||||
# Boost_NO_SYSTEM_PATHS Set to TRUE to suppress searching
|
||||
# in system paths (or other locations outside of BOOST_ROOT
|
||||
# or BOOST_INCLUDEDIR). Useful when specifying BOOST_ROOT.
|
||||
# Defaults to OFF.
|
||||
|
||||
compile_flags = "-O2 -g"
|
||||
BuildTypeOptions = []
|
||||
# Set CMAKE_BUILD_TYPE to what cbtf-krell wants it to be, not the
|
||||
# stdcmakeargs
|
||||
for word in cmakeOptions[:]:
|
||||
if word.startswith('-DCMAKE_BUILD_TYPE'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_CXX_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_C_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
BuildTypeOptions.extend([
|
||||
'-DCMAKE_BUILD_TYPE=None',
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags
|
||||
])
|
||||
|
||||
cmakeOptions.extend(BuildTypeOptions)
|
||||
if '+runtime' in spec:
|
||||
# Install message tag include file for use in Intel MIC
|
||||
# cbtf-krell build
|
||||
# FIXME
|
||||
cmake_args = [
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DRUNTIME_ONLY=TRUE',
|
||||
'-DBoost_NO_SYSTEM_PATHS=TRUE',
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix,
|
||||
'-DBOOST_ROOT=%s' % spec['boost'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DCMAKE_MODULE_PATH=%s' % join_path(
|
||||
prefix.share, 'KrellInstitute', 'cmake')]
|
||||
else:
|
||||
cmake_args = [
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DBoost_NO_SYSTEM_PATHS=TRUE',
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix,
|
||||
'-DBOOST_ROOT=%s' % spec['boost'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DCMAKE_MODULE_PATH=%s' % join_path(
|
||||
prefix.share, 'KrellInstitute', 'cmake')]
|
||||
|
||||
def install(self, spec, prefix):
|
||||
with working_dir('build', create=True):
|
||||
|
||||
# Boost_NO_SYSTEM_PATHS Set to TRUE to suppress searching
|
||||
# in system paths (or other locations outside of BOOST_ROOT
|
||||
# or BOOST_INCLUDEDIR). Useful when specifying BOOST_ROOT.
|
||||
# Defaults to OFF.
|
||||
|
||||
if '+runtime' in spec:
|
||||
# Install message tag include file for use in Intel MIC
|
||||
# cbtf-krell build
|
||||
# FIXME
|
||||
cmakeOptions = []
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s' % prefix,
|
||||
'-DBoost_NO_SYSTEM_PATHS=TRUE',
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix,
|
||||
'-DBOOST_ROOT=%s' % spec['boost'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DCMAKE_MODULE_PATH=%s' % join_path(
|
||||
prefix.share, 'KrellInstitute', 'cmake')])
|
||||
|
||||
# Add in the standard cmake arguments
|
||||
cmakeOptions.extend(std_cmake_args)
|
||||
|
||||
# Adjust the standard cmake arguments to what we want the build
|
||||
# type, etc to be
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
# Invoke cmake
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
else:
|
||||
cmakeOptions = []
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s' % prefix,
|
||||
'-DBoost_NO_SYSTEM_PATHS=TRUE',
|
||||
'-DXERCESC_DIR=%s' % spec['xerces-c'].prefix,
|
||||
'-DBOOST_ROOT=%s' % spec['boost'].prefix,
|
||||
'-DMRNET_DIR=%s' % spec['mrnet'].prefix,
|
||||
'-DCMAKE_MODULE_PATH=%s' % join_path(
|
||||
prefix.share, 'KrellInstitute', 'cmake')])
|
||||
|
||||
# Add in the standard cmake arguments
|
||||
cmakeOptions.extend(std_cmake_args)
|
||||
|
||||
# Adjust the standard cmake arguments to what we want the build
|
||||
# type, etc to be
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
# Invoke cmake
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
return cmake_args
|
||||
|
@ -1,5 +1,5 @@
|
||||
##############################################################################
|
||||
# Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC.
|
||||
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
|
||||
# Produced at the Lawrence Livermore National Laboratory.
|
||||
#
|
||||
# This file is part of Spack.
|
||||
@ -23,7 +23,7 @@
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
##############################################################################
|
||||
##############################################################################
|
||||
# Copyright (c) 2015-2016 Krell Institute. All Rights Reserved.
|
||||
# Copyright (c) 2015-2017 Krell Institute. All Rights Reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify it
|
||||
# under the terms of the GNU General Public License as published by the Free
|
||||
@ -45,7 +45,7 @@
|
||||
import os.path
|
||||
|
||||
|
||||
class Openspeedshop(Package):
|
||||
class Openspeedshop(CMakePackage):
|
||||
"""OpenSpeedShop is a community effort by The Krell Institute with
|
||||
current direct funding from DOEs NNSA. It builds on top of a
|
||||
broad list of community infrastructures, most notably Dyninst
|
||||
@ -61,17 +61,11 @@ class Openspeedshop(Package):
|
||||
|
||||
homepage = "http://www.openspeedshop.org"
|
||||
url = "https://github.com/OpenSpeedShop"
|
||||
version('2.2', '16cb051179c2038de4e8a845edf1d573')
|
||||
|
||||
# Use when the git repository is available
|
||||
version('2.3', branch='master',
|
||||
git='https://github.com/OpenSpeedShop/openspeedshop.git')
|
||||
|
||||
# Optional mirror template
|
||||
# url = "file:/home/jeg/OpenSpeedShop_ROOT/SOURCES/openspeedshop-2.3.tar.gz"
|
||||
# version('2.3', '517a7798507241ad8abd8b0626a4d2cf')
|
||||
|
||||
parallel = False
|
||||
|
||||
variant('offline', default=False,
|
||||
description="build with offline instrumentor enabled.")
|
||||
variant('cbtf', default=True,
|
||||
@ -83,8 +77,9 @@ class Openspeedshop(Package):
|
||||
to point to target build.")
|
||||
variant('cuda', default=False,
|
||||
description="build with cuda packages included.")
|
||||
variant('ptgf', default=False,
|
||||
description="build with the PTGF based gui package enabled.")
|
||||
variant('useqt4gui', default=False,
|
||||
description="build with Qt4/Qt5 based gui package enabled. \
|
||||
Do not build older Qt3 gui")
|
||||
variant('rtfe', default=False,
|
||||
description="build for clusters heterogeneous processors \
|
||||
on fe/be nodes.")
|
||||
@ -115,15 +110,13 @@ class Openspeedshop(Package):
|
||||
depends_on("bison", type='build')
|
||||
depends_on("flex", type='build')
|
||||
depends_on("binutils@2.24+krellpatch", type='build')
|
||||
# TODO: when using dyninst@9.3.0:, we will need to use elf
|
||||
# depends_on("elf", type="link")
|
||||
depends_on("libelf")
|
||||
depends_on("elf", type="link")
|
||||
depends_on("libdwarf")
|
||||
depends_on("sqlite")
|
||||
depends_on("boost@1.50.0:1.59.0")
|
||||
depends_on("dyninst@9.2.0")
|
||||
depends_on("dyninst@9.3.2")
|
||||
depends_on("libxml2+python")
|
||||
depends_on("qt@3.3.8b+krellpatch")
|
||||
depends_on("qt@3.3.8b+krellpatch", when='~useqt4gui')
|
||||
|
||||
# Dependencies only for the openspeedshop offline package.
|
||||
depends_on("libunwind", when='+offline')
|
||||
@ -138,30 +131,124 @@ class Openspeedshop(Package):
|
||||
|
||||
# Dependencies only for the openspeedshop cbtf package.
|
||||
depends_on("cbtf", when='+cbtf')
|
||||
depends_on("cbtf-krell", when='+cbtf')
|
||||
depends_on('cbtf-krell+mpich', when='+cbtf+mpich')
|
||||
depends_on('cbtf-krell+mpich2', when='+cbtf+mpich2')
|
||||
depends_on('cbtf-krell+mpt', when='+cbtf+mpt')
|
||||
depends_on('cbtf-krell+mvapich', when='+cbtf+mvapich')
|
||||
depends_on('cbtf-krell+mvapich2', when='+cbtf+mvapich2')
|
||||
depends_on('cbtf-krell+openmpi', when='+cbtf+openmpi')
|
||||
depends_on("cbtf-argonavis", when='+cbtf+cuda')
|
||||
depends_on("mrnet@5.0.1:+lwthreads", when='+cbtf')
|
||||
|
||||
def adjustBuildTypeParams_cmakeOptions(self, spec, cmakeOptions):
|
||||
# Sets build type parameters into cmakeOptions the
|
||||
# options that will enable the cbtf-krell built type settings
|
||||
parallel = False
|
||||
|
||||
build_directory = 'build_openspeedshop'
|
||||
|
||||
def build_type(self):
|
||||
return 'None'
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
compile_flags = "-O2 -g"
|
||||
BuildTypeOptions = []
|
||||
# Set CMAKE_BUILD_TYPE to what cbtf-krell wants it
|
||||
# to be, not the stdcmakeargs
|
||||
for word in cmakeOptions[:]:
|
||||
if word.startswith('-DCMAKE_BUILD_TYPE'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_CXX_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
if word.startswith('-DCMAKE_C_FLAGS'):
|
||||
cmakeOptions.remove(word)
|
||||
BuildTypeOptions.extend(['-DCMAKE_BUILD_TYPE=None',
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags])
|
||||
|
||||
cmakeOptions.extend(BuildTypeOptions)
|
||||
if '+offline' in spec:
|
||||
instrumentor_setting = "offline"
|
||||
if '+runtime' in spec:
|
||||
|
||||
cmake_args = [
|
||||
'-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DINSTRUMENTOR=%s' % instrumentor_setting,
|
||||
'-DLIBMONITOR_DIR=%s' % spec['libmonitor'].prefix,
|
||||
'-DLIBUNWIND_DIR=%s' % spec['libunwind'].prefix,
|
||||
'-DPAPI_DIR=%s' % spec['papi'].prefix]
|
||||
|
||||
# Add any MPI implementations coming from variant settings
|
||||
self.set_mpi_cmakeOptions(spec, cmake_args)
|
||||
|
||||
else:
|
||||
cmake_args = []
|
||||
|
||||
# Appends base options to cmake_args
|
||||
self.set_defaultbase_cmakeOptions(spec, cmake_args)
|
||||
|
||||
cmake_args.extend(
|
||||
['-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DINSTRUMENTOR=%s'
|
||||
% instrumentor_setting,
|
||||
'-DLIBMONITOR_DIR=%s'
|
||||
% spec['libmonitor'].prefix,
|
||||
'-DLIBUNWIND_DIR=%s'
|
||||
% spec['libunwind'].prefix,
|
||||
'-DPAPI_DIR=%s'
|
||||
% spec['papi'].prefix,
|
||||
'-DSQLITE3_DIR=%s'
|
||||
% spec['sqlite'].prefix,
|
||||
'-DQTLIB_DIR=%s'
|
||||
% spec['qt'].prefix])
|
||||
|
||||
# Add any MPI implementations coming from variant settings
|
||||
self.set_mpi_cmakeOptions(spec, cmake_args)
|
||||
|
||||
elif '+cbtf' in spec:
|
||||
instrumentor_setting = "cbtf"
|
||||
|
||||
if '+runtime' in spec:
|
||||
|
||||
# Appends base options to cmake_args
|
||||
self.set_defaultbase_cmakeOptions(spec, cmake_args)
|
||||
|
||||
cmake_args.extend(
|
||||
['-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DINSTRUMENTOR=%s'
|
||||
% instrumentor_setting,
|
||||
'-DCBTF_DIR=%s'
|
||||
% spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s'
|
||||
% spec['cbtf-krell'].prefix,
|
||||
'-DMRNET_DIR=%s'
|
||||
% spec['mrnet'].prefix])
|
||||
|
||||
else:
|
||||
cmake_args = []
|
||||
|
||||
# Appends base options to cmake_args
|
||||
self.set_defaultbase_cmakeOptions(spec, cmake_args)
|
||||
|
||||
if '+useqt4gui' in self.spec:
|
||||
cmake_args.extend(
|
||||
['-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DINSTRUMENTOR=%s'
|
||||
% instrumentor_setting,
|
||||
'-DSQLITE3_DIR=%s'
|
||||
% spec['sqlite'].prefix,
|
||||
'-DCBTF_DIR=%s'
|
||||
% spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s'
|
||||
% spec['cbtf-krell'].prefix,
|
||||
'-DMRNET_DIR=%s'
|
||||
% spec['mrnet'].prefix])
|
||||
else:
|
||||
cmake_args.extend(
|
||||
['-DCMAKE_CXX_FLAGS=%s' % compile_flags,
|
||||
'-DCMAKE_C_FLAGS=%s' % compile_flags,
|
||||
'-DINSTRUMENTOR=%s'
|
||||
% instrumentor_setting,
|
||||
'-DSQLITE3_DIR=%s'
|
||||
% spec['sqlite'].prefix,
|
||||
'-DCBTF_DIR=%s'
|
||||
% spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s'
|
||||
% spec['cbtf-krell'].prefix,
|
||||
'-DQTLIB_DIR=%s'
|
||||
% spec['qt'].prefix,
|
||||
'-DMRNET_DIR=%s'
|
||||
% spec['mrnet'].prefix])
|
||||
|
||||
return cmake_args
|
||||
|
||||
def set_defaultbase_cmakeOptions(self, spec, cmakeOptions):
|
||||
# Appends to cmakeOptions the options that will enable
|
||||
@ -174,7 +261,7 @@ def set_defaultbase_cmakeOptions(self, spec, cmakeOptions):
|
||||
BaseOptions = []
|
||||
|
||||
BaseOptions.append('-DBINUTILS_DIR=%s' % spec['binutils'].prefix)
|
||||
BaseOptions.append('-DLIBELF_DIR=%s' % spec['libelf'].prefix)
|
||||
BaseOptions.append('-DLIBELF_DIR=%s' % spec['elf'].prefix)
|
||||
BaseOptions.append('-DLIBDWARF_DIR=%s' % spec['libdwarf'].prefix)
|
||||
BaseOptions.append('-DPYTHON_EXECUTABLE=%s' % python_exe)
|
||||
BaseOptions.append('-DPYTHON_INCLUDE_DIR=%s' % python_include)
|
||||
@ -273,144 +360,3 @@ def setup_environment(self, spack_env, run_env):
|
||||
run_env.set('OPENSS_MPI_IMPLEMENTATION', 'mvapich2')
|
||||
if '+openmpi' in self.spec:
|
||||
run_env.set('OPENSS_MPI_IMPLEMENTATION', 'openmpi')
|
||||
|
||||
def install(self, spec, prefix):
|
||||
|
||||
if '+offline' in spec:
|
||||
instrumentor_setting = "offline"
|
||||
if '+runtime' in spec:
|
||||
with working_dir('build_runtime', create=True):
|
||||
|
||||
cmakeOptions = []
|
||||
cmakeOptions.extend([
|
||||
'-DCMAKE_INSTALL_PREFIX=%s' % prefix,
|
||||
'-DINSTRUMENTOR=%s' % instrumentor_setting,
|
||||
'-DLIBMONITOR_DIR=%s' % spec['libmonitor'].prefix,
|
||||
'-DLIBUNWIND_DIR=%s' % spec['libunwind'].prefix,
|
||||
'-DPAPI_DIR=%s' % spec['papi'].prefix])
|
||||
|
||||
# Add any MPI implementations coming from variant settings
|
||||
self.set_mpi_cmakeOptions(spec, cmakeOptions)
|
||||
cmakeOptions.extend(std_cmake_args)
|
||||
|
||||
# Adjust the build options to the favored
|
||||
# ones for this build
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
else:
|
||||
cmake_prefix_path = join_path(spec['dyninst'].prefix)
|
||||
with working_dir('build', create=True):
|
||||
cmakeOptions = []
|
||||
|
||||
# Appends base options to cmakeOptions
|
||||
self.set_defaultbase_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s'
|
||||
% prefix,
|
||||
'-DCMAKE_PREFIX_PATH=%s'
|
||||
% cmake_prefix_path,
|
||||
'-DINSTRUMENTOR=%s'
|
||||
% instrumentor_setting,
|
||||
'-DLIBMONITOR_DIR=%s'
|
||||
% spec['libmonitor'].prefix,
|
||||
'-DLIBUNWIND_DIR=%s'
|
||||
% spec['libunwind'].prefix,
|
||||
'-DPAPI_DIR=%s'
|
||||
% spec['papi'].prefix,
|
||||
'-DSQLITE3_DIR=%s'
|
||||
% spec['sqlite'].prefix,
|
||||
'-DQTLIB_DIR=%s'
|
||||
% spec['qt'].prefix])
|
||||
|
||||
# Add any MPI implementations coming from variant settings
|
||||
self.set_mpi_cmakeOptions(spec, cmakeOptions)
|
||||
cmakeOptions.extend(std_cmake_args)
|
||||
|
||||
# Adjust the build options to the favored
|
||||
# ones for this build
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
|
||||
elif '+cbtf' in spec:
|
||||
instrumentor_setting = "cbtf"
|
||||
# resolve_symbols = "symtabapi"
|
||||
cmake_prefix_path = join_path(spec['cbtf'].prefix) \
|
||||
+ ':' + join_path(spec['cbtf-krell'].prefix)\
|
||||
+ ':' + join_path(spec['dyninst'].prefix)
|
||||
|
||||
if '+runtime' in spec:
|
||||
with working_dir('build_cbtf_runtime', create=True):
|
||||
cmakeOptions = []
|
||||
|
||||
# Appends base options to cmakeOptions
|
||||
self.set_defaultbase_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s'
|
||||
% prefix,
|
||||
'-DCMAKE_PREFIX_PATH=%s'
|
||||
% cmake_prefix_path,
|
||||
'-DINSTRUMENTOR=%s'
|
||||
% instrumentor_setting,
|
||||
'-DCBTF_DIR=%s'
|
||||
% spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s'
|
||||
% spec['cbtf-krell'].prefix,
|
||||
'-DMRNET_DIR=%s'
|
||||
% spec['mrnet'].prefix])
|
||||
|
||||
# Adjust the build options to the
|
||||
# favored ones for this build
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
|
||||
else:
|
||||
with working_dir('build_cbtf', create=True):
|
||||
cmakeOptions = []
|
||||
|
||||
# Appends base options to cmakeOptions
|
||||
self.set_defaultbase_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
cmakeOptions.extend(
|
||||
['-DCMAKE_INSTALL_PREFIX=%s'
|
||||
% prefix,
|
||||
'-DCMAKE_PREFIX_PATH=%s'
|
||||
% cmake_prefix_path,
|
||||
'-DINSTRUMENTOR=%s'
|
||||
% instrumentor_setting,
|
||||
'-DSQLITE3_DIR=%s'
|
||||
% spec['sqlite'].prefix,
|
||||
'-DCBTF_DIR=%s'
|
||||
% spec['cbtf'].prefix,
|
||||
'-DCBTF_KRELL_DIR=%s'
|
||||
% spec['cbtf-krell'].prefix,
|
||||
'-DQTLIB_DIR=%s'
|
||||
% spec['qt'].prefix,
|
||||
'-DMRNET_DIR=%s'
|
||||
% spec['mrnet'].prefix])
|
||||
|
||||
# Adjust the build options to the favored
|
||||
# ones for this build
|
||||
self.adjustBuildTypeParams_cmakeOptions(spec, cmakeOptions)
|
||||
|
||||
cmake('..', *cmakeOptions)
|
||||
|
||||
make("clean")
|
||||
make()
|
||||
make("install")
|
||||
|
Loading…
Reference in New Issue
Block a user