summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/gdb/package.py28
1 files changed, 12 insertions, 16 deletions
diff --git a/var/spack/repos/builtin/packages/gdb/package.py b/var/spack/repos/builtin/packages/gdb/package.py
index aabb553dce..f1413c7140 100644
--- a/var/spack/repos/builtin/packages/gdb/package.py
+++ b/var/spack/repos/builtin/packages/gdb/package.py
@@ -19,6 +19,7 @@ class Gdb(AutotoolsPackage, GNUMirrorPackage):
maintainers("robertu94")
+ version("13.1", sha256="4cc3d7143d6d54d289d227b1e7289dbc0fa4cbd46131ab87136e1ea831cf46d4")
version("12.1", sha256="87296a3a9727356b56712c793704082d5df0ff36a34ca9ec9734fc9a8bdfdaab")
version("11.2", sha256="b558b66084835e43b6361f60d60d314c487447419cdf53adf83a87020c367290")
version("11.1", sha256="cc2903474e965a43d09c3b263952d48ced39dd22ce2d01968f3aa181335fcb9c")
@@ -45,6 +46,7 @@ class Gdb(AutotoolsPackage, GNUMirrorPackage):
variant("gold", default=False, description="Enable gold linker")
variant("ld", default=False, description="Enable ld")
variant("tui", default=False, description="Enable tui")
+ variant("debuginfod", default=True, description="Enable debuginfod support", when="@10.1:")
# Resolves the undefined references to libintl_gettext while linking gdbserver
# https://www.gnu.org/software/gettext/FAQ.html#integrating_undefined
@@ -80,11 +82,20 @@ class Gdb(AutotoolsPackage, GNUMirrorPackage):
depends_on("source-highlight", when="+source-highlight")
depends_on("ncurses", when="+tui")
depends_on("gmp", when="@11.1:")
+ depends_on("elfutils@0.178:+debuginfod", when="@11.1:+debuginfod")
build_directory = "spack-build"
def configure_args(self):
- args = ["--with-system-gdbinit={0}".format(self.prefix.etc.gdbinit)]
+ args = [
+ "--with-system-gdbinit={0}".format(self.prefix.etc.gdbinit),
+ *self.enable_or_disable("lto"),
+ *self.with_or_without("quad"),
+ *self.enable_or_disable("gold"),
+ *self.enable_or_disable("ld"),
+ *self.enable_or_disable("tui"),
+ *self.with_or_without("debuginfod"),
+ ]
if self.spec.version >= Version("11.1"):
args.append("--with-gmp={0}".format(self.spec["gmp"].prefix))
@@ -93,21 +104,6 @@ class Gdb(AutotoolsPackage, GNUMirrorPackage):
args.append("--with-python={0}".format(self.spec["python"].command))
args.append("LDFLAGS={0}".format(self.spec["python"].libs.ld_flags))
- if "+lto" in self.spec:
- args.append("--enable-lto")
-
- if "+quad" in self.spec:
- args.append("--with-quad")
-
- if "+gold" in self.spec:
- args.append("--enable-gold")
-
- if "+ld" in self.spec:
- args.append("--enable-ld")
-
- if "+tui" in self.spec:
- args.append("--enable-tui")
-
return args
@run_after("install")