Remove custom phases in packages (1/n) (#29968)

* abi-dumper: remove custom phases

* apktool: remove custom phases, add v2.6.1

* aragorn: remove custom phases

* ascent: remove custom phases

* astral: remove custom phases, add v5.7.1

* bigdft: remove redundant phase definitions

* bazel: remove custom phases phase definitions

* blasr: remove custom phases phase definitions

* bmake: remove custom phases phase definitions, add v20220330

* botan: remove custom phases phase definitions

* breakdancer: remove custom phases phase definitions

* dnstracer: remove custom phases phase definitions

* conduit: remove custom phases phase definitions

* eclipse-gcj-parser: remove custom phases phase definitions

* eem: remove custom phases phase definitions

* fasttree: remove custom phases phase definitions

* fleur: remove custom phases phase definitions

* fpm: remove custom phases phase definitions

* genie: remove custom phases phase definitions

* gluegen: remove custom phases phase definitions

* gnat: remove custom phases phase definitions

* hpgmg: remove custom phases phase definitions

* karma: remove custom phases phase definitions

* libc: remove custom phases phase definitions
This commit is contained in:
Massimiliano Culpo 2022-04-11 11:39:50 +02:00 committed by GitHub
parent c2f470f4a6
commit d0ad644ea6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
31 changed files with 61 additions and 157 deletions

View File

@ -6,12 +6,12 @@
from spack import * from spack import *
class AbiDumper(MakefilePackage): class AbiDumper(Package):
"""ABI Dumper is a tool to dump ABI of an ELF object containing """ABI Dumper is a tool to dump ABI of an ELF object containing
DWARF debug info.""" DWARF debug info."""
homepage = "https://github.com/lvc/abi-dumper" homepage = "https://github.com/lvc/abi-dumper"
url = "https://github.com/lvc/abi-dumper/archive/1.2.tar.gz" url = "https://github.com/lvc/abi-dumper/archive/1.2.tar.gz"
version('1.2', sha256='8a9858c91b4e9222c89b676d59422053ad560fa005a39443053568049bd4d27e') version('1.2', sha256='8a9858c91b4e9222c89b676d59422053ad560fa005a39443053568049bd4d27e')
version('1.1', sha256='ef63201368e0d76a29d2f7aed98c488f6fb71898126762d65baed1e762988083') version('1.1', sha256='ef63201368e0d76a29d2f7aed98c488f6fb71898126762d65baed1e762988083')
@ -24,7 +24,5 @@ class AbiDumper(MakefilePackage):
depends_on('universal-ctags') depends_on('universal-ctags')
depends_on('vtable-dumper@1.1:') depends_on('vtable-dumper@1.1:')
phases = ['install']
def install(self, spec, prefix): def install(self, spec, prefix):
make('prefix={0}'.format(prefix), 'install') make('prefix={0}'.format(prefix), 'install')

View File

@ -13,20 +13,17 @@ class Apktool(Package):
homepage = "https://ibotpeaches.github.io/Apktool/" homepage = "https://ibotpeaches.github.io/Apktool/"
url = "https://github.com/iBotPeaches/Apktool/archive/refs/tags/v2.6.0.tar.gz" url = "https://github.com/iBotPeaches/Apktool/archive/refs/tags/v2.6.0.tar.gz"
version('2.6.1', sha256='8932e77d963b9e0e07227422d82ed4a355e8aa268bad1361e5cfaffa8e4d52ee')
version('2.6.0', sha256='74739cdb1434ca35ec34e51ca7272ad3f378ae3ed0a2d5805d9a2fab5016037f') version('2.6.0', sha256='74739cdb1434ca35ec34e51ca7272ad3f378ae3ed0a2d5805d9a2fab5016037f')
depends_on('java@8:', type=('build', 'run')) depends_on('java@8:', type=('build', 'run'))
phases = ['build', 'install']
def setup_build_environment(self, env): def setup_build_environment(self, env):
env.set('LC_ALL', 'en_US.UTF-8') env.set('LC_ALL', 'en_US.UTF-8')
def build(self, spec, prefix): def install(self, spec, prefix):
gradlew = Executable('./gradlew') gradlew = Executable('./gradlew')
gradlew('--info', '--debug', 'build', 'shadowJar') gradlew('--info', '--debug', 'build', 'shadowJar')
def install(self, spec, prefix):
ln = which('ln') ln = which('ln')
mkdir(join_path(prefix, 'bin')) mkdir(join_path(prefix, 'bin'))
install( install(

View File

@ -16,13 +16,9 @@ class Aragorn(Package):
version('1.2.38', sha256='4b84e3397755fb22cc931c0e7b9d50eaba2a680df854d7a35db46a13cecb2126') version('1.2.38', sha256='4b84e3397755fb22cc931c0e7b9d50eaba2a680df854d7a35db46a13cecb2126')
version('1.2.36', sha256='ab06032589e45aa002f8616333568e9ab11034b3a675f922421e5f1c3e95e7b5') version('1.2.36', sha256='ab06032589e45aa002f8616333568e9ab11034b3a675f922421e5f1c3e95e7b5')
phases = ['build', 'install'] def install(self, spec, prefix):
def build(self, spec, prefix):
cc = Executable(spack_cc) cc = Executable(spack_cc)
cc('-O3', '-ffast-math', '-finline-functions', cc('-O3', '-ffast-math', '-finline-functions',
'-oaragorn', 'aragorn' + format(spec.version.dotted) + '.c') '-oaragorn', 'aragorn' + format(spec.version.dotted) + '.c')
def install(self, spec, prefix):
mkdirp(prefix.bin) mkdirp(prefix.bin)
install('aragorn', prefix.bin) install('aragorn', prefix.bin)

View File

@ -187,11 +187,6 @@ class Ascent(CMakePackage, CudaPackage):
conflicts("+shared", when="+cuda", conflicts("+shared", when="+cuda",
msg="Ascent needs to be built with ~shared for CUDA builds.") msg="Ascent needs to be built with ~shared for CUDA builds.")
###################################
# build phases used by this package
###################################
phases = ['hostconfig', 'cmake', 'build', 'install']
def setup_build_environment(self, env): def setup_build_environment(self, env):
env.set('CTEST_OUTPUT_ON_FAILURE', '1') env.set('CTEST_OUTPUT_ON_FAILURE', '1')
@ -260,7 +255,8 @@ def _get_host_config_path(self, spec):
host_config_path)) host_config_path))
return host_config_path return host_config_path
def hostconfig(self, spec, prefix): @run_before('cmake')
def hostconfig(self):
""" """
This method creates a 'host-config' file that specifies This method creates a 'host-config' file that specifies
all of the options used to configure and build ascent. all of the options used to configure and build ascent.
@ -269,6 +265,7 @@ def hostconfig(self, spec, prefix):
https://ascent.readthedocs.io/en/latest/BuildingAscent.html https://ascent.readthedocs.io/en/latest/BuildingAscent.html
""" """
spec = self.spec
if not os.path.isdir(spec.prefix): if not os.path.isdir(spec.prefix):
os.mkdir(spec.prefix) os.mkdir(spec.prefix)

View File

@ -15,6 +15,7 @@ class Astral(Package):
homepage = "https://github.com/smirarab/ASTRAL" homepage = "https://github.com/smirarab/ASTRAL"
url = "https://github.com/smirarab/ASTRAL/archive/v4.10.7.tar.gz" url = "https://github.com/smirarab/ASTRAL/archive/v4.10.7.tar.gz"
version('5.7.1', sha256='8aa6fd4324efca325d3dde432517090fac314bea95f407b1dd59977181fec77e')
version('5.6.1', sha256='b49a67c9fe19c0c92a89dc2f1a3928840e698a53054a595c61546ca98448a076', version('5.6.1', sha256='b49a67c9fe19c0c92a89dc2f1a3928840e698a53054a595c61546ca98448a076',
url='https://github.com/smirarab/ASTRAL/archive/untagged-697f19dbce69929ece09.tar.gz') url='https://github.com/smirarab/ASTRAL/archive/untagged-697f19dbce69929ece09.tar.gz')
version('4.10.7', sha256='314b49e0129ec06a7c78a1b60d590259ede6a5e75253407031e108d8048fcc79') version('4.10.7', sha256='314b49e0129ec06a7c78a1b60d590259ede6a5e75253407031e108d8048fcc79')
@ -22,13 +23,9 @@ class Astral(Package):
depends_on('java', type=('build', 'run')) depends_on('java', type=('build', 'run'))
depends_on('zip', type='build') depends_on('zip', type='build')
phases = ['build', 'install'] def install(self, spec, prefix):
def build(self, spec, prefix):
make = Executable('./make.sh') make = Executable('./make.sh')
make() make()
def install(self, spec, prefix):
mkdirp(prefix.bin) mkdirp(prefix.bin)
install_tree('lib', prefix.tools.lib) install_tree('lib', prefix.tools.lib)
jar_file = 'astral.{v}.jar'.format(v=self.version) jar_file = 'astral.{v}.jar'.format(v=self.version)

View File

@ -157,8 +157,6 @@ class Bazel(Package):
patch('disabledepcheck.patch', when='@0.3.2:+nodepfail') patch('disabledepcheck.patch', when='@0.3.2:+nodepfail')
patch('disabledepcheck_old.patch', when='@0.3.0:0.3.1+nodepfail') patch('disabledepcheck_old.patch', when='@0.3.0:0.3.1+nodepfail')
phases = ['bootstrap', 'install']
executables = ['^bazel$'] executables = ['^bazel$']
@classmethod @classmethod
@ -195,7 +193,8 @@ def setup_build_environment(self, env):
' --subcommands=pretty_print' ' --subcommands=pretty_print'
' --jobs={0}'.format(make_jobs)) ' --jobs={0}'.format(make_jobs))
def bootstrap(self, spec, prefix): @run_before('install')
def bootstrap(self):
bash = which('bash') bash = which('bash')
bash('./compile.sh') bash('./compile.sh')

View File

@ -29,8 +29,6 @@ class BigdftAtlab(AutotoolsPackage):
for vers in ['1.8.1', '1.8.2', '1.8.3', '1.9.0', '1.9.1', '1.9.2', 'develop']: for vers in ['1.8.1', '1.8.2', '1.8.3', '1.9.0', '1.9.1', '1.9.2', 'develop']:
depends_on('bigdft-futile@{0}'.format(vers), when='@{0}'.format(vers)) depends_on('bigdft-futile@{0}'.format(vers), when='@{0}'.format(vers))
phases = ['autoreconf', 'configure', 'build', 'install']
build_directory = "atlab" build_directory = "atlab"
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):

View File

@ -45,8 +45,6 @@ class BigdftChess(AutotoolsPackage, CudaPackage):
for vers in ['1.8.3', '1.9.0', '1.9.1', '1.9.2', 'develop']: for vers in ['1.8.3', '1.9.0', '1.9.1', '1.9.2', 'develop']:
depends_on('bigdft-atlab@{0}'.format(vers), when='@{0}'.format(vers)) depends_on('bigdft-atlab@{0}'.format(vers), when='@{0}'.format(vers))
phases = ['autoreconf', 'configure', 'build', 'install']
build_directory = "chess" build_directory = "chess"
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):

View File

@ -48,8 +48,6 @@ class BigdftCore(AutotoolsPackage, CudaPackage):
depends_on('bigdft-psolver@{0}'.format(vers), when='@{0}'.format(vers)) depends_on('bigdft-psolver@{0}'.format(vers), when='@{0}'.format(vers))
depends_on('bigdft-libabinit@{0}'.format(vers), when='@{0}'.format(vers)) depends_on('bigdft-libabinit@{0}'.format(vers), when='@{0}'.format(vers))
phases = ['autoreconf', 'configure', 'build', 'install']
build_directory = "bigdft" build_directory = "bigdft"
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):

View File

@ -38,8 +38,6 @@ class BigdftFutile(AutotoolsPackage, CudaPackage):
depends_on('py-pyyaml') depends_on('py-pyyaml')
depends_on('mpi', when='+mpi') depends_on('mpi', when='+mpi')
phases = ['autoreconf', 'configure', 'build', 'install']
build_directory = "futile" build_directory = "futile"
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):

View File

@ -40,8 +40,6 @@ class BigdftLibabinit(AutotoolsPackage):
patch('m_libpaw_mpi.F90.patch', when='@:1.8.2') patch('m_libpaw_mpi.F90.patch', when='@:1.8.2')
phases = ['autoreconf', 'configure', 'build', 'install']
build_directory = "libABINIT" build_directory = "libABINIT"
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):

View File

@ -42,8 +42,6 @@ class BigdftPsolver(AutotoolsPackage, CudaPackage):
for vers in ['1.8.3', '1.9.0', '1.9.1', '1.9.2', 'develop']: for vers in ['1.8.3', '1.9.0', '1.9.1', '1.9.2', 'develop']:
depends_on('bigdft-atlab@{0}'.format(vers), when='@{0}'.format(vers)) depends_on('bigdft-atlab@{0}'.format(vers), when='@{0}'.format(vers))
phases = ['autoreconf', 'configure', 'build', 'install']
build_directory = "psolver" build_directory = "psolver"
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):

View File

@ -41,8 +41,6 @@ class BigdftSpred(AutotoolsPackage):
depends_on('bigdft-psolver@{0}'.format(vers), when='@{0}'.format(vers)) depends_on('bigdft-psolver@{0}'.format(vers), when='@{0}'.format(vers))
depends_on('bigdft-core@{0}'.format(vers), when='@{0}'.format(vers)) depends_on('bigdft-core@{0}'.format(vers), when='@{0}'.format(vers))
phases = ['autoreconf', 'configure', 'build', 'install']
build_directory = "spred" build_directory = "spred"
def autoreconf(self, spec, prefix): def autoreconf(self, spec, prefix):

View File

@ -28,8 +28,7 @@ class BlasrLibcpp(Package):
depends_on('python@2.7:2.8', type='build') depends_on('python@2.7:2.8', type='build')
phases = ['configure', 'build', 'install'] @run_before('install')
def configure(self, spec, prefix): def configure(self, spec, prefix):
configure_args = [ configure_args = [
'PBBAM_INC={0}'.format(self.spec['pbbam'].prefix.include), 'PBBAM_INC={0}'.format(self.spec['pbbam'].prefix.include),
@ -39,6 +38,7 @@ def configure(self, spec, prefix):
] ]
python('configure.py', *configure_args) python('configure.py', *configure_args)
@run_before('install')
def build(self, spec, prefix): def build(self, spec, prefix):
os.environ['CPLUS_INCLUDE_PATH'] = self.stage.source_path os.environ['CPLUS_INCLUDE_PATH'] = self.stage.source_path
make() make()

View File

@ -30,8 +30,6 @@ class Blasr(Package):
depends_on('blasr-libcpp') depends_on('blasr-libcpp')
depends_on('python', type='build') depends_on('python', type='build')
phases = ['configure', 'build', 'install']
def setup_build_environment(self, env): def setup_build_environment(self, env):
env.prepend_path('CPATH', self.spec['blasr-libcpp'].prefix) env.prepend_path('CPATH', self.spec['blasr-libcpp'].prefix)
env.prepend_path('CPATH', self.spec['blasr-libcpp'].prefix.pbdata) env.prepend_path('CPATH', self.spec['blasr-libcpp'].prefix.pbdata)
@ -46,6 +44,7 @@ def setup_build_environment(self, env):
def setup_run_environment(self, env): def setup_run_environment(self, env):
env.prepend_path('PATH', self.spec.prefix.utils) env.prepend_path('PATH', self.spec.prefix.utils)
@run_before('install')
def configure(self, spec, prefix): def configure(self, spec, prefix):
configure_args = [ configure_args = [
'LIBPBDATA_INC={0}'.format( 'LIBPBDATA_INC={0}'.format(
@ -64,6 +63,7 @@ def configure(self, spec, prefix):
] ]
python('configure.py', *configure_args) python('configure.py', *configure_args)
@run_before('install')
def build(self, spec, prefix): def build(self, spec, prefix):
os.environ['CPLUS_INCLUDE_PATH'] = join_path( os.environ['CPLUS_INCLUDE_PATH'] = join_path(
self.stage.source_path, 'include') self.stage.source_path, 'include')

View File

@ -10,14 +10,13 @@ class Bmake(Package):
"""Portable version of NetBSD make(1).""" """Portable version of NetBSD make(1)."""
homepage = "https://www.crufty.net/help/sjg/bmake.htm" homepage = "https://www.crufty.net/help/sjg/bmake.htm"
url = "https://www.crufty.net/ftp/pub/sjg/bmake-20180512.tar.gz" url = "https://www.crufty.net/ftp/pub/sjg/bmake-20180512.tar.gz"
version('20220330', sha256='4b46d95b6ae4b3311ba805ff7d5a19b9e37ac0e86880e296e2111f565b545092')
version('20200710', sha256='6538fc4319ef79d178dca76d3b869f7aa93a9bb7b510df08a7d872c01a56b76c') version('20200710', sha256='6538fc4319ef79d178dca76d3b869f7aa93a9bb7b510df08a7d872c01a56b76c')
version('20180512', sha256='ac3cd262065fcc20c1dec7c95f06306c8138b3e17025b949343a06a8980a5508') version('20180512', sha256='ac3cd262065fcc20c1dec7c95f06306c8138b3e17025b949343a06a8980a5508')
version('20171207', sha256='1703667e53a0498c0903b20612ebcbb41b886a94b238624cfeadd91a4111d39a') version('20171207', sha256='1703667e53a0498c0903b20612ebcbb41b886a94b238624cfeadd91a4111d39a')
phases = ['configure', 'build', 'install']
def patch(self): def patch(self):
# Do not pre-roff cat pages # Do not pre-roff cat pages
filter_file('MANTARGET?', 'MANTARGET', 'mk/man.mk', string=True) filter_file('MANTARGET?', 'MANTARGET', 'mk/man.mk', string=True)
@ -25,14 +24,8 @@ def patch(self):
filter_file('GetDir /bmake', 'GetDir ' + self.stage.source_path, filter_file('GetDir /bmake', 'GetDir ' + self.stage.source_path,
'boot-strap', string=True) 'boot-strap', string=True)
def configure(self, spec, prefix):
sh = which('sh')
sh('boot-strap', 'op=configure')
def build(self, spec, prefix):
sh = which('sh')
sh('boot-strap', 'op=build')
def install(self, spec, prefix): def install(self, spec, prefix):
sh = which('sh') sh = which('sh')
sh('boot-strap', 'op=configure')
sh('boot-strap', 'op=build')
sh('boot-strap', '--prefix={0}'.format(prefix), 'op=install') sh('boot-strap', '--prefix={0}'.format(prefix), 'op=install')

View File

@ -6,7 +6,7 @@
from spack import * from spack import *
class Botan(Package): class Botan(MakefilePackage):
"""Crypto and TLS for Modern C++""" """Crypto and TLS for Modern C++"""
homepage = "https://botan.randombit.net/" homepage = "https://botan.randombit.net/"
@ -36,24 +36,15 @@ class Botan(Package):
depends_on('python', type='build') depends_on('python', type='build')
depends_on('py-sphinx@1.2:', type='build', when='+doc') depends_on('py-sphinx@1.2:', type='build', when='+doc')
phases = ['configure', 'build', 'install'] def edit(self, spec, prefix):
def configure(self, spec, prefix):
configure = Executable('./configure.py') configure = Executable('./configure.py')
configure(*self.configure_args()) configure(*self.configure_args())
def configure_args(self): def configure_args(self):
spec = self.spec spec = self.spec
args = [] args = ['--prefix={0}'.format(self.prefix)]
args.append('--prefix=' + prefix)
if '+doc' in spec: if '+doc' in spec:
args.append('--with-documentation') args.append('--with-documentation')
else: else:
args.append('--without-documentation') args.append('--without-documentation')
return args return args
def build(self, spec, prefix):
make()
def install(self, spec, prefix):
make('install')

View File

@ -24,8 +24,6 @@ class Breakdancer(CMakePackage):
version('master', submodules='true', version('master', submodules='true',
git='https://github.com/genome/breakdancer.git', preferred=True) git='https://github.com/genome/breakdancer.git', preferred=True)
phases = ['edit', 'cmake', 'build', 'install']
depends_on('zlib') depends_on('zlib')
depends_on('ncurses', type='link') depends_on('ncurses', type='link')
@ -45,7 +43,8 @@ def setup_run_environment(self, env):
# get the perl tools in the path # get the perl tools in the path
env.prepend_path('PATH', self.prefix.lib) env.prepend_path('PATH', self.prefix.lib)
def edit(self, spec, prefix): @run_before('cmake')
def edit(self):
# perl tools end up in a silly lib subdirectory, fixing that # perl tools end up in a silly lib subdirectory, fixing that
filter_file(r'set\(SUPPORT_LIBDIR lib\/breakdancer-max\$ \ filter_file(r'set\(SUPPORT_LIBDIR lib\/breakdancer-max\$ \
\{EXE_VERSION_SUFFIX\}\)', \{EXE_VERSION_SUFFIX\}\)',

View File

@ -176,11 +176,6 @@ class Conduit(CMakePackage):
patch('https://github.com/LLNL/conduit/pull/773.patch?full_index=1', when='@:0.7.2', patch('https://github.com/LLNL/conduit/pull/773.patch?full_index=1', when='@:0.7.2',
sha256='784d74942a63acf698c31b39848b46b4b755bf06faa6aa6fb81be61783ec0c30') sha256='784d74942a63acf698c31b39848b46b4b755bf06faa6aa6fb81be61783ec0c30')
###################################
# build phases used by this package
###################################
phases = ['hostconfig', 'cmake', 'build', 'install']
def setup_build_environment(self, env): def setup_build_environment(self, env):
env.set('CTEST_OUTPUT_ON_FAILURE', '1') env.set('CTEST_OUTPUT_ON_FAILURE', '1')
# conduit uses a <=1.10 api version before 0.8 # conduit uses a <=1.10 api version before 0.8
@ -274,7 +269,8 @@ def _get_host_config_path(self, spec):
host_config_path)) host_config_path))
return host_config_path return host_config_path
def hostconfig(self, spec, prefix): @run_before('cmake')
def hostconfig(self):
""" """
This method creates a 'host-config' file that specifies This method creates a 'host-config' file that specifies
all of the options used to configure and build conduit. all of the options used to configure and build conduit.
@ -282,6 +278,7 @@ def hostconfig(self, spec, prefix):
For more details about 'host-config' files see: For more details about 'host-config' files see:
http://software.llnl.gov/conduit/building.html http://software.llnl.gov/conduit/building.html
""" """
spec = self.spec
if not os.path.isdir(spec.prefix): if not os.path.isdir(spec.prefix):
os.mkdir(spec.prefix) os.mkdir(spec.prefix)

View File

@ -6,24 +6,17 @@
from spack import * from spack import *
class Dnstracer(Package): class Dnstracer(MakefilePackage):
"""Dnstracer determines where a given Domain Name Server gets """Dnstracer determines where a given Domain Name Server gets
its information from, and follows the chain of DNS servers back to its information from, and follows the chain of DNS servers back to
the servers which know the data.""" the servers which know the data.
"""
homepage = "https://github.com/Orc/dnstracer" homepage = "https://github.com/Orc/dnstracer"
git = "https://github.com/Orc/dnstracer.git" git = "https://github.com/Orc/dnstracer.git"
version('master', branch='master') version('master', branch='master')
phases = ['configure', 'build', 'install'] def edit(self, spec, prefix):
def configure(self, spec, prefix):
configure = Executable('./configure.sh') configure = Executable('./configure.sh')
configure('--prefix={0}'.format(prefix)) configure('--prefix={0}'.format(prefix))
def build(self, spec, prefix):
make()
def install(self, spec, prefix):
make('install')

View File

@ -25,8 +25,6 @@ class EclipseGcjParser(Package):
version('4.8', sha256='98fd128f1d374d9e42fd9d4836bdd249c6d511ebc6c0df17fbc1b9df96c3d781', expand=False) version('4.8', sha256='98fd128f1d374d9e42fd9d4836bdd249c6d511ebc6c0df17fbc1b9df96c3d781', expand=False)
phases = ('build', 'install')
@property @property
def gcj(self): def gcj(self):
"""Obtain Executable for the gcj included with this GCC, """Obtain Executable for the gcj included with this GCC,
@ -40,12 +38,9 @@ def gcj(self):
return Executable(join_path(dir, gcc.replace('gcc', 'gcj'))) return Executable(join_path(dir, gcc.replace('gcc', 'gcj')))
def build(self, spec, prefix):
self.gcj(
'-o', 'ecj1',
'--main=org.eclipse.jdt.internal.compiler.batch.GCCMain',
'ecj-4.8.jar')
def install(self, spec, prefix): def install(self, spec, prefix):
self.gcj('-o', 'ecj1',
'--main=org.eclipse.jdt.internal.compiler.batch.GCCMain',
'ecj-4.8.jar')
mkdirp(spec.prefix.bin) mkdirp(spec.prefix.bin)
install('ecj1', spec.prefix.bin) install('ecj1', spec.prefix.bin)

View File

@ -17,8 +17,6 @@ class Eem(MakefilePackage):
variant('K', default=False, description='Build for K computer') variant('K', default=False, description='Build for K computer')
phases = ['edit', 'install']
depends_on('mpi') depends_on('mpi')
build_directory = 'src' build_directory = 'src'

View File

@ -8,24 +8,19 @@
class Fasttree(Package): class Fasttree(Package):
"""FastTree infers approximately-maximum-likelihood phylogenetic """FastTree infers approximately-maximum-likelihood phylogenetic
trees from alignments of nucleotide or protein sequences. trees from alignments of nucleotide or protein sequences.
FastTree can handle alignments with up to a million of sequences """
in a reasonable amount of time and memory."""
homepage = "http://www.microbesonline.org/fasttree" homepage = "http://www.microbesonline.org/fasttree"
url = "http://www.microbesonline.org/fasttree/FastTree-2.1.10.c" url = "http://www.microbesonline.org/fasttree/FastTree-2.1.10.c"
version('2.1.10', sha256='54cb89fc1728a974a59eae7a7ee6309cdd3cddda9a4c55b700a71219fc6e926d', expand=False, url='http://www.microbesonline.org/fasttree/FastTree-2.1.10.c') version('2.1.10', sha256='54cb89fc1728a974a59eae7a7ee6309cdd3cddda9a4c55b700a71219fc6e926d', expand=False, url='http://www.microbesonline.org/fasttree/FastTree-2.1.10.c')
phases = ['build', 'install'] def install(self, spec, prefix):
def build(self, spec, prefix):
cc = Executable(spack_cc) cc = Executable(spack_cc)
cc('-O3', self.compiler.openmp_flag, cc('-O3', self.compiler.openmp_flag,
'-DOPENMP', '-finline-functions', '-funroll-loops', '-Wall', '-DOPENMP', '-finline-functions', '-funroll-loops', '-Wall',
'-oFastTreeMP', 'FastTree-' + format(spec.version.dotted) + '.c', '-oFastTreeMP', 'FastTree-' + format(spec.version.dotted) + '.c',
'-lm') '-lm')
def install(self, spec, prefix):
mkdir(prefix.bin) mkdir(prefix.bin)
install('FastTreeMP', prefix.bin) install('FastTreeMP', prefix.bin)

View File

@ -53,8 +53,6 @@ class Fleur(Package):
depends_on('elpa~openmp', when='+elpa~openmp') depends_on('elpa~openmp', when='+elpa~openmp')
depends_on('elpa+openmp', when='+elpa+openmp') depends_on('elpa+openmp', when='+elpa+openmp')
phases = ['configure', 'build', 'install']
conflicts('%intel@:16.0.4', conflicts('%intel@:16.0.4',
msg='ifort version <16.0 will most probably not work correctly') msg='ifort version <16.0 will most probably not work correctly')
conflicts('%gcc@:6.3.0', conflicts('%gcc@:6.3.0',
@ -81,7 +79,8 @@ def setup_build_environment(self, env):
env.set('FC', spec['mpi'].mpifc, force=True) env.set('FC', spec['mpi'].mpifc, force=True)
env.set('CXX', spec['mpi'].mpicxx, force=True) env.set('CXX', spec['mpi'].mpicxx, force=True)
def configure(self, spec, prefix): @run_before('install')
def configure(self):
spec = self.spec spec = self.spec
sh = which('bash') sh = which('bash')
@ -162,18 +161,12 @@ def configure(self, spec, prefix):
args.append(" ".join(options["-libdir"])) args.append(" ".join(options["-libdir"]))
args.append("-includedir") args.append("-includedir")
args.append(" ".join(options["-includedir"])) args.append(" ".join(options["-includedir"]))
# args.append("-flags")
# args.append(" ".join(options["-flags"]))
sh('configure.sh', *args) sh('configure.sh', *args)
def build(self, spec, prefix):
with working_dir('build'):
make()
def install(self, spec, prefix): def install(self, spec, prefix):
with working_dir('build'): with working_dir('build'):
# copy bin make()
mkdirp(prefix.bin) mkdirp(prefix.bin)
if '+mpi' in spec: if '+mpi' in spec:
install('fleur_MPI', prefix.bin) install('fleur_MPI', prefix.bin)

View File

@ -19,7 +19,6 @@ class Fpm(Package):
url = "https://github.com/fortran-lang/fpm/releases/download/v0.4.0/fpm-0.4.0.zip" url = "https://github.com/fortran-lang/fpm/releases/download/v0.4.0/fpm-0.4.0.zip"
maintainers = ["awvwgk"] maintainers = ["awvwgk"]
phases = ["install"]
version("0.5.0", "e4a06956d2300f9aa1d06bd3323670480e946549617582e32684ded6921a921e") version("0.5.0", "e4a06956d2300f9aa1d06bd3323670480e946549617582e32684ded6921a921e")
version("0.4.0", "cd9b80b7f40d9cf357ca8d5d4fe289fd32dfccb729bad7d2a68f245e4cdd0045") version("0.4.0", "cd9b80b7f40d9cf357ca8d5d4fe289fd32dfccb729bad7d2a68f245e4cdd0045")

View File

@ -12,7 +12,7 @@
from spack.version import Version from spack.version import Version
class Genie(Package): # Genie doesn"t use Autotools class Genie(Package):
"""Genie is a neutrino Monte Carlo Generator.""" """Genie is a neutrino Monte Carlo Generator."""
homepage = "https://www.genie-mc.org" homepage = "https://www.genie-mc.org"
@ -22,7 +22,7 @@ class Genie(Package): # Genie doesn"t use Autotools
tags = ["neutrino", "hep"] tags = ["neutrino", "hep"]
maintainers = [ maintainers = [
# maintainer of this recipe, not affliated with the GENIE collaboration # maintainer of this recipe, not affiliated with the GENIE collaboration
"davehadley", "davehadley",
] ]
@ -77,8 +77,6 @@ class Genie(Package): # Genie doesn"t use Autotools
variant("vleextension", default=False, variant("vleextension", default=False,
description="Enable GENIE very low energy (1 MeV - 100 MeV) extension") description="Enable GENIE very low energy (1 MeV - 100 MeV) extension")
phases = ["configure", "build", "install"]
def url_for_version(self, version): def url_for_version(self, version):
url = "https://github.com/GENIE-MC/Generator/archive/R-{0}.tar.gz" url = "https://github.com/GENIE-MC/Generator/archive/R-{0}.tar.gz"
if version >= Version(3): if version >= Version(3):
@ -94,16 +92,11 @@ def setup_run_environment(self, env):
env.set("GENIE", self.prefix) env.set("GENIE", self.prefix)
return super(Genie, self).setup_run_environment(env) return super(Genie, self).setup_run_environment(env)
def configure(self, spec, prefix): def install(self, spec, prefix):
configure = Executable("./configure") configure = Executable("./configure")
args = self._configure_args(spec, prefix) args = self._configure_args(spec, prefix)
configure(*args) configure(*args)
def build(self, spec, prefix):
# parallel build is not supported on GENIE 2
self._make(parallel=spec.satisfies("@3:")) self._make(parallel=spec.satisfies("@3:"))
def install(self, spec, prefix):
# GENIE make install does not support parallel jobs # GENIE make install does not support parallel jobs
self._make("install", parallel=False) self._make("install", parallel=False)
# GENIE requires these files to be present at runtime, but doesn"t install them # GENIE requires these files to be present at runtime, but doesn"t install them

View File

@ -34,11 +34,9 @@ class Gluegen(Package):
# patch for build with Fujitsu Compiler # patch for build with Fujitsu Compiler
patch('cpptasks.fj.patch', working_dir='ant-cpptasks', when='%fj') patch('cpptasks.fj.patch', working_dir='ant-cpptasks', when='%fj')
phases = ['build', 'install']
compiler_mapping = {'gcc': 'gcc', 'clang': 'clang', 'fj': 'fcc'} compiler_mapping = {'gcc': 'gcc', 'clang': 'clang', 'fj': 'fcc'}
def build(self, spec, prefix): def install(self, spec, prefix):
ant = spec['ant'].command ant = spec['ant'].command
cname = spec.compiler.name cname = spec.compiler.name
compiler = self.compiler_mapping.get(cname, 'gcc') compiler = self.compiler_mapping.get(cname, 'gcc')
@ -53,7 +51,6 @@ def build(self, spec, prefix):
with working_dir('make'): with working_dir('make'):
ant(*antarg) ant(*antarg)
def install(self, spec, prefix):
install_tree('build', prefix.build) install_tree('build', prefix.build)
install(join_path('ant-optional', 'optional-1.5.4.jar'), prefix.build) install(join_path('ant-optional', 'optional-1.5.4.jar'), prefix.build)
install_tree('make', prefix.make) install_tree('make', prefix.make)

View File

@ -6,7 +6,7 @@
from spack import * from spack import *
class Gnat(MakefilePackage): class Gnat(Package):
"""The GNAT Ada compiler. Ada is a modern programming language designed """The GNAT Ada compiler. Ada is a modern programming language designed
for large, long-lived applications - and embedded systems in particular for large, long-lived applications - and embedded systems in particular
- where reliability and efficiency are essential.""" - where reliability and efficiency are essential."""
@ -26,7 +26,5 @@ class Gnat(MakefilePackage):
version('2016', sha256='d083c01e054d0aeda7c67967306cfa5a8df12268664f9098a2d9b331aa24dfe7', extension='tar.gz', version('2016', sha256='d083c01e054d0aeda7c67967306cfa5a8df12268664f9098a2d9b331aa24dfe7', extension='tar.gz',
url="http://mirrors.cdn.adacore.com/art/5739cefdc7a447658e0b016b") url="http://mirrors.cdn.adacore.com/art/5739cefdc7a447658e0b016b")
phases = ['install']
def install(self, spec, prefix): def install(self, spec, prefix):
make('ins-all', 'prefix={0}'.format(prefix)) make('ins-all', 'prefix={0}'.format(prefix))

View File

@ -6,14 +6,15 @@
from spack import * from spack import *
class Hpgmg(Package): class Hpgmg(MakefilePackage):
"""HPGMG implements full multigrid (FMG) algorithms using finite-volume and """HPGMG implements full multigrid (FMG) algorithms using finite-volume and
finite-element methods. Different algorithmic variants adjust the finite-element methods.
arithmetic intensity and architectural properties that are tested. These
FMG methods converge up to discretization error in one F-cycle, thus may Different algorithmic variants adjust the arithmetic intensity and architectural
be considered direct solvers. An F-cycle visits the finest level a total properties that are tested. These FMG methods converge up to discretization
of two times, the first coarsening (8x smaller) 4 times, the second error in one F-cycle, thus may be considered direct solvers. An F-cycle visits
coarsening 6 times, etc. the finest level a total of two times, the first coarsening (8x smaller) 4 times,
the second coarsening 6 times, etc.
""" """
homepage = "https://bitbucket.org/hpgmg/hpgmg" homepage = "https://bitbucket.org/hpgmg/hpgmg"
@ -27,11 +28,9 @@ class Hpgmg(Package):
version('a0a5510df23b', sha256='b9c50f25e541428d4735fb07344d1d0ed9fc821bdde918d8e0defa78c0d9b4f9') version('a0a5510df23b', sha256='b9c50f25e541428d4735fb07344d1d0ed9fc821bdde918d8e0defa78c0d9b4f9')
version('0.3', sha256='12a65da216fec91daea78594ae4b5a069c8f1a700f1ba21eed9f45a79a68c793') version('0.3', sha256='12a65da216fec91daea78594ae4b5a069c8f1a700f1ba21eed9f45a79a68c793')
variant( variant('fe', default=False, description='Build finite element solver')
'fe', default=False, description='Build finite element solver') variant('fv', default='mpi', values=('serial', 'mpi', 'none'),
variant( description='Build finite volume solver with or without MPI support')
'fv', default='mpi', values=('serial', 'mpi', 'none'),
description='Build finite volume solver with or without MPI support')
variant('cuda', default=False, description='Build with CUDA') variant('cuda', default=False, description='Build with CUDA')
variant('debug', default=False, description='Build in debug mode') variant('debug', default=False, description='Build in debug mode')
@ -41,8 +40,6 @@ class Hpgmg(Package):
depends_on('cuda', when='+cuda') depends_on('cuda', when='+cuda')
depends_on('python', type='build') depends_on('python', type='build')
phases = ['configure', 'build', 'install']
def configure_args(self): def configure_args(self):
args = [] args = []
if '+fe' in self.spec and not ('@0.3' in self.spec): if '+fe' in self.spec and not ('@0.3' in self.spec):
@ -75,7 +72,7 @@ def configure_args(self):
return args return args
def configure(self, spec, prefix): def edit(self, spec, prefix):
python('configure', *self.configure_args()) python('configure', *self.configure_args())
def build(self, spec, prefix): def build(self, spec, prefix):

View File

@ -21,8 +21,6 @@ class Karma(Package):
depends_on('libx11', type=('build', 'run')) depends_on('libx11', type=('build', 'run'))
depends_on('libxaw', type=('build', 'run')) depends_on('libxaw', type=('build', 'run'))
phases = ['install']
resource( resource(
name='karma-linux', name='karma-linux',
url='ftp://ftp.atnf.csiro.au/pub/software/karma/karma-1.7.25-amd64_Linux_libc6.3.tar.bz2', url='ftp://ftp.atnf.csiro.au/pub/software/karma/karma-1.7.25-amd64_Linux_libc6.3.tar.bz2',

View File

@ -6,12 +6,10 @@
from llnl.util.filesystem import LibraryList from llnl.util.filesystem import LibraryList
class Libc(Package): class Libc(BundlePackage):
"""Dummy package to provide interfaces available in libc.""" """Dummy package to provide interfaces available in libc."""
homepage = "https://en.wikipedia.org/wiki/C_standard_library" homepage = "https://en.wikipedia.org/wiki/C_standard_library"
has_code = False
phases = []
version('1.0') # Dummy version('1.0') # Dummy