Skip to contentSkip to conversation

package/gdb: fix shared-only build

PATCH New Romain Naour 3 participants 3 messages Dec 17, 2014 – Dec 21, 2014

lore
Share & tools
lore
#0 lore raw

PATCH v4 1/1 package/gdb: fix shared-only build

The shared build only of gdb is actually not supported.

When --disable-static is given to the gdb's main configure script, it also disable the static build of bundled libraries like bfd, readline and opcodes, which must be build statically.

Force the static build of bundled libraries by adding --enable-static in GDB_CONF_OPTS.

Fixes:
http://autobuild.buildroot.net/results/219/21979e730dca1fce5bdda9a4c7fad4485e788866/
http://autobuild.buildroot.net/results/c10/c1096d0bd22de5c6feba848f743601ad0416a944/
http://autobuild.buildroot.net/results/d8a/d8a5bcc7fa374fb0c916a9d0f33ef283109cb404/
http://autobuild.buildroot.net/results/22a/22a86d0f1df0fc4698c0f734f3d659e6317404a4/
http://autobuild.buildroot.net/results/404/404e61e5c30040ee5756f4b5839149dca38660d4/

And many more.

---
v4: Fix typos (ThomasP)
v3: Add a comment in gdb.mk (ThomasP)
v2: D'ont patch gdb, just enable static build.

---
 package/gdb/gdb.mk | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
package/gdb/gdb.mk +4 -1
index dbec760..aa22193 100644
@@ -74,6 +74,8 @@ GDB_CONF_ENV = \
 	bash_cv_have_mbstate_t=yes \
 	gdb_cv_func_sigsetjmp=yes
 
+# The shared only build is not supported by gdb, so enable static build for
+# build-in libraries with --enable-static.
 GDB_CONF_OPTS = \
 	--without-uiout \
 	--disable-gdbtk \
@@ -83,7 +85,8 @@ GDB_CONF_OPTS = \
 	$(if $(BR2_PACKAGE_GDB_SERVER),--enable-gdbserver) \
 	--with-curses \
 	--without-included-gettext \
-	--disable-werror
+	--disable-werror \
+	--enable-static
 
 ifeq ($(BR2_PACKAGE_GDB_TUI),y)
 	GDB_CONF_OPTS += --enable-tui
Signature · 1 line
1.9.3
#1 lore raw

PATCH v4 1/1 package/gdb: fix shared-only build

Romain, All,

On 2014-12-17 22:37 +0100, Romain Naour spake thusly:

Quoted 16 lines

The shared build only of gdb is actually not supported.

When --disable-static is given to the gdb's main configure script, it also disable the static build of bundled libraries like bfd, readline and opcodes, which must be build statically.

Force the static build of bundled libraries by adding --enable-static in GDB_CONF_OPTS.

Fixes:
http://autobuild.buildroot.net/results/219/21979e730dca1fce5bdda9a4c7fad4485e788866/
http://autobuild.buildroot.net/results/c10/c1096d0bd22de5c6feba848f743601ad0416a944/
http://autobuild.buildroot.net/results/d8a/d8a5bcc7fa374fb0c916a9d0f33ef283109cb404/
http://autobuild.buildroot.net/results/22a/22a86d0f1df0fc4698c0f734f3d659e6317404a4/
http://autobuild.buildroot.net/results/404/404e61e5c30040ee5756f4b5839149dca38660d4/

Quoted 3 lines

And many more.

This is starting to bug some real users, as recently reported on the IRC channel.

Regards,
Yann E. MORIN.

Quoted 38 lines

---
v4: Fix typos (ThomasP)
v3: Add a comment in gdb.mk (ThomasP)
v2: D'ont patch gdb, just enable static build.

---
 package/gdb/gdb.mk | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
package/gdb/gdb.mk +4 -1
index dbec760..aa22193 100644
@@ -74,6 +74,8 @@ GDB_CONF_ENV = \
 	bash_cv_have_mbstate_t=yes \
 	gdb_cv_func_sigsetjmp=yes
 
+# The shared only build is not supported by gdb, so enable static build for
+# build-in libraries with --enable-static.
 GDB_CONF_OPTS = \
 	--without-uiout \
 	--disable-gdbtk \
@@ -83,7 +85,8 @@ GDB_CONF_OPTS = \
 	$(if $(BR2_PACKAGE_GDB_SERVER),--enable-gdbserver) \
 	--with-curses \
 	--without-included-gettext \
-	--disable-werror
+	--disable-werror \
+	--enable-static
 
 ifeq ($(BR2_PACKAGE_GDB_TUI),y)
 	GDB_CONF_OPTS += --enable-tui
Signature · 6 lines
1.9.3

_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
#2 lore raw

PATCH v4 1/1 package/gdb: fix shared-only build

In reply to Romain Naour

Dear Romain Naour,

Quoted 16 lines · Romain Naour

The shared build only of gdb is actually not supported.

When --disable-static is given to the gdb's main configure script, it also disable the static build of bundled libraries like bfd, readline and opcodes, which must be build statically.

Force the static build of bundled libraries by adding --enable-static in GDB_CONF_OPTS.

Fixes:
http://autobuild.buildroot.net/results/219/21979e730dca1fce5bdda9a4c7fad4485e788866/
http://autobuild.buildroot.net/results/c10/c1096d0bd22de5c6feba848f743601ad0416a944/
http://autobuild.buildroot.net/results/d8a/d8a5bcc7fa374fb0c916a9d0f33ef283109cb404/
http://autobuild.buildroot.net/results/22a/22a86d0f1df0fc4698c0f734f3d659e6317404a4/
http://autobuild.buildroot.net/results/404/404e61e5c30040ee5756f4b5839149dca38660d4/

Quoted 3 lines

And many more.

Applied, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com