48 lines
1.4 KiB
Diff
48 lines
1.4 KiB
Diff
From: Andreas Fenkart <andreas.fenkart@digitalstrom.com>
|
|
Date: Fri, 25 Mar 2016 14:52:19 +0100
|
|
Subject: [PATCH] tools: env: bug: config structs must be defined in tools
|
|
library
|
|
|
|
fw_senten/fw_printenv can be compiled as a tools library,
|
|
excluding the fw_env_main object.
|
|
|
|
Reported-by: Stefano Babic <sbabic@denx.de>
|
|
Signed-off-by: Andreas Fenkart <andreas.fenkart@digitalstrom.com>
|
|
(cherry picked from commit 43cb65b7a00e4759427a6e4b8a02039e43dab5a5)
|
|
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
|
|
---
|
|
tools/env/fw_env.c | 4 ++++
|
|
tools/env/fw_env_main.c | 4 ----
|
|
2 files changed, 4 insertions(+), 4 deletions(-)
|
|
|
|
diff --git a/tools/env/fw_env.c b/tools/env/fw_env.c
|
|
index ee17a6901609..2533dc4eec2b 100644
|
|
--- a/tools/env/fw_env.c
|
|
+++ b/tools/env/fw_env.c
|
|
@@ -34,6 +34,10 @@
|
|
|
|
#include "fw_env.h"
|
|
|
|
+struct common_args common_args;
|
|
+struct printenv_args printenv_args;
|
|
+struct setenv_args setenv_args;
|
|
+
|
|
#define DIV_ROUND_UP(n, d) (((n) + (d) - 1) / (d))
|
|
|
|
#define WHITESPACE(c) ((c == '\t') || (c == ' '))
|
|
diff --git a/tools/env/fw_env_main.c b/tools/env/fw_env_main.c
|
|
index 4bd4216625aa..3065de962272 100644
|
|
--- a/tools/env/fw_env_main.c
|
|
+++ b/tools/env/fw_env_main.c
|
|
@@ -49,10 +49,6 @@ static struct option long_options[] = {
|
|
{NULL, 0, NULL, 0}
|
|
};
|
|
|
|
-struct common_args common_args;
|
|
-struct printenv_args printenv_args;
|
|
-struct setenv_args setenv_args;
|
|
-
|
|
void usage_printenv(void)
|
|
{
|
|
|