diff options
author | Denton Liu <liu.denton@gmail.com> | 2019-09-25 01:21:01 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2019-09-28 14:04:22 +0900 |
commit | b503a2d515e6ac3d2cced7881791c12663c45d01 (patch) | |
tree | 9fcba0f80078552a3e0f67cb7c71259e92600bd5 /.gitignore | |
parent | pack-bitmap.h: remove magic number (diff) | |
download | tgif-b503a2d515e6ac3d2cced7881791c12663c45d01.tar.xz |
Makefile: emulate compile in $(HCO) target better
Currently, when testing headers using `make hdr-check`, headers are
directly compiled. Although this seems to test the headers, this is too
strict since we treat the headers as C sources. As a result, this will
cause warnings to appear that would otherwise not, such as a static
variable definition intended for later use throwing a unused variable
warning.
In addition, on platforms that can run `make hdr-check` but require
custom flags, this target was failing because none of them were being
passed to the compiler. For example, on MacOS, the NO_OPENSSL flag was
being set but it was not being passed into compiler so the check was
failing.
Fix these problems by emulating the compile process better, including
test compiling dummy *.hcc C sources generated from the *.h files and
passing $(ALL_CFLAGS) into the compiler for the $(HCO) target so that
these custom flags can be used.
Helped-by: Jeff King <peff@peff.net>
Signed-off-by: Denton Liu <liu.denton@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to '.gitignore')
-rw-r--r-- | .gitignore | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore index 521d8f4fb4..34efe125cb 100644 --- a/.gitignore +++ b/.gitignore @@ -216,6 +216,7 @@ /tags /TAGS /cscope* +*.hcc *.obj *.lib *.res |