1 # Maintainer makefile rules for Automake.
3 # Copyright (C) 1995-2024 Free Software Foundation, Inc.
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)
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.
15 # You should have received a copy of the GNU General Public License
16 # along with this program. If not, see <https://www.gnu.org/licenses/>.
18 # Avoid CDPATH issues.
21 # Program to use to fetch files from the Net.
24 # --------------------------------------------------------- #
25 # Automatic generation of the ChangeLog from git history. #
26 # --------------------------------------------------------- #
28 gitlog_to_changelog_command
= $(PERL
) $(srcdir)/lib
/gitlog-to-changelog
29 gitlog_to_changelog_fixes
= $(srcdir)/.git-log-fix
30 gitlog_to_changelog_options
= \
32 --amend
=$(gitlog_to_changelog_fixes
) \
33 --since
='2011-12-28 00:00:00' \
34 --no-cluster
--format
'%s%n%n%b'
36 EXTRA_DIST
+= lib
/gitlog-to-changelog
37 EXTRA_DIST
+= $(gitlog_to_changelog_fixes
)
39 # When executed from a git checkout, generate the ChangeLog from the git
40 # history. When executed from an extracted distribution tarball, just
41 # copy the distributed ChangeLog in the build directory (and if this
42 # fails, or if no distributed ChangeLog file is present, complain and
45 # The ChangeLog should be regenerated unconditionally when working from
46 # checked-out sources; otherwise, if we're working from a distribution
47 # tarball, we expect the ChangeLog to be distributed, so check that it
48 # is indeed present in the source directory.
50 $(AM_V_GEN
)set
-e
; set
-u
; \
51 if
test -d
$(srcdir)/.git
; then \
53 && $(gitlog_to_changelog_command
) \
54 $(gitlog_to_changelog_options
) >$@
-t \
58 elif
test ! -f
$(srcdir)/$@
; then \
59 echo
"Source tree is not a git checkout, and no pre-existent" \
60 "$@ file has been found there" >&2; \
66 # --------------------------- #
67 # Perl coverage statistics. #
68 # --------------------------- #
70 PERL_COVERAGE_DB
= $(abs_top_builddir
)/cover_db
71 PERL_COVERAGE_FLAGS
= -MDevel
::Cover
=-db
,$(PERL_COVERAGE_DB
),-silent
,on
,-summary
,off
74 check-coverage-run recheck-coverage-run
: %-coverage-run
: all
75 $(MKDIR_P
) $(PERL_COVERAGE_DB
)
76 PERL5OPT
="$$PERL5OPT $(PERL_COVERAGE_FLAGS)"; export PERL5OPT
; \
77 WANT_NO_THREADS
=yes
; export WANT_NO_THREADS
; unset AUTOMAKE_JOBS
; \
80 check-coverage-report
:
81 @if
test ! -d
"$(PERL_COVERAGE_DB)"; then \
82 echo
"No coverage database found in '$(PERL_COVERAGE_DB)'." >&2; \
83 echo
"Please run \"make check-coverage\" first" >&2; \
86 $(PERL_COVER
) $(PERL_COVER_FLAGS
) "$(PERL_COVERAGE_DB)"
88 # We don't use direct dependencies here because we'd like to be able
89 # to invoke the report even after interrupted check-coverage.
90 check-coverage
: check-coverage-run
91 $(MAKE
) check-coverage-report
93 recheck-coverage
: recheck-coverage-run
94 $(MAKE
) check-coverage-report
97 rm -rf
"$(PERL_COVERAGE_DB)"
98 clean-local
: clean-coverage
100 .PHONY
: check-coverage recheck-coverage check-coverage-run \
101 recheck-coverage-run check-coverage-report clean-coverage
104 # ---------------------------------------------------- #
105 # Tagging and/or uploading stable and beta releases. #
106 # ---------------------------------------------------- #
110 EXTRA_DIST
+= lib
/gnupload
112 # First component of a version number (mandatory).
114 # Later components of a version number (optional).
116 # Used in recipes to decide which kind of release we are.
117 stable_major_version_rx
= $(rx-0
)\
.0$$
118 stable_minor_version_rx
= $(rx-0
)$(rx-1
)$$
119 stable_micro_version_rx
= $(rx-0
)$(rx-1
)$(rx-1
)$$
120 beta_version_rx
= $(rx-0
)($(rx-1
)){1,2}[bdfhjlnprtvxz
]$$
121 alpha_version_rx
= $(rx-0
)($(rx-1
)){1,2}[acegikmoqsuwy
]$$
122 match_version
= echo
"$(VERSION)" |
$(EGREP
) >/dev
/null
124 # Check that we don't have uncommitted or unstaged changes.
125 # TODO: Maybe the git suite already offers a shortcut to verify if the
126 # TODO: working directory is "clean" or not? If yes, use that instead
127 # TODO: of duplicating the logic here.
128 git_must_have_clean_workdir
= \
129 $(GIT
) rev-parse
--verify HEAD
>/dev
/null \
130 && $(GIT
) update-index
-q
--refresh \
131 && $(GIT
) diff-files
--quiet \
132 && $(GIT
) diff-index
--quiet
--cached HEAD \
133 ||
{ echo
"$@: you have uncommitted or unstaged changes" >&2; exit
1; }
135 determine_release_type
= \
136 if
$(match_version
) '$(stable_major_version_rx)'; then \
137 release_type
='Major release'; \
138 announcement_type
='major release'; \
140 elif
$(match_version
) '$(stable_minor_version_rx)'; then \
141 release_type
='Minor release'; \
142 announcement_type
='minor release'; \
144 elif
$(match_version
) '$(stable_micro_version_rx)'; then \
145 release_type
='Micro release'; \
146 announcement_type
='maintenance release'; \
148 elif
$(match_version
) '$(beta_version_rx)'; then \
149 release_type
='Beta release'; \
150 announcement_type
='test release'; \
152 elif
$(match_version
) '$(alpha_version_rx)'; then \
153 echo
"$@: improper version '$(VERSION)' for a release" >&2; \
154 if
test -n
'$(strip $(DEVEL_SNAPSHOT))'; then \
155 echo
"$@: continuing anyway since DEVEL_SNAPSHOT is set" >&2; \
156 release_type
='Development snapshot'; \
157 announcement_type
='development snapshot'; \
163 echo
"$@: invalid version number '$(VERSION)'" >&2; \
167 # Help the debugging of $(determine_release_type) and related code.
169 @
$(determine_release_type
); \
170 echo
"$$release_type $(VERSION);" \
171 "it will be announced as a \"$$announcement_type\""
173 git-tag-release
: maintainer-check
175 case
'$(AM_TAG_DRYRUN)' in \
176 ""|
[nN
]|
[nN
]o|NO
) run
="";; \
177 *) run
="echo Running:";; \
179 $(git_must_have_clean_workdir
); \
180 $$run $(GIT
) tag
-s
"v$(VERSION)" -m
"$(PACKAGE) $(VERSION)"
183 @
# Check this is a version we can cut a release (either test
185 @
$(determine_release_type
)
186 @
# The repository must be clean.
187 @
$(git_must_have_clean_workdir
)
188 @
# Check that we are releasing from a valid tag.
189 @tag
=`$(GIT) describe` \
190 && case
$$tag in
"v$(VERSION)") true
;; *) false
;; esac \
191 ||
{ echo
"$@: you can only create a release from a tagged" \
194 @
# Build the distribution tarball(s).
196 @
# Upload it to the correct FTP repository.
197 @
$(determine_release_type
) \
198 && dest
=$$dest.gnu.org
:automake \
199 && echo
"Will upload to $$dest: $(DIST_ARCHIVES)" \
200 && $(srcdir)/lib
/gnupload
$(GNUPLOADFLAGS
) --to
$$dest \
203 .PHONY
: print-release-type git-upload-release git-tag-release
206 # ------------------------------------------------------------------ #
207 # Explore differences of autogenerated files in different commits. #
208 # ------------------------------------------------------------------ #
210 # Visually comparing differences between the Makefile.in files in
211 # automake's own build system as generated in two different branches
212 # might help to catch bugs and blunders. This has already happened a
213 # few times in the past, when we used to version-control Makefile.in.
216 NEW_COMMIT
=$${NEW_COMMIT-
"HEAD"}; \
217 OLD_COMMIT
=$${OLD_COMMIT-
"HEAD~1"}; \
218 am_gitdir
='$(abs_top_srcdir)/.git'; \
219 get_autofiles_from_rev
() \
222 && echo
"$@: will get files from revision $$rev" \
223 && $(GIT
) clone
-q
--depth
1 "$$am_gitdir" tmp \
225 && $(GIT
) checkout
-q
"$$rev" \
226 && echo
"$@: bootstrapping $$rev" \
227 && $(SHELL
) .
/bootstrap \
228 && echo
"$@: copying files from $$rev" \
229 && makefile_ins
=`find . -name Makefile.in` \
230 && (tar cf
- configure aclocal.m4
$$makefile_ins) | \
231 (cd ..
&& cd
"$$dir" && tar xf
-) \
236 && : Before proceeding
, ensure the specified revisions truly exist. \
237 && $(GIT
) --git-dir
="$$am_gitdir" describe
$$OLD_COMMIT >/dev
/null \
238 && $(GIT
) --git-dir
="$$am_gitdir" describe
$$NEW_COMMIT >/dev
/null \
243 && get_autofiles_from_rev
$$OLD_COMMIT old \
244 && get_autofiles_from_rev
$$NEW_COMMIT new \
247 # With lots of eye candy; we like our developers pampered and spoiled :-)
248 compare-autodiffs
: autodiffs
250 : $${COLORDIFF
=colordiff
} $${DIFF
=diff
}; \
252 if
test ! -d
"$$dir"; then \
253 echo
"$@: $$dir: Not a directory" >&2; \
256 mydiff
=false mypager
=false
; \
258 if
($$COLORDIFF -r . .
) </dev
/null
>/dev
/null
2>&1; then \
259 mydiff
=$$COLORDIFF; \
267 if
test "$$mydiff" = false
; then \
268 if
($$DIFF -r
-u . .
); then \
271 echo
"$@: no good-enough diff program specified" >&2; \
275 st
=0; $$mydiff -r
-u
$$dir/old
$$dir/new |
$$mypager || st
=$$?
; \
278 .PHONY
: autodiffs compare-autodiffs
280 # ---------------------------------------------- #
281 # Help writing the announcement for a release. #
282 # ---------------------------------------------- #
284 PACKAGE_MAILINGLIST
= automake@gnu.org
286 announcement
: DEVEL_SNAPSHOT
= yes
290 && $(determine_release_type
) \
291 && ftp_base
="https://$$dest.gnu.org/gnu/$(PACKAGE)" \
292 && X
() { printf
'%s\n' "$$*" >> $@
-t
; } \
293 && X
"We are pleased to announce the $(PACKAGE_NAME) $(VERSION)" \
294 "$$announcement_type." \
296 && X
"**TODO** Brief description of the release here." \
298 && X
"**TODO** This description can span multiple paragraphs." \
300 && X
"See below for the detailed list of changes since the" \
301 && X
"previous version, as summarized by the NEWS file." \
303 && X
"Download here:" \
305 && X
" $$ftp_base/$(PACKAGE)-$(VERSION).tar.gz" \
306 && X
" $$ftp_base/$(PACKAGE)-$(VERSION).tar.xz" \
308 && X
"Please report bugs and problems to" \
309 "<$(PACKAGE_BUGREPORT)>" \
310 "(instead of replying to this mail)," \
311 && X
"and send general comments and feedback to" \
312 "<$(PACKAGE_MAILINGLIST)>," \
313 && X
"and patches to" \
314 "<automake-patches@gnu.org>." \
316 && X
"Thanks to everyone who has reported problems, contributed" \
317 && X
"patches, and helped test Automake!" \
322 ($$0 ~ /^New in .*:/) { wait_for_end=1; } \
323 (/^~~~/ && wait_for_end) { print; exit(0) } \
325 ' <$(srcdir)/NEWS
>> $@
-t \
329 CLEANFILES
+= announcement
331 # --------------------------------------------------------------------- #
332 # Synchronize third-party files that are committed in our repository. #
333 # --------------------------------------------------------------------- #
335 # Git repositories on Savannah.
336 git-sv-host
= git.savannah.gnu.org
338 # Some repositories we sync files from.
339 SV_GIT_CF
= 'https://$(git-sv-host)/gitweb/?p=config.git;a=blob_plain;hb=HEAD;f='
340 SV_GIT_GL
= 'https://$(git-sv-host)/gitweb/?p=gnulib.git;a=blob_plain;hb=HEAD;f='
342 # Files that we fetch and which we compare against.
343 # Note that the 'lib/COPYING' file and help2man must still be synced by hand.
345 $(SV_GIT_CF
)config.guess \
346 $(SV_GIT_CF
)config.sub \
347 $(SV_GIT_GL
)build-aux
/texinfo.
tex \
348 $(SV_GIT_GL
)build-aux
/gendocs.sh \
349 $(SV_GIT_GL
)build-aux
/gitlog-to-changelog \
350 $(SV_GIT_GL
)build-aux
/gnupload \
351 $(SV_GIT_GL
)build-aux
/update-copyright \
352 $(SV_GIT_GL
)doc
/gendocs_template \
353 $(SV_GIT_GL
)doc
/INSTALL
355 # Fetch the latest versions of few scripts and files we care about.
356 # A retrieval or copying failure usually means serious problems,
357 # so we'll just bail out if 'wget' or 'cp' fail.
358 # Update the top-level INSTALL in sync with lib/INSTALL as a special case.
360 $(AM_V_at
)rm -rf Fetchdir
361 $(AM_V_at
)mkdir Fetchdir
363 if
$(AM_V_P
); then wget_opts
=; else wget_opts
=-nv
; fi
; \
364 for url in
$(FETCHFILES
); do \
365 file
=`printf '%s\n' "$$url" | sed 's|^.*/||; s|^.*=||'`; \
366 $(WGET
) $$wget_opts "$$url" -O Fetchdir
/$$file || exit
1; \
367 if cmp Fetchdir
/$$file $(srcdir)/lib
/$$file >/dev
/null
; then \
370 echo
"$@: updating file $$file"; \
371 cp Fetchdir
/$$file $(srcdir)/lib
/$$file || exit
1; \
372 test "$$file" != INSTALL || cp Fetchdir
/$$file ..
/$$file; \
375 $(AM_V_at
)rm -rf Fetchdir
378 # ---------------------------------------------------------------------- #
379 # Generate and upload manuals in several formats, for the GNU website. #
380 # ---------------------------------------------------------------------- #
382 web_manual_dir
= doc
/web-manual
388 WEBCVS_ROOT
= cvs.savannah.gnu.org
:/web
392 .PHONY
: web-manual web-manual-update
393 web-manual web-manual-update
: t
= $@.
dir
395 MANUAL_VERSION_HTML
= \
396 <p
>See the
<a href
="index-full.html">full version index
</a
> for the manual for other releases of Automake.
</p
>
397 MANUAL_VERSION_HTML_PARENT
= \
398 <p
>See the
<a href
="../index-full.html">full version index
</a
> for the manual for other releases of Automake.
</p
>
400 # Build manual in several formats. Note to the recipe:
401 # 1. The symlinking of automake.texi into the temporary directory is
402 # required to pacify extra checks from gendocs.sh.
403 # 2. The redirection to /dev/null before the invocation of gendocs.sh
404 # is done to better respect silent rules.
406 $(AM_V_at
)rm -rf
$(web_manual_dir
) $t
408 $(AM_V_at
)$(LN_S
) '$(abs_srcdir)/doc/$(PACKAGE).texi' '$t/'
410 && GENDOCS_TEMPLATE_DIR
='$(abs_srcdir)/lib' \
411 && export GENDOCS_TEMPLATE_DIR \
412 && if
$(AM_V_P
); then
:; else exec
>/dev
/null
2>&1; fi \
413 && $(SHELL
) '$(abs_srcdir)/lib/gendocs.sh' \
414 -I
'$(abs_srcdir)/doc' --email
$(PACKAGE_BUGREPORT
) \
415 $(PACKAGE
) '$(PACKAGE_NAME)'
416 $(AM_V_at
)mkdir
$(web_manual_dir
)
417 $(AM_V_at
)mv
-f
$t/manual
/* $(web_manual_dir
)
419 @
! $(AM_V_P
) || ls
-l
$(web_manual_dir
)
421 # Upload manual to www.gnu.org, using CVS (sigh!)
423 $(AM_V_at
)$(determine_release_type
); \
424 case
$$release_type in \
425 [Mm
]ajor\ release|
[Mm
]inor\ release|
[Mm
]icro\ release
);; \
426 *) echo
"Cannot upload manuals from a \"$$release_type\"" >&2; \
429 $(AM_V_at
)test -f
$(web_manual_dir
)/$(PACKAGE
).html ||
{ \
430 echo
'You have to run "$(MAKE) web-manual" before' \
431 'invoking "$(MAKE) $@"' >&2; \
437 && $(CVS
) -z3
-d
:ext
:$(CVS_USER
)@
$(WEBCVS_ROOT
)/$(PACKAGE
) \
438 co -l
$(PACKAGE
)/manual \
439 && cd
$(PACKAGE
)/manual \
440 && $(CVS
) up html_node
441 @
# According to the rsync manpage, "a trailing slash on the
442 @
# source [...] avoids creating an additional directory
443 @
# level at the destination". So the trailing '/' after
444 @
# '$(web_manual_dir)' below is intended.
445 $(AM_V_at
)$(RSYNC
) -avP
$(web_manual_dir
)/ $t/$(PACKAGE
)/manual
446 $(AM_V_at
)sed
-i
'/This page generated by the/i$(MANUAL_VERSION_HTML)\n' $t/$(PACKAGE
)/manual
/index.html
447 $(AM_V_at
)$(RSYNC
) -avP
$(web_manual_dir
)/ $t/$(PACKAGE
)/manual
/$(VERSION
)
448 $(AM_V_at
)sed
-i
'/This page generated by the/i$(MANUAL_VERSION_HTML_PARENT)\n' $t/$(PACKAGE
)/manual
/$(VERSION
)/index.html
450 && cd
$t/$(PACKAGE
)/manual \
451 && $(CVS
) add
$(VERSION
) $(VERSION
)/*/ \
452 && new_files
=`$(CVSU) --types='?'` \
453 && new_files
=`echo "$$new_files" | sed s/^..//` \
454 && { test -z
"$$new_files" ||
$(CVS
) add
-ko
$$new_files; } \
455 && $(CVS
) ci
-m
$(VERSION
)
457 .PHONY
: web-manual-update
460 $(AM_V_at
)rm -rf
$(web_manual_dir
)
461 .PHONY
: clean-web-manual
462 clean-local
: clean-web-manual
464 EXTRA_DIST
+= lib
/gendocs.sh lib
/gendocs_template
466 # ------------------------------------------------ #
467 # Update copyright years of all committed files. #
468 # ------------------------------------------------ #
470 EXTRA_DIST
+= lib
/update-copyright
472 update_copyright_env
= \
473 UPDATE_COPYRIGHT_FORCE
=1 \
474 UPDATE_COPYRIGHT_USE_INTERVALS
=2
476 # In addition to the several README files, these as well are
477 # not expected to have a copyright notice.
478 files_without_copyright
= \
491 # This script is in the public domain.
492 files_without_copyright
+= lib
/mkinstalldirs
494 # This script has an MIT-style license
495 files_without_copyright
+= lib
/install-sh
497 # The UPDATE_COPYRIGHT_YEAR environment variable is honoured by the
498 # 'lib/update-copyright' script.
499 .PHONY
: update-copyright
502 if
test -n
"$$UPDATE_COPYRIGHT_YEAR"; then \
503 current_year
=$$UPDATE_COPYRIGHT_YEAR; \
505 current_year
=`date +%Y` && test -n
"$$current_year" \
506 ||
{ echo
"$@: cannot get current year" >&2; exit
1; }; \
508 sed
-i
"/^RELEASE_YEAR=/s/=.*$$/=$$current_year/" \
509 bootstrap configure.ac
; \
511 for url in $(FETCHFILES); do echo "$$url"; done \
512 | sed -e 's!^.*/!!' -e 's!^.*=!!' -e 's!^!lib/!' \
513 && for f in $(files_without_copyright); do echo $$f; done \
514 ) | sed -e '$$!s,$$,|,' | tr -d '\012\015'`; \
516 | grep
-Ev
'(^|/)README$$' \
517 | grep
-Ev
'^PLANS(/|$$)' \
518 | grep
-Ev
"^($$excluded_re)$$" \
519 |
$(update_copyright_env
) xargs
$(srcdir)/lib
/$@
521 # -------------------------------------------------------------- #
522 # Run the testsuite with the least supported autoconf version. #
523 # -------------------------------------------------------------- #
525 gnu-ftp
= https
://ftp.gnu.org
/gnu
527 # Various shorthands: version, name, package name, tarball name,
528 # tarball location, installation directory.
529 ac-v
= $(required_autoconf_version
)
531 ac-p
= $(ac-n
)-$(ac-v
)
532 ac-t
= $(ac-p
).
tar.gz
533 ac-l
= maintainer
/$(ac-t
)
534 ac-d
= maintainer
/$(ac-p
)
536 fetch-minimal-autoconf
: o
= $(ac-l
)
537 fetch-minimal-autoconf
:
538 $(AM_V_at
)$(MKDIR_P
) $(dir $o)
539 $(AM_V_at
)rm -f
$o $o-t
540 $(AM_V_GEN
)$(WGET
) -O
$o-t
$(gnu-ftp
)/$(ac-n
)/$(ac-t
)
541 $(AM_V_at
)chmod a-w
$o-t
&& mv
-f
$o-t
$o && ls
-l
$o
542 .PHONY
: fetch-minimal-autoconf
544 build-minimal-autoconf
:
546 test -f
$(ac-l
) ||
{ \
547 echo
"$@: tarball $(ac-l) seems missing." >&2; \
548 echo
"$@: have you run '$(MAKE) fetch-minimal-autoconf'?" >&2; \
552 && $(PERL
) $(srcdir)/t
/ax
/deltree.pl
$(ac-d
) \
553 && $(MKDIR_P
) $(ac-d
) \
555 && tar xzf
'$(CURDIR)/$(ac-l)' \
559 && env CONFIG_SHELL
='$(SHELL)' $(SHELL
) ..
/src
/configure \
560 --prefix='$(CURDIR)/$(ac-d)' CONFIG_SHELL
='$(SHELL)' \
562 $(AM_V_at
)echo
' ======' && $(ac-d
)/bin
/autoconf
--version
563 .PHONY
: build-minimal-autoconf
565 check-minimal-autoconf
:
566 $(AM_V_at
)p
='$(ac-d)/bin/autoconf'; \
567 if
test ! -f
"$$p" ||
test ! -x
"$$p"; then \
568 echo
"$@: program '$$p' seems missing." >&2; \
569 echo
"$@: have you run '$(MAKE) build-minimal-autoconf'?" >&2; \
573 && PATH
='$(CURDIR)/$(ac-d)/bin$(PATH_SEPARATOR)'$$PATH \
575 && AUTOCONF
=autoconf \
576 && AUTOHEADER
=autoheader \
577 && AUTORECONF
=autoreconf \
578 && AUTOM4TE
=autom4te \
579 && AUTOUPDATE
=autoupdate \
580 && export AUTOCONF AUTOHEADER AUTORECONF AUTOM4TE AUTOUPDATE \
581 && echo
=== check autoconf version
'(must be = $(ac-v))' \
582 && autoconf
--version \
583 && autoconf
--version | sed
-e
's/^/ /; s/$$/ /' -e
1q \
584 |
$(FGREP
) '$(ac-v)' >/dev
/null \
585 && echo
=== configure \
586 && $(srcdir)/configure
$(shell .
/config.status
--config
) \
587 && echo
=== build and
test \
589 .PHONY
: check-minimal-autoconf
592 # --------------------------------------------------------------- #
593 # Testing on real-world packages can help us avoid regressions. #
594 # --------------------------------------------------------------- #
597 # NOTE (from Stefano Lattarini):
599 # This section is mostly hacky and ad-hoc, but works for me and
600 # on my system. And while far from clean, it should help catching
601 # real regressions on real world packages, which is important.
602 # Ideas about how to improve this and make it more generic, portable,
603 # clean, etc., are welcome.
606 # Tiny sample package.
607 FEW_PACKAGES
+= hello
608 # Smallish package using recursive make setup.
610 # Medium-size package using non-recursive make setup.
611 FEW_PACKAGES
+= coreutils
622 pkg-targets
= check dist
624 # Note: "ttp" stays for "Third Party Package".
626 ttp-check ttp-check-all
: do-clone
= $(GIT
) clone
--verbose
627 ttp-check
: ttp-packages
= $(FEW_PACKAGES
)
628 ttp-check-all
: ttp-packages
= $(ALL_PACKAGES
)
630 # Note: some packages depend on pkg-config, and its provided macros.
631 ttp-check ttp-check-all
: t
/pkg-config-macros.log
633 $(setup_autotools_paths
); \
637 echo
"*** $@: WARNING: $$@" >&2; \
638 echo
"*** $@: WARNING: some packages might fail to bootstrap" >&2; \
641 . t
/pkg-config-macros.
dir/get.sh || exit
1; \
642 mkdir
$@.d
&& cd
$@.d || exit
1; \
643 for p in
$(ttp-packages
); do \
645 echo
======== BEGIN TTP
$$p =========; \
648 $(do-clone
) git
://$(git-sv-host
)/$$p.git || exit
1; \
652 && if
test -f bootstrap
; then \
653 .
/bootstrap
--no-git
; \
658 && if
test $$p = make
; then \
661 && for t in
$(pkg-targets
); do \
662 $(MAKE
) $$t WERROR_CFLAGS
= || exit
1; \
667 echo
======== END TTP
$$p =========; \
674 # Alias for lazy typists.
676 ttp-all
: ttp-check-all
678 .PHONY
: ttp ttp-check ttp-all ttp-check-all