Bug 14678 - GDB 7.5 fails to build unless makeinfo is installed
Summary: GDB 7.5 fails to build unless makeinfo is installed
Status: RESOLVED FIXED
Alias: None
Product: gdb
Classification: Unclassified
Component: build (show other bugs)
Version: 7.5
: P2 normal
Target Milestone: 11.1
Assignee: Not yet assigned to anyone
URL:
Keywords:
: 17268 18113 20417 22092 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-10-06 19:17 UTC by psmith
Modified: 2022-10-19 04:02 UTC (History)
10 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description psmith 2012-10-06 19:17:21 UTC
I've seen various bugs against earlier releases of GDB stating that they would not build on systems where makeinfo is not installed, but they were supposed to be fixed in the current GDB releases.  So there is a new build failure with GDB 7.5, which will not build properly on systems without makeinfo installed.

It appears that gdb.info is depending on the generated file GDBvn.texi, but that file is not provided in the GDB 7.5 distribution.  As a result make rebuilds it, and as a result of THAT it wants to rebuild gdb.info but this of course fails if makeinfo is not available:

make[7]: Entering directory `/usr/src/cc/obj/f/gdb.i686/gdb/doc'
(test "ln -s" = "ln -s" && \
  ln -s /usr/src/cc/gdb-7.5/gdb/doc/all-cfg.texi gdb-cfg.texi) || \
ln /usr/src/cc/gdb-7.5/gdb/doc/all-cfg.texi gdb-cfg.texi || \
cp /usr/src/cc/gdb-7.5/gdb/doc/all-cfg.texi gdb-cfg.texi
echo "@set GDBVN `sed q /usr/src/cc/gdb-7.5/gdb/doc/../version.in`" > ./GDBvn.new
if [ -n "(GDB) " ]; then \
  echo "@set VERSION_PACKAGE (GDB) " >> ./GDBvn.new; \
fi
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; \
fi
if test -z "-I /usr/src/cc/gdb-7.5/gdb/doc/../../readline/doc"; then \
  echo "@set SYSTEM_READLINE" >> ./GDBvn.new; \
fi
mv GDBvn.new GDBvn.texi
/usr/src/cc/gdb-7.5/missing makeinfo --split-size=5000000 --split-size=5000000   -I /usr/src/cc/gdb-7.5/gdb/doc/../../readline/doc -I /usr/src/cc/gdb-7.5/gdb/doc/../mi -I /usr/src/cc/gdb-7.5/gdb/doc \
	-o gdb.info /usr/src/cc/gdb-7.5/gdb/doc/gdb.texinfo
WARNING: `makeinfo' is missing on your system.  You should only need it if
         you modified a `.texi' or `.texinfo' file, or any other file
         indirectly affecting the aspect of the manual.  The spurious
         call might also be the consequence of using a buggy `make' (AIX,
         DU, IRIX).  You might want to install the `Texinfo' package or
         the `GNU make' package.  Grab either from any GNU archive site.
make[7]: *** [gdb.info] Error 1
Comment 1 Pedro Alves 2013-01-02 18:57:16 UTC
I just tried 7.5.1 (with 'configure MAKEINFO=false'), and I only see that 
if I try to build the info manual, with "make info".  If I just build gdb, with "make", then I get no complaints.  I see gdb.info is included pre-built in the the release tarball.  What exactly were you trying to do?
Comment 2 Aaro Koskinen 2013-06-28 18:12:38 UTC
I see the same error with GDB 7.5.1. This happens during "make install".

There should be a way to prevent docs being installed. I'm cross-building GDB for 5 different targets, it's not like I would need a separate copy of documentation for each one of them in any case.
Comment 3 psmith 2017-08-22 18:19:27 UTC
I'm still seeing this with GDB 8.0 using the tar.xz package from ftp.gnu.org.

$ mkdir obj
$ cd obj
$ ../gdb-8.0/configure
  ...
checking for makeinfo... no
obj/gdb-8.0/missing: 81: obj/gdb-8.0/missing: makeinfo: not found
  ...
checking for makeinfo... obj/gdb-8.0/missing makeinfo --split-size=5000000
configure: WARNING:
*** Makeinfo is missing. Info documentation will not be built.

$ make
$ make install
   ...
mv GDBvn.new GDBvn.texi
/usr/src/cc/gdb-7.5/missing makeinfo --split-size=5000000 --split-size=5000000   -I /usr/src/cc/gdb-7.5/gdb/doc/../../readline/doc -I /usr/src/cc/gdb-7.5/gdb/doc/../mi -I /usr/src/cc/gdb-7.5/gdb/doc \
	-o gdb.info /usr/src/cc/gdb-7.5/gdb/doc/gdb.texinfo
WARNING: `makeinfo' is missing on your system.  You should only need it if
         you modified a `.texi' or `.texinfo' file, or any other file
         indirectly affecting the aspect of the manual.  The spurious
         call might also be the consequence of using a buggy `make' (AIX,
         DU, IRIX).  You might want to install the `Texinfo' package or
         the `GNU make' package.  Grab either from any GNU archive site.
make[7]: *** [gdb.info] Error 1
Comment 4 psmith 2017-08-22 18:30:28 UTC
Sorry I pasted the wrong cut buffer into my comment above: the error messages refer to gdb-8.0 not gdb-7.5:

if test -z "-I ../gdb-8.0/gdb/doc/../../readline/doc"; then \
  echo "@set SYSTEM_READLINE" >> ./GDBvn.new; \
fi
if [ -n "" ]; then \
  echo "@set SYSTEM_GDBINIT " >> ./GDBvn.new; \
fi
mv GDBvn.new GDBvn.texi
../gdb-8.0/missing makeinfo --split-size=5000000 --split-size=5000000   -I ../gdb-8.0/gdb/doc/../../readline/doc -I ../gdb-8.0/gdb/doc/../mi -I ../gdb-8.0/gdb/doc \
        -o gdb.info ../gdb-8.0/gdb/doc/gdb.texinfo
../gdb-8.0/missing: 81: ../gdb-8.0/missing: makeinfo: 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:
         <http://www.gnu.org/software/texinfo/>
         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:
         <http://www.gnu.org/software/make/>
make[5]: *** [Makefile:503: gdb.info] Error 127


I'm not sure if I'm supposed to change the status of this bug myself and if so what I should change it to...
Comment 5 Pedro Alves 2017-08-22 19:04:33 UTC
Paul, please feel free to edit the bug status.  I had set it to waiting in comment #1 waiting for your response.
Comment 6 psmith 2017-08-22 19:42:23 UTC
Oops sorry; I dpn't have much to add beyond what Aaro said: you need to run "make install" to see the issue.  Cheers!
Comment 7 psmith 2020-03-07 19:18:38 UTC
Just FYI, this problem still is true in the latest GDB 9.1 release package: the GDBvn.texi and gdb-cfg.texi files are not provided with the package, so they need to be rebuilt, which then makes them newer than the info files, which then requires makeinfo to be installed in order to build GDB.
Comment 8 psmith 2020-03-07 19:22:32 UTC
Also I should mention: in GDB 9.1 I get the failure just during a normal invocation of `make`; I don't need to run `make install` to see it.
Comment 9 Miguel Ojeda 2020-11-21 20:48:22 UTC
Still there in 10.1
Comment 10 Tom Tromey 2022-02-22 15:18:53 UTC
*** Bug 17268 has been marked as a duplicate of this bug. ***
Comment 11 Tom Tromey 2022-02-22 15:19:03 UTC
*** Bug 18113 has been marked as a duplicate of this bug. ***
Comment 12 Tom Tromey 2022-02-22 15:19:16 UTC
*** Bug 22092 has been marked as a duplicate of this bug. ***
Comment 13 Tom Tromey 2022-02-22 15:20:35 UTC
*** Bug 20417 has been marked as a duplicate of this bug. ***
Comment 14 Tom de Vries 2022-10-04 15:48:17 UTC
This is fixed by commit ab954e4a53c ("Fix building gdb release from tar file without makeinfo"), available starting release 11.1.
Comment 15 nfall 2022-10-19 01:43:32 UTC
This bug appears to still be occuring in gdb 12.1.

$ mkdir gdbtest
$ cd gdbtest
$ ../tmp/gdb-12.1/configure
...
checking for makeinfo... no
/home/me/tmp/gdb-12.1/missing: line 81: makeinfo: command not found
...
$ make
...
  MAKEINFO doc/bfd.info
/home/me/tmp/gdb-12.1/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:
         <http://www.gnu.org/software/texinfo/>
         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:
         <http://www.gnu.org/software/make/>
make[3]: *** [doc/bfd.info] Error 127
make[3]: Leaving directory `/home/me/gdbtest/bfd'
make[2]: *** [info-recursive] Error 1
make[2]: Leaving directory `/home/me/gdbtest/bfd'
make[1]: *** [all-bfd] Error 2
make[1]: Leaving directory `/home/me/gdbtest'
make: *** [all] Error 2
Comment 16 Tom de Vries 2022-10-19 04:02:04 UTC
(In reply to nfall from comment #15)
> This bug appears to still be occuring in gdb 12.1.

I'm aware of two separate problems with the same symptom:
- not being able to build gdb from a snapshot or release tarball without
  makeinfo
- not being able to build gdb from the repository without makeinfo

[ It's a bit unfortunate that PRs reporting both problems have been marked as duplicate of this PR. ]

The first is gdb-specific, the second is due to top-level configure.

AFAICT, comment 0 reports the first problem, and comment 15 the second.

The first one has been fixed in aforementioned commit.  I've just confirmed that downloading the gdb 12.1 tarball and doing configure MAKEINFO=/usr/bin/false and make all-gdb gets me a complete build.

I'm working on fixing the second, I'm in the process of upstreaming a patch at gcc-patches ( https://gcc.gnu.org/pipermail/gcc-patches/2022-October/602797.html ).

[ FWIW, I have a workaround submitted here https://sourceware.org/pipermail/gdb-patches/2022-September/191642.html if you're looking for something less intrusive.  Note also that this should work: ./configure; make MAKEINFO=/usr/bin/true, it's just a bit cumbersome to have to remember to do this for each make invocation. ]