]> git.ipfire.org Git - thirdparty/git.git/commit
Makefile: strip leading ./ in $(LIB_H)
authorDenton Liu <liu.denton@gmail.com>
Mon, 16 Sep 2019 19:23:08 +0000 (12:23 -0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 17 Sep 2019 16:13:02 +0000 (09:13 -0700)
commitcf6a2d2557a5a50e0b1cf3a861a0df948e2782fc
tree4548ab0e07cdad7bdf2b54e1bc3e9f787c2badca
parent7027f508c767f57d9e8d5edeacf99d13950f6b69
Makefile: strip leading ./ in $(LIB_H)

Currently, $(LIB_H) is generated from two modes: if `git ls-files` is
present, it will use that to enumerate the files in the repository; else
it will use `$(FIND) .` to enumerate the files in the directory.

There is a subtle difference between these two methods, however. With
ls-files, filenames don't have a leading `./` while with $(FIND), they
do. This results in $(CHK_HDRS) having to substitute out the leading
`./` before it uses $(LIB_H).

Unify the two possible values in $(LIB_H) by using patsubst to remove the
`./` prefix at its definition.

Signed-off-by: Denton Liu <liu.denton@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Makefile