1 # Main Automakefile for GNU diffutils.
3 # Copyright (C) 2001-2002, 2004, 2006, 2009-2013, 2015-2024 Free Software
6 # This program is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation, either version 3 of the License, or
9 # (at your option) any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program. If not, see <http://www.gnu.org/licenses/>.
19 ALL_RECURSIVE_TARGETS =
21 EXTRA_DIST = bootstrap exgettext ChangeLog-2008 cfg.mk dist-check.mk
22 SUBDIRS = lib src tests doc man po gnulib-tests
24 ACLOCAL_AMFLAGS = -I m4
25 AM_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS)
27 # Arrange so that .tarball-version appears only in the distribution
28 # tarball, and never in a checked-out repository.
29 dist-hook: gen-ChangeLog
30 $(AM_V_GEN)echo $(VERSION) > $(distdir)/.tarball-version
32 gen_start_date = '2009-11-11 15:00'
35 $(AM_V_GEN)if test -d .git; then \
36 $(top_srcdir)/build-aux/gitlog-to-changelog \
37 --since=$(gen_start_date) > $(distdir)/cl-t && \
38 { rm -f $(distdir)/ChangeLog && \
39 mv $(distdir)/cl-t $(distdir)/ChangeLog; } \
42 ALL_RECURSIVE_TARGETS += distcheck-hook
46 # Some of our git hook scripts are supposed to be identical to git's samples.
47 # See if they are still in sync.
48 .PHONY: check-git-hook-script-sync
49 check-git-hook-script-sync:
52 && cd $$t && git init -q && cd .git/hooks \
53 && for i in pre-commit pre-applypatch applypatch-msg; do \
54 diff -u $(abs_top_srcdir)/scripts/git-hooks/$$i $$i.sample \