distcheck-hook-m4.am 1.3 KB

123456789101112131415161718192021222324252627282930
  1. ## Data files for some tests. Not used in the automake build system.
  2. ##
  3. ## Copyright (C) 2011-2017 Free Software Foundation, Inc.
  4. ##
  5. ## This program is free software; you can redistribute it and/or modify
  6. ## it under the terms of the GNU General Public License as published by
  7. ## the Free Software Foundation; either version 2, or (at your option)
  8. ## any later version.
  9. ##
  10. ## This program is distributed in the hope that it will be useful,
  11. ## but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. ## GNU General Public License for more details.
  14. ##
  15. ## You should have received a copy of the GNU General Public License
  16. ## along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. distcheck-hook:
  18. @fatal () { echo "$@: $$*" >&2; exit 1; }; \
  19. $(am__cd) $(distdir) && chmod u+w . && mkdir _m4 \
  20. || fatal "cannot setup distdir"; \
  21. $(ACLOCAL) -I _m4 $(ACLOCAL_AMFLAGS) --install --output=_am.m4 \
  22. || fatal "cannot regenerate aclocal.m4"; \
  23. lst=`ls _m4 | tr '\012\015' ' '`; \
  24. if test -n "$$lst"; then \
  25. fatal "required m4 files not distributed or outdated: $$lst"; \
  26. fi; \
  27. $(AUTOCONF) -o /dev/null || fatal "can't remake configure"; \
  28. rm -rf _m4 _am.m4 autom4te.cache && chmod a-w . \
  29. || fatal "cannot reset distdir"