Skip to contentSkip to conversation

gdb: get rid of host-texinfo dependency

PATCH New Thomas De Schampheleire 3 participants 9 messages Oct 11, 2016 – Oct 14, 2016

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/3 gdb: get rid of host-texinfo dependency

From: Thomas De Schampheleire <[email protected]>

The host-texinfo dependency in gdb/host-gdb was added because gdb insisted in building info documentation in recent versions, and we want to avoid 'makeinfo' to be present on the build system.

However, there is another solution that does not require actually building
host-texinfo: instruct the makefiles to use a dummy makeinfo command ('true').

---
 package/gdb/gdb.mk | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

v2: use INSTALL_TARGET_OPTS for target packages iso INSTALL_OPTS (INSTALL_STAGING_OPTS not needed: INSTALL_STAGING != YES)
v3: fix INSTALL_TARGET_OPTS to include the actual 'install' make target

package/gdb/gdb.mk +5 -6
index 1c778e9..68a91f1 100644
@@ -37,12 +37,11 @@ endif
 # also need ncurses.
 HOST_GDB_DEPENDENCIES = host-expat host-ncurses
 
-# Starting with gdb 7.10, gdb wants to re-generate its documentation.
-# We were trying to avoid that by patching the Makefiles, but it wasn't
-# working in all situations. So, we simply add a dependency on
-# host-texinfo in all case.
-GDB_DEPENDENCIES += host-texinfo
-HOST_GDB_DEPENDENCIES += host-texinfo
+# Disable building documentation
+GDB_MAKE_OPTS += MAKEINFO=true
+GDB_INSTALL_TARGET_OPTS += DESTDIR=$(TARGET_DIR) MAKEINFO=true install
+HOST_GDB_MAKE_OPTS += MAKEINFO=true
+HOST_GDB_INSTALL_OPTS += MAKEINFO=true install
 
 # Apply the Xtensa specific patches
 XTENSA_CORE_NAME = $(call qstrip, $(BR2_XTENSA_CORE_NAME))
Signature · 1 line
2.7.3
#1 lore raw

PATCH v3 2/3 binutils: get rid of host-texinfo dependency and other documentation tricks

From: Thomas De Schampheleire <[email protected]>

The binutils/host-binutils package applied several tricks to avoid building info documentation. In the worst case, host-texinfo is added as dependency.

However, there is a simpler solution that removes the need for all these
tricks: instruct the makefiles to use a dummy makeinfo command ('true').

---
 package/binutils/binutils.mk | 25 +++++++++----------------
 1 file changed, 9 insertions(+), 16 deletions(-)

v2: use INSTALL_TARGET_OPTS for target packages iso INSTALL_OPTS (INSTALL_STAGING_OPTS not needed: custom limited staging install)
v3: fix INSTALL_TARGET_OPTS to include the actual 'install' make target

package/binutils/binutils.mk +9 -16
index 3a4a661..966cc79 100644
@@ -29,19 +29,8 @@ BINUTILS_LICENSE = GPLv3+, libiberty LGPLv2.1+
 BINUTILS_LICENSE_FILES = COPYING3 COPYING.LIB
 
 ifeq ($(BINUTILS_FROM_GIT),y)
-BINUTILS_DEPENDENCIES += host-flex host-bison host-texinfo
-HOST_BINUTILS_DEPENDENCIES += host-flex host-bison host-texinfo
-endif
-
-# The .info files in the >= 2.26 tarball have an incorrect timestamp,
-# so binutils tries to re-generate them. In order to avoid the
-# dependency on host-texinfo, we simply update the timestamps.
-ifeq ($(BR2_BINUTILS_VERSION_2_26_X)$(BR2_BINUTILS_VERSION_2_27_X),y)
-define BINUTILS_FIXUP_INFO_TIMESTAMPS
-	find $(@D) -name '*.info' -exec touch {} \;
-endef
-BINUTILS_POST_PATCH_HOOKS += BINUTILS_FIXUP_INFO_TIMESTAMPS
-HOST_BINUTILS_POST_PATCH_HOOKS += BINUTILS_FIXUP_INFO_TIMESTAMPS
+BINUTILS_DEPENDENCIES += host-flex host-bison
+HOST_BINUTILS_DEPENDENCIES += host-flex host-bison
 endif
 
 # When binutils sources are fetched from the binutils-gdb repository,
@@ -68,8 +57,12 @@ endif
 
 # Don't build documentation. It takes up extra space / build time,
 # and sometimes needs specific makeinfo versions to work
-BINUTILS_CONF_ENV += ac_cv_prog_MAKEINFO=missing
-HOST_BINUTILS_CONF_ENV += ac_cv_prog_MAKEINFO=missing
+BINUTILS_CONF_ENV += MAKEINFO=true
+BINUTILS_MAKE_OPTS += MAKEINFO=true
+BINUTILS_INSTALL_TARGET_OPTS = DESTDIR=$(TARGET_DIR) MAKEINFO=true install
+HOST_BINUTILS_CONF_ENV += MAKEINFO=true
+HOST_BINUTILS_MAKE_OPTS += MAKEINFO=true
+HOST_BINUTILS_INSTALL_OPTS += MAKEINFO=true install
 
 # gcc bug with Os/O2/O3, PR77311
 # error: unable to find a register to spill in class 'CCREGS'
@@ -109,7 +102,7 @@ HOST_BINUTILS_CONF_OPTS = \
 # binutils run configure script of subdirs at make time, so ensure
 # our TARGET_CONFIGURE_ARGS are taken into consideration for those
 define BINUTILS_BUILD_CMDS
-	$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_ARGS) $(MAKE) -C $(@D)
+	$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_ARGS) $(MAKE) $(BINUTILS_MAKE_OPTS) -C $(@D)
 endef
 
 # We just want libbfd, libiberty and libopcodes,
Signature · 1 line
2.7.3
#2 lore raw

PATCH v3 2/3 binutils: get rid of host-texinfo dependency and other documentation tricks

Hi Thomas,

Le 11/10/2016 ? 14:02, Thomas De Schampheleire a ?crit :

Quoted 45 lines

From: Thomas De Schampheleire <[email protected]>

The binutils/host-binutils package applied several tricks to avoid building info documentation. In the worst case, host-texinfo is added as dependency.

However, there is a simpler solution that removes the need for all these
tricks: instruct the makefiles to use a dummy makeinfo command ('true').

---
 package/binutils/binutils.mk | 25 +++++++++----------------
 1 file changed, 9 insertions(+), 16 deletions(-)

v2: use INSTALL_TARGET_OPTS for target packages iso INSTALL_OPTS (INSTALL_STAGING_OPTS not needed: custom limited staging install)
v3: fix INSTALL_TARGET_OPTS to include the actual 'install' make target

package/binutils/binutils.mk +2 -13
index 3a4a661..966cc79 100644
@@ -29,19 +29,8 @@ BINUTILS_LICENSE = GPLv3+, libiberty LGPLv2.1+
 BINUTILS_LICENSE_FILES = COPYING3 COPYING.LIB
 
 ifeq ($(BINUTILS_FROM_GIT),y)
-BINUTILS_DEPENDENCIES += host-flex host-bison host-texinfo
-HOST_BINUTILS_DEPENDENCIES += host-flex host-bison host-texinfo
-endif
-
-# The .info files in the >= 2.26 tarball have an incorrect timestamp,
-# so binutils tries to re-generate them. In order to avoid the
-# dependency on host-texinfo, we simply update the timestamps.
-ifeq ($(BR2_BINUTILS_VERSION_2_26_X)$(BR2_BINUTILS_VERSION_2_27_X),y)
-define BINUTILS_FIXUP_INFO_TIMESTAMPS
-	find $(@D) -name '*.info' -exec touch {} \;
-endef
-BINUTILS_POST_PATCH_HOOKS += BINUTILS_FIXUP_INFO_TIMESTAMPS
-HOST_BINUTILS_POST_PATCH_HOOKS += BINUTILS_FIXUP_INFO_TIMESTAMPS
+BINUTILS_DEPENDENCIES += host-flex host-bison
+HOST_BINUTILS_DEPENDENCIES += host-flex host-bison
 endif
 
 # When binutils sources are fetched from the binutils-gdb repository,
@@ -68,8 +57,12 @@ endif
 

package/binutils/binutils.mk endif · line 65

Quoted 10 lines
package/binutils/binutils.mk +6 -2
 # Don't build documentation. It takes up extra space / build time,
 # and sometimes needs specific makeinfo versions to work
-BINUTILS_CONF_ENV += ac_cv_prog_MAKEINFO=missing
-HOST_BINUTILS_CONF_ENV += ac_cv_prog_MAKEINFO=missing
+BINUTILS_CONF_ENV += MAKEINFO=true
+BINUTILS_MAKE_OPTS += MAKEINFO=true
+BINUTILS_INSTALL_TARGET_OPTS = DESTDIR=$(TARGET_DIR) MAKEINFO=true install
+HOST_BINUTILS_CONF_ENV += MAKEINFO=true
+HOST_BINUTILS_MAKE_OPTS += MAKEINFO=true
+HOST_BINUTILS_INSTALL_OPTS += MAKEINFO=true install

Best regards,
Romain

Quoted 13 lines
package/binutils/binutils.mk +1 -1
 # gcc bug with Os/O2/O3, PR77311
 # error: unable to find a register to spill in class 'CCREGS'
@@ -109,7 +102,7 @@ HOST_BINUTILS_CONF_OPTS = \
 # binutils run configure script of subdirs at make time, so ensure
 # our TARGET_CONFIGURE_ARGS are taken into consideration for those
 define BINUTILS_BUILD_CMDS
-	$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_ARGS) $(MAKE) -C $(@D)
+	$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_ARGS) $(MAKE) $(BINUTILS_MAKE_OPTS) -C $(@D)
 endef
 
 # We just want libbfd, libiberty and libopcodes,
#3 lore raw

PATCH v3 2/3 binutils: get rid of host-texinfo dependency and other documentation tricks

In reply to Thomas De Schampheleire
Quoted 10 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Thomas" == Thomas De Schampheleire <[email protected]> writes:

From: Thomas De Schampheleire <[email protected]> The binutils/host-binutils package applied several tricks to avoid building info documentation. In the worst case, host-texinfo is added as dependency.

However, there is a simpler solution that removes the need for all these
tricks: instruct the makefiles to use a dummy makeinfo command ('true').

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard
#4 lore raw

PATCH v3 3/3 Revert "texinfo: new host package"

In reply to Thomas De Schampheleire

From: Thomas De Schampheleire <[email protected]>

This reverts commit ea161cf6891c3a3a601dfce072f68ee4aed08d21.

The host-texinfo dependency is no longer used by any package, after using another solution to the problem that required its introduction in the first place.

---
 package/texinfo/texinfo.hash |  2 --
 package/texinfo/texinfo.mk   | 13 -------------
 2 files changed, 15 deletions(-)
 delete mode 100644 package/texinfo/texinfo.hash
 delete mode 100644 package/texinfo/texinfo.mk

v2/v3: no changes

package/texinfo/texinfo.hash deleted +0 -2
deleted file mode 100644
index 4bdf343..0000000
@@ -1,2 +0,0 @@
-# Locally calculated
-sha256 ac68394ce21b2420ba7ed7cec65d84aacf308cc88e9bf4716fcfff88286883d2 texinfo-6.1.tar.xz
package/texinfo/texinfo.mk deleted +0 -13
deleted file mode 100644
index ebd0b48..0000000
@@ -1,13 +0,0 @@
-################################################################################
-#
-# texinfo
-#
-################################################################################
-
-TEXINFO_VERSION = 6.1
-TEXINFO_SITE = $(BR2_GNU_MIRROR)/texinfo
-TEXINFO_SOURCE = texinfo-$(TEXINFO_VERSION).tar.xz
-TEXINFO_LICENSE = GPLv3+
-TEXINFO_LICENSE_FILES = COPYING
-
-$(eval $(host-autotools-package))
Signature · 1 line
2.7.3
#5 lore raw

PATCH v3 3/3 Revert "texinfo: new host package"

Hi Thomas,

Le 11/10/2016 ? 14:02, Thomas De Schampheleire a ?crit :

Quoted 9 lines

From: Thomas De Schampheleire <[email protected]>

This reverts commit ea161cf6891c3a3a601dfce072f68ee4aed08d21.

The host-texinfo dependency is no longer used by any package, after using another solution to the problem that required its introduction in the first place.

Best regards,
Romain

Quoted 37 lines
---
 package/texinfo/texinfo.hash |  2 --
 package/texinfo/texinfo.mk   | 13 -------------
 2 files changed, 15 deletions(-)
 delete mode 100644 package/texinfo/texinfo.hash
 delete mode 100644 package/texinfo/texinfo.mk

v2/v3: no changes

package/texinfo/texinfo.hash deleted +0 -2
deleted file mode 100644
index 4bdf343..0000000
@@ -1,2 +0,0 @@
-# Locally calculated
-sha256 ac68394ce21b2420ba7ed7cec65d84aacf308cc88e9bf4716fcfff88286883d2 texinfo-6.1.tar.xz
package/texinfo/texinfo.mk deleted +0 -13
deleted file mode 100644
index ebd0b48..0000000
@@ -1,13 +0,0 @@
-################################################################################
-#
-# texinfo
-#
-################################################################################
-
-TEXINFO_VERSION = 6.1
-TEXINFO_SITE = $(BR2_GNU_MIRROR)/texinfo
-TEXINFO_SOURCE = texinfo-$(TEXINFO_VERSION).tar.xz
-TEXINFO_LICENSE = GPLv3+
-TEXINFO_LICENSE_FILES = COPYING
-
-$(eval $(host-autotools-package))
#6 lore raw

PATCH v3 3/3 Revert "texinfo: new host package"

In reply to Thomas De Schampheleire
Quoted 10 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Thomas" == Thomas De Schampheleire <[email protected]> writes:

From: Thomas De Schampheleire <[email protected]> This reverts commit ea161cf6891c3a3a601dfce072f68ee4aed08d21.

The host-texinfo dependency is no longer used by any package, after using another solution to the problem that required its introduction in the first place.

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard
#7 lore raw

PATCH v3 1/3 gdb: get rid of host-texinfo dependency

In reply to Thomas De Schampheleire

Hi Thomas,

Le 11/10/2016 ? 14:02, Thomas De Schampheleire a ?crit :

Quoted 24 lines

From: Thomas De Schampheleire <[email protected]>

The host-texinfo dependency in gdb/host-gdb was added because gdb insisted in building info documentation in recent versions, and we want to avoid 'makeinfo' to be present on the build system.

However, there is another solution that does not require actually building
host-texinfo: instruct the makefiles to use a dummy makeinfo command ('true').

---
 package/gdb/gdb.mk | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

v2: use INSTALL_TARGET_OPTS for target packages iso INSTALL_OPTS (INSTALL_STAGING_OPTS not needed: INSTALL_STAGING != YES)
v3: fix INSTALL_TARGET_OPTS to include the actual 'install' make target

package/gdb/gdb.mk +0 -0
index 1c778e9..68a91f1 100644

package/gdb/gdb.mk endif · line 40

Quoted 10 lines
package/gdb/gdb.mk +1 -6
@@ -37,12 +37,11 @@ endif
 # also need ncurses.
 HOST_GDB_DEPENDENCIES = host-expat host-ncurses
 
-# Starting with gdb 7.10, gdb wants to re-generate its documentation.
-# We were trying to avoid that by patching the Makefiles, but it wasn't
-# working in all situations. So, we simply add a dependency on
-# host-texinfo in all case.
-GDB_DEPENDENCIES += host-texinfo
-HOST_GDB_DEPENDENCIES += host-texinfo
+# Disable building documentation

This part doesn't apply on master, it seems you're not working on the latest master :p

package/gdb/gdb.mk endif · line 44

Quoted 4 lines
package/gdb/gdb.mk +4 -0
+GDB_MAKE_OPTS += MAKEINFO=true
+GDB_INSTALL_TARGET_OPTS += DESTDIR=$(TARGET_DIR) MAKEINFO=true install
+HOST_GDB_MAKE_OPTS += MAKEINFO=true
+HOST_GDB_INSTALL_OPTS += MAKEINFO=true install

Otherwise ok with the changes.

Best regards,
Romain

Quoted 4 lines
package/gdb/gdb.mk +0 -0
 # Apply the Xtensa specific patches
 XTENSA_CORE_NAME = $(call qstrip, $(BR2_XTENSA_CORE_NAME))
 
#8 lore raw

PATCH v3 1/3 gdb: get rid of host-texinfo dependency

In reply to Thomas De Schampheleire
Quoted 11 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Thomas" == Thomas De Schampheleire <[email protected]> writes:

From: Thomas De Schampheleire <[email protected]> The host-texinfo dependency in gdb/host-gdb was added because gdb insisted in building info documentation in recent versions, and we want to avoid 'makeinfo' to be present on the build system.

However, there is another solution that does not require actually building
host-texinfo: instruct the makefiles to use a dummy makeinfo command ('true').

Quoted 8 lines
---
 package/gdb/gdb.mk | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

v2: use INSTALL_TARGET_OPTS for target packages iso INSTALL_OPTS (INSTALL_STAGING_OPTS not needed: INSTALL_STAGING != YES)
v3: fix INSTALL_TARGET_OPTS to include the actual 'install' make target

As Thomas already applied your earlier version, I've instead added a patch to add back the 'install'.

Signature · 1 line
Bye, Peter Korsgaard