sys/conf/newvers.sh -R KERNEL_CONFIG_NAME and make -C release -V BRANCH called during build kernel and wold. Both call git if it installed and does not fail if there is no git or .git repo. NOGIT='yes' does not stop this. As workaround I use: GIT_CMD='/dev/_not_exist_' helps with (release/Makefile.inc1) and svnversion='echo' sed -i '.orig' -e 's|local savedir|return 1|g' "sys/conf/newvers.sh" Is it possible to make NOGIT=yes work for whole build process?
What is the actual issue you are trying to solve?
(In reply to Ed Maste from comment #1) Certification for product procedure requires provide list of all files that was used during build. My manager wants to minimize that list and do not want provide .git files. https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=274198 also as part of this work.
newvers.sh looks for a .git directory and does not invoke git if not found.
(In reply to Ed Maste from comment #3) I do not want workaround with renaming git binary or renaming .git dir, I want NOGIT or similar knob start work. Also "auto detect" features without on/off switch produces unpredictable results, so REPRODUCIBLE_BUILD is not reproductable: newvers.sh give different output on systems with .git+git and on systems without it.