[Buildroot] [git commit branch/2021.02.x] package/gdb: append to dependencies in conditional

Peter Korsgaard peter at korsgaard.com
Sun Oct 10 10:04:39 UTC 2021


commit: https://git.buildroot.net/buildroot/commit/?id=31a3f734c97520795cc4d5cfe26b1fc06a5bb254
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/2021.02.x

Repeat after me: "Forcing the value of <pkg>_DEPENDENCIES inside a
conditional is the root of all evil."

Repeat after me: "Forcing the value of <pkg>_DEPENDENCIES inside a
conditional is the root of all evil."

Repeat after me: "Forcing the value of <pkg>_DEPENDENCIES inside a
conditional is the root of all evil."

Repeat after me: "Forcing the value of <pkg>_DEPENDENCIES inside a
conditional is the root of all evil."

Enough? :-)

Due to this mistake, any other GDB_DEPENDENCIES defined before this
assignment were lost. For example, the host-flex host-bison added
inside the GDB_FROM_GIT==y condition were ignored if
BR2_PACKAGE_GDB_DEBUGGER.

Fixes the build of all ARC configurations that have
BR2_PACKAGE_GDB_DEBUGGER enabled.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni at bootlin.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998 at free.fr>
(cherry picked from commit 97f3ad7af3dd54a15a10aa35786e7fa08cf5e7b1)
Signed-off-by: Peter Korsgaard <peter at korsgaard.com>
---
 package/gdb/gdb.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package/gdb/gdb.mk b/package/gdb/gdb.mk
index 17e10e8b16..e69dabd757 100644
--- a/package/gdb/gdb.mk
+++ b/package/gdb/gdb.mk
@@ -156,7 +156,7 @@ ifeq ($(BR2_PACKAGE_GDB_DEBUGGER),y)
 GDB_CONF_OPTS += \
 	--enable-gdb \
 	--with-curses
-GDB_DEPENDENCIES = ncurses \
+GDB_DEPENDENCIES += ncurses \
 	$(if $(BR2_PACKAGE_LIBICONV),libiconv)
 else
 GDB_CONF_OPTS += \


More information about the buildroot mailing list