Bug 18113 - GDB 7.9 fails to build when makeinfo is not installed
Summary: GDB 7.9 fails to build when makeinfo is not installed
Status: RESOLVED DUPLICATE of bug 14678
Alias: None
Product: gdb
Classification: Unclassified
Component: build (show other bugs)
Version: 7.9
: P2 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
Depends on:
Reported: 2015-03-11 13:21 UTC by wpoely86
Modified: 2022-02-22 15:19 UTC (History)
5 users (show)

See Also:
Last reconfirmed:


Note You need to log in before you can comment on or make changes to this bug.
Description wpoely86 2015-03-11 13:21:22 UTC
This bug is more or less the same as https://sourceware.org/bugzilla/show_bug.cgi?id=14678 , only this one is for GDB 7.9.

If you don't have makeinfo installed, the make will fail:

make[5]: Entering directory `/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9/gdb/doc'
(test "ln -s" = "ln -s" && \
	  ln -s ./all-cfg.texi gdb-cfg.texi) || \
	ln ./all-cfg.texi gdb-cfg.texi || \
	cp ./all-cfg.texi gdb-cfg.texi
date=`sed -n -e 's/^.* BFD_VERSION_DATE \(.*\)$/\1/p' ./../../bfd/version.h`; \
	sed -e "s/DATE/$date/" < ./../version.in > version.subst
echo "@set GDBVN `sed q version.subst`" > ./GDBvn.new
if [ -n "(GDB) " ]; then \
	  echo "@set VERSION_PACKAGE (GDB) " >> ./GDBvn.new; \
echo "@set BUGURL @uref{http://www.gnu.org/software/gdb/bugs/}" >> ./GDBvn.new
if [ "@uref{http://www.gnu.org/software/gdb/bugs/}" = "@uref{http://www.gnu.org/software/gdb/bugs/}" ]; then \
	  echo "@set BUGURL_DEFAULT" >> ./GDBvn.new; \
if test -z "-I ./../../readline/doc"; then \
	  echo "@set SYSTEM_READLINE" >> ./GDBvn.new; \
if [ -n "" ]; then \
	  echo "@set SYSTEM_GDBINIT " >> ./GDBvn.new; \
mv GDBvn.new GDBvn.texi
/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9/missing makeinfo --split-size=5000000 --split-size=5000000   -I ./../../readline/doc -I ./../mi -I . \
		-o gdb.info ./gdb.texinfo
/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9/missing: line 81: makeinfo: command not found
WARNING: 'makeinfo' is missing on your system.
         You should only need it if you modified a '.texi' file, or
         any other file indirectly affecting the aspect of the manual.
         You might want to install the Texinfo package:
         The spurious makeinfo call might also be the consequence of
         using a buggy 'make' (AIX, DU, IRIX), in which case you might
         want to install GNU make:
make[5]: *** [gdb.info] Error 127
make[5]: Leaving directory `/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9/gdb/doc'
make[4]: *** [subdir_do] Error 1
make[4]: Leaving directory `/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9/gdb'
make[3]: *** [install-only] Error 2
make[3]: Leaving directory `/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9/gdb'
make[2]: *** [install] Error 2
make[2]: Leaving directory `/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9/gdb'
make[1]: *** [install-gdb] Error 2
make[1]: Leaving directory `/home/ward/tmp/eb_sandbox_20150311_13-46-46_buOYR/GDB/7.9/GCC-4.9.2/gdb-7.9'
make: *** [install] Error 2

This is because the missing script passes the return code (127) from the failed call to makeinfo to make. Setting MAKEINFO=true (or false) will not help because the configure script does a version check on makeinfo.
Comment 1 mephi42 2015-09-03 14:05:03 UTC
This also affects GDB 7.10. Here is the one-liner that reproduces the issue:

docker run -i -t centos:centos6 sh -c "yum -y install gcc make tar xz && curl http://ftp.gnu.org/gnu/gdb/gdb-7.10.tar.xz | tar -xJ && cd gdb-7.10 && ./configure && make && make install"

My workaround:

    echo '#!/bin/sh'                          >makeinfo && \
    echo 'echo "makeinfo (GNU texinfo) 5.2"' >>makeinfo && \
    chmod a+x makeinfo && \
    ./configure MAKEINFO=`realpath ./makeinfo` && \
    make && \
    make install
Comment 2 David Abdurachmanov 2015-09-03 14:11:13 UTC
Here is mine: https://github.com/cms-sw/cmsdist/blob/IB/CMSSW_7_6_X/next/gdb-disable-makeinfo.patch (probably not good for upstream)

Basically if MAKEINFO is true, keep it as-is and ignore resetting MAKEINFO to something else.
Comment 3 Keith Seitz 2016-05-17 17:29:44 UTC
Reclassifying to build/.
Comment 4 Tom Tromey 2022-02-22 15:19:03 UTC

*** This bug has been marked as a duplicate of bug 14678 ***