txinfo-override-texinfo-tex.sh 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. #! /bin/sh
  2. # Copyright (C) 2003-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. # Make sure the user can override TEXINFO_TEX.
  17. # Also make sure TEXINFO_TEX is not distributed.
  18. # Report from Tom Tromey.
  19. required='makeinfo tex texi2dvi'
  20. . test-init.sh
  21. cat > configure.ac << END
  22. AC_INIT([$me], [1.0])
  23. AC_CONFIG_AUX_DIR([aux1])
  24. AM_INIT_AUTOMAKE
  25. AC_CONFIG_FILES([Makefile])
  26. AC_OUTPUT
  27. END
  28. cat > Makefile.am << 'END'
  29. TEXINFO_TEX = ../tex/texinfo.tex
  30. info_TEXINFOS = main.texi
  31. sure_it_exists:
  32. test -f $(srcdir)/$(TEXINFO_TEX)
  33. sure_it_is_not_distributed: distdir
  34. test ! -f $(distdir)/tex/texinfo.tex
  35. check-local: sure_it_exists
  36. END
  37. cat > main.texi << 'END'
  38. \input texinfo
  39. @setfilename main.info
  40. @settitle main
  41. @node Top
  42. Hello walls.
  43. @bye
  44. END
  45. mkdir aux1
  46. mkdir tex
  47. cp "$am_pkgvdatadir/texinfo.tex" tex
  48. $ACLOCAL
  49. $AUTOMAKE --add-missing
  50. $AUTOCONF
  51. test ! -e texinfo.tex
  52. test ! -e aux1/texinfo.tex
  53. test -f tex/texinfo.tex
  54. ./configure
  55. $MAKE distcheck
  56. $MAKE sure_it_is_not_distributed
  57. :