Re: [PATCH v8 09/15] bugreport: generate config safelist based on docs
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Feb 26, 2020, 16:49 UTC
- Message-ID
- <xmqqr1yhjnte.fsf@gitster-ct.c.googlers.com>
- In-Reply-To
- <nycvar.QRO.7.76.6.2002261649550.46@tvgsbejvaqbjf.bet>
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
Show 27 quoted lines
> Subject: [PATCH] fixup??? bugreport: generate config safelist based on docs > > The Visual Studio build is a special beast: as we cannot assume the > presence of any Unix tools on Windows, we have to commit all of the > files generated via shell scripts. > > These two generated header files are no exception. > > Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> > --- > config.mak.uname | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/config.mak.uname b/config.mak.uname > index 6d58d22cd5a..f1f36e43e47 100644 > --- a/config.mak.uname > +++ b/config.mak.uname > @@ -788,8 +788,10 @@ vcxproj: > git add -f git/LinkOrCopyBuiltins.targets git-remote-http/LinkOrCopyRemoteHttp.targets > > # Add command-list.h > - $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 command-list.h > - git add -f command-list.h > + $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 command-list.h \ > + config-list.h bugreport-config-safelist.h > + git add -f command-list.h \ > + config-list.h bugreport-config-safelist.h
Two important questions are
- Is $(GENERATED_H) visible to you at this point in this makefile snippet that is included from the main Makefile?
- Currently the list of files listed on $(GENERATED_H) match what you are building and adding here. Is there a reason to believe two would ever diverge?
If the answers to the above are yes and no, there is an obvious futureproofing of the suggested patch, i.e.
- $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 command-list.h - git add -f command-list.h + $(MAKE) MSVC=1 SKIP_VCPKG=1 prefix=/mingw64 $(GENERATED_H) + git add -f $(GENERATED_H)