diff options
author | Ludovic Courtès <ludo@gnu.org> | 2012-12-15 00:06:09 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2012-12-15 00:06:09 +0100 |
commit | da30f55582c53966130ebe814ba084ff7b60fb6a (patch) | |
tree | dbf48406f0332b53d29fb226aacffb260f9abc8b /nix/nix-daemon | |
parent | 335dd762ccf757916939886003068e6f9111a47a (diff) | |
download | guix-da30f55582c53966130ebe814ba084ff7b60fb6a.tar guix-da30f55582c53966130ebe814ba084ff7b60fb6a.tar.gz |
daemon: Add `--debug' option.
* nix/nix-daemon/guix-daemon.cc (GUIX_OPT_DEBUG): New macro.
(options): Add `--debug'.
(parse_opt): Set `verbosity' upon GUIX_OPT_DEBUG.
Diffstat (limited to 'nix/nix-daemon')
-rw-r--r-- | nix/nix-daemon/guix-daemon.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/nix/nix-daemon/guix-daemon.cc b/nix/nix-daemon/guix-daemon.cc index 1cb0987193..79c719399e 100644 --- a/nix/nix-daemon/guix-daemon.cc +++ b/nix/nix-daemon/guix-daemon.cc @@ -21,6 +21,7 @@ #include <types.hh> #include "shared.hh" #include <globals.hh> +#include <util.hh> #include <stdlib.h> #include <argp.h> @@ -56,6 +57,7 @@ builds derivations on behalf of its clients."; #define GUIX_OPT_DISABLE_LOG_COMPRESSION 6 #define GUIX_OPT_DISABLE_STORE_OPTIMIZATION 7 #define GUIX_OPT_IMPERSONATE_LINUX_26 8 +#define GUIX_OPT_DEBUG 9 static const struct argp_option options[] = { @@ -88,6 +90,8 @@ static const struct argp_option options[] = " (this option has no effect in this configuration)" #endif }, + { "debug", GUIX_OPT_DEBUG, 0, 0, + "Produce debugging output" }, { 0, 0, 0, 0, 0 } }; @@ -118,6 +122,9 @@ parse_opt (int key, char *arg, struct argp_state *state) case GUIX_OPT_LOSE_LOGS: settings.keepLog = false; break; + case GUIX_OPT_DEBUG: + verbosity = lvlDebug; + break; case 'C': settings.buildCores = atoi (arg); break; |