Makefile.am 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. # $Id$
  2. # Makefile.am for texinfo.
  3. # Process this file with automake to produce Makefile.in in all directories.
  4. #
  5. # Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011,
  6. # 2012, 2013, 2014, 2015, 2016 Free Software Foundation, Inc.
  7. #
  8. # This file is free software; as a special exception the author gives
  9. # unlimited permission to copy and/or distribute it, with or without
  10. # modifications, as long as this notice is preserved.
  11. #
  12. # This program is distributed in the hope that it will be useful, but
  13. # WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
  14. # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  15. # Find our headers and gnulib headers.
  16. ACLOCAL_AMFLAGS = -I gnulib/m4
  17. # Additional files to distribute.
  18. EXTRA_DIST = ChangeLog.46 INSTALL.generic README-hacking \
  19. system.h gnulib/m4/gnulib-cache.m4 \
  20. contrib djgpp
  21. # include contrib perl manual, exclude .svn.
  22. dist-hook:
  23. cd $(top_distdir)/contrib/perldoc-all && $(MAKE) distclean
  24. rm -rf `find $(distdir) -type d -name .svn`
  25. # update texi2html translations.
  26. dist-local:
  27. cp -fpR $(srcdir)/po_document/*.po $(srcdir)/po_document/LINGUAS texi2html/po_document/
  28. cp -fpR $(srcdir)/po/*.po $(srcdir)/po/LINGUAS texi2html/po_messages/
  29. # This is to prevent texinfo.tex from being included in the top-level
  30. # distribution directory.
  31. TEXINFO_TEX = doc/texinfo.tex
  32. # One special target for installers to use by hand if desired.
  33. install-tex:
  34. cd doc && $(MAKE) TEXMF=$(TEXMF) install-tex
  35. # painful separate build for cross-compiling.
  36. SUBDIRS =
  37. if TOOLS_ONLY
  38. # Build native tools only.
  39. SUBDIRS += gnulib/lib install-info tp util
  40. if HAVE_TERMLIBS
  41. SUBDIRS += info
  42. else
  43. # DOS/Windows don't need TERMLIBS to build Info
  44. if HOST_IS_WINDOWS
  45. SUBDIRS += info
  46. endif
  47. endif
  48. else
  49. # All subdirectories.
  50. # Do libs first since the C programs depend on it.
  51. # Do doc and man last so things will be built when we get there.
  52. # Others are alphabetical.
  53. SUBDIRS += $(native_tools) gnulib/lib
  54. if HAVE_TERMLIBS
  55. SUBDIRS += info
  56. else
  57. # DOS/Windows don't need TERMLIBS to build Info
  58. if HOST_IS_WINDOWS
  59. SUBDIRS += info
  60. endif
  61. endif
  62. SUBDIRS += install-info po po_document tp Pod-Simple-Texinfo texindex util \
  63. doc man
  64. endif
  65. distclean-local:
  66. -test -d "$(native_tools)" && rm -rf "$(native_tools)"
  67. # Don't install native tools for cross compile.
  68. if TOOLS_ONLY
  69. install:
  70. endif
  71. # to be run before making a distribution: ensure that the texinfo.dtd on
  72. # the web is what we will be releasing. See README-hacking.
  73. wget = wget
  74. dtd_url = http://www.gnu.org/software/texinfo/dtd/$(TEXINFO_DTD_VERSION)/texinfo.dtd
  75. dtd-check:
  76. $(wget) -nv $(dtd_url) -O $@-1 \
  77. && diff $@-1 $(srcdir)/util/texinfo.dtd \
  78. && rm -f $@-1
  79. # emacs-page
  80. # just for convenience:
  81. update-po:
  82. cd $(srcdir)/po && $(MAKE) update-po
  83. cd $(srcdir)/po_document && $(MAKE) update-po
  84. # From coreutils. Use when making a release.
  85. # Verify that all source files using _() are listed in po/POTFILES.in.
  86. # Run this before making pretests, as well as official releases, so that
  87. # translators will see changed strings. See README-hacking.
  88. po-check:
  89. @if test -f po/POTFILES.in; then \
  90. grep -E -v '^(#|$$)' po/POTFILES.in \
  91. | grep -v '^src/false\.c$$' | sort > $@-1; \
  92. files=; \
  93. for file in $$($(CVS_LIST_EXCEPT)) \
  94. `find [a-z]* -name '*.[ch]' \
  95. -o -name '*.p[lm]' \
  96. -o -name '*.notyettwjr'`; do \
  97. # don't look at sources from some subdirs. \
  98. case $$file in \
  99. contrib/* ) continue;; \
  100. djgpp/* | makeinfo/* | man/* | texi2html/* ) continue;; \
  101. tp/parsetexi/*) continue;; \
  102. texinfo-*/*) continue;; \
  103. tp/maintain/* ) continue;; \
  104. esac; \
  105. # if have lex/yacc sources, skip corresponding c/h files. \
  106. case $$file in \
  107. *.[ch]) \
  108. base=`expr " $$file" : ' \(.*\)\..'`; \
  109. { test -f $$base.l || test -f $$base.y; } && continue;; \
  110. esac; \
  111. files="$$files $$file"; \
  112. done; \
  113. # the first alternative is for twjr/gawk, which just uses _" \
  114. # with no space or lparen; the other alternative matches the \
  115. # usual function calls, e.g., _("..."), with or without space.\
  116. grep -E -l \
  117. '\b[^$$]N?__?"|\b(N?__?|gdt|gettext *)\([^)"]*("|$$)' \
  118. $$files | sort -u > $@-2; \
  119. diff -u $@-1 $@-2 || exit 1; \
  120. rm -f $@-1 $@-2; \
  121. fi