summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin/packages/binutils/package.py
diff options
context:
space:
mode:
Diffstat (limited to 'var/spack/repos/builtin/packages/binutils/package.py')
-rw-r--r--var/spack/repos/builtin/packages/binutils/package.py46
1 files changed, 25 insertions, 21 deletions
diff --git a/var/spack/repos/builtin/packages/binutils/package.py b/var/spack/repos/builtin/packages/binutils/package.py
index bf49ca9405..c3c521bad8 100644
--- a/var/spack/repos/builtin/packages/binutils/package.py
+++ b/var/spack/repos/builtin/packages/binutils/package.py
@@ -1,13 +1,13 @@
##############################################################################
-# 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.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-647188
#
-# For details, see https://github.com/llnl/spack
-# Please also see the LICENSE file for our notice and the LGPL.
+# For details, see https://github.com/spack/spack
+# Please also see the NOTICE and LICENSE files for our notice and the LGPL.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License (as
@@ -25,12 +25,13 @@
from spack import *
-class Binutils(Package):
+class Binutils(AutotoolsPackage):
"""GNU binutils, which contain the linker, assembler, objdump and others"""
homepage = "http://www.gnu.org/software/binutils/"
- url = "https://ftp.gnu.org/gnu/binutils/binutils-2.25.tar.bz2"
+ url = "https://ftp.gnu.org/gnu/binutils/binutils-2.28.tar.bz2"
+ version('2.28', '9e8340c96626b469a603c15c9d843727')
version('2.27', '2869c9bf3e60ee97c74ac2a6bf4e9d68')
version('2.26', '64146a0faa3b411ba774f47d41de239f')
version('2.25', 'd9f3303f802a5b6b0bb73a335ab89d66')
@@ -38,25 +39,26 @@ class Binutils(Package):
version('2.23.2', '4f8fa651e35ef262edc01d60fb45702e')
version('2.20.1', '2b9dc8f2b7dbd5ec5992c6e29de0b764')
- depends_on('m4', type='build')
- depends_on('flex', type='build')
- depends_on('bison', type='build')
-
- # Add a patch that creates binutils libiberty_pic.a which is preferred by
- # OpenSpeedShop and cbtf-krell
- variant('krellpatch', default=False,
- description="build with openspeedshop based patch.")
+ variant('plugins', default=False,
+ description="enable plugins, needed for gold linker")
variant('gold', default=True, description="build the gold linker")
- patch('binutilskrell-2.24.patch', when='@2.24+krellpatch')
+ variant('libiberty', default=False, description='Also install libiberty.')
patch('cr16.patch')
patch('update_symbol-2.26.patch', when='@2.26')
- variant('libiberty', default=False, description='Also install libiberty.')
+ depends_on('zlib')
+
+ depends_on('m4', type='build')
+ depends_on('flex', type='build')
+ depends_on('bison', type='build')
+ depends_on('gettext')
+
+ def configure_args(self):
+ spec = self.spec
- def install(self, spec, prefix):
configure_args = [
- '--prefix=%s' % prefix,
+ '--with-system-zlib',
'--disable-dependency-tracking',
'--disable-werror',
'--enable-interwork',
@@ -64,14 +66,16 @@ class Binutils(Package):
'--enable-shared',
'--enable-64-bit-bfd',
'--enable-targets=all',
- '--with-sysroot=/']
+ '--with-sysroot=/',
+ ]
if '+gold' in spec:
configure_args.append('--enable-gold')
+ if '+plugins' in spec:
+ configure_args.append('--enable-plugins')
+
if '+libiberty' in spec:
configure_args.append('--enable-install-libiberty')
- configure(*configure_args)
- make()
- make("install")
+ return configure_args