005-libctf-update-regexp-to-allow-makeinfo-to-build-docu.patch 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. From f7c5db99b76e8dde89335d794c82fcbfbf53c612 Mon Sep 17 00:00:00 2001
  2. From: Enze Li <[email protected]>
  3. Date: Sat, 14 Jan 2023 11:33:48 +0800
  4. Subject: [PATCH 05/50] libctf: update regexp to allow makeinfo to build
  5. document
  6. While trying to build gdb on latest openSUSE Tumbleweed, I noticed the
  7. following warning,
  8. checking for makeinfo... makeinfo --split-size=5000000
  9. configure: WARNING:
  10. *** Makeinfo is too old. Info documentation will not be built.
  11. then I checked the version of makeinfo, it said,
  12. ======
  13. $ makeinfo --version
  14. texi2any (GNU texinfo) 7.0.1
  15. Copyright (C) 2022 Free Software Foundation, Inc.
  16. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
  17. This is free software: you are free to change and redistribute it.
  18. There is NO WARRANTY, to the extent permitted by law.
  19. ======
  20. After digging a little bit, it became quite obvious that a dot is
  21. missing in regexp that makes it impossible to match versions higher than
  22. 7.0, and here's the solution:
  23. - | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9][0-9])' >/dev/null 2>&1; then
  24. + | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9]\.[0-9])' >/dev/null 2>&1; then
  25. However, Eli pointed out that the solution above has another problem: it
  26. will stop working when Texinfo 10.1 will be released. Meanwhile, he
  27. suggested to solve this problem permanently. That is, we don't care
  28. about the minor version for Texinfo > 6.9, we only care about the major
  29. version.
  30. In this way, the problem will be resolved permanently, thanks to Eli.
  31. libctf/ChangeLog:
  32. * configure: Regenerated.
  33. * configure.ac: Update regexp to match versions higher than 7.0.
  34. ---
  35. libctf/configure | 2 +-
  36. libctf/configure.ac | 2 +-
  37. 2 files changed, 2 insertions(+), 2 deletions(-)
  38. --- a/libctf/configure
  39. +++ b/libctf/configure
  40. @@ -14865,7 +14865,7 @@ esac
  41. # We require texinfo to be 6.3 or later, for a working synindex
  42. # and validatemenus: otherwise we fall back to /bin/true.
  43. if ${MAKEINFO} --version \
  44. - | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9][0-9])' >/dev/null 2>&1; then
  45. + | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9]|[1-6][0-9])' >/dev/null 2>&1; then
  46. build_info=yes
  47. else
  48. build_info=
  49. --- a/libctf/configure.ac
  50. +++ b/libctf/configure.ac
  51. @@ -184,7 +184,7 @@ changequote(,)
  52. # We require texinfo to be 6.3 or later, for a working synindex
  53. # and validatemenus: otherwise we fall back to /bin/true.
  54. if ${MAKEINFO} --version \
  55. - | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9][0-9])' >/dev/null 2>&1; then
  56. + | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9]|[1-6][0-9])' >/dev/null 2>&1; then
  57. build_info=yes
  58. else
  59. build_info=