txinfo28.sh 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. #! /bin/sh
  2. # Copyright (C) 2002-2017 Free Software Foundation, Inc.
  3. #
  4. # This program is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2, or (at your option)
  7. # any later version.
  8. #
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. # GNU General Public License for more details.
  13. #
  14. # You should have received a copy of the GNU General Public License
  15. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  16. # Check that info files are built in builddir when needed.
  17. # Similar to txinfo24.sh, but obfuscating filenames with variable
  18. # references.
  19. # Report from Ralf Corsepius.
  20. required='makeinfo tex texi2dvi'
  21. . test-init.sh
  22. # This setting, when honored by GNU ls, used to cause an infinite loop
  23. # in mdate-sh.
  24. TIME_STYLE="+%Y-%m-%d %H:%M:%S"
  25. export TIME_STYLE
  26. echo AC_OUTPUT >> configure.ac
  27. cat > Makefile.am << 'END'
  28. MA = ma
  29. IN = in
  30. PROJ = $(MA)$(IN)
  31. include fragment.mk
  32. info_TEXINFOS = ma$(IN).texi
  33. END
  34. echo 'CLEANFILES = $(PROJ).info' > fragment.mk
  35. cat > main.texi << 'END'
  36. \input texinfo
  37. @setfilename main.info
  38. @settitle main
  39. @node Top
  40. Hello walls.
  41. @include version.texi
  42. @bye
  43. END
  44. $ACLOCAL
  45. $AUTOMAKE --add-missing -Wno-error
  46. $AUTOCONF
  47. mkdir build
  48. cd build
  49. ../configure
  50. $MAKE
  51. test -f main.info
  52. cd ..
  53. rm -rf build
  54. ./configure
  55. $MAKE
  56. test -f main.info
  57. # Make sure stamp-vti is older that version.texi.
  58. # (A common situation in a real tree).
  59. test -f stamp-vti
  60. test -f version.texi
  61. $sleep
  62. touch stamp-vti
  63. $MAKE distclean
  64. test -f stamp-vti
  65. test -f version.texi
  66. mkdir build
  67. cd build
  68. ../configure
  69. $MAKE
  70. # main.info should be rebuilt in the current directory.
  71. test -f main.info
  72. test ! -e ../main.info
  73. $MAKE dvi
  74. test -f main.dvi
  75. $MAKE distcheck