From bdf89087d9aa0fb318ecaa25b76a36cda5d98584 Mon Sep 17 00:00:00 2001 From: Alexey Shmalko Date: Thu, 18 Feb 2016 07:21:04 +0200 Subject: [PATCH] gdb: add multitarget option Multitarget option builds gdb with support for all targets. That's similar to gdb-multiarch package in Ubuntu or gdb with multitarget USE-flag in Gentoo. --- pkgs/development/tools/misc/gdb/default.nix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pkgs/development/tools/misc/gdb/default.nix b/pkgs/development/tools/misc/gdb/default.nix index 547f7a81ab6..cdef2ee58ca 100644 --- a/pkgs/development/tools/misc/gdb/default.nix +++ b/pkgs/development/tools/misc/gdb/default.nix @@ -3,6 +3,8 @@ , python ? null , guile ? null , target ? null +# Support all known targets in one gdb binary. +, multitarget ? false # Additional dependencies for GNU/Hurd. , mig ? null, hurd ? null @@ -47,6 +49,7 @@ stdenv.mkDerivation rec { "--with-separate-debug-dir=/run/current-system/sw/lib/debug" ] ++ optional (target != null) "--target=${target.config}" + ++ optional multitarget "--enable-targets=all" ++ optional (elem stdenv.system platforms.cygwin) "--without-python"; crossAttrs = { @@ -54,7 +57,9 @@ stdenv.mkDerivation rec { configureFlags = with stdenv.lib; [ "--with-gmp=${gmp.crossDrv}" "--with-mpfr=${mpfr.crossDrv}" "--with-system-readline" "--with-system-zlib" "--with-expat" "--with-libexpat-prefix=${expat.crossDrv}" "--without-python" - ] ++ optional (target != null) "--target=${target.config}"; + ] + ++ optional (target != null) "--target=${target.config}" + ++ optional multitarget "--enable-targets=all"; }; postInstall =