Skip to content

Commit 114ff6f

Browse files
ashimida123masahir0y
authored andcommitted
Documentation: kbuild: Add description of git for reproducible builds
The status of git will affect the final compilation result, add it to the documentation of reproducible builds. Signed-off-by: Dan Li <[email protected]> Signed-off-by: Masahiro Yamada <[email protected]>
1 parent 5c1df62 commit 114ff6f

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

Documentation/kbuild/reproducible-builds.rst

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,16 @@ To avoid this, you can make the vDSO different for different
119119
kernel versions by including an arbitrary string of "salt" in it.
120120
This is specified by the Kconfig symbol ``CONFIG_BUILD_SALT``.
121121

122+
Git
123+
---
124+
125+
Uncommitted changes or different commit ids in git can also lead
126+
to different compilation results. For example, after executing
127+
``git reset HEAD^``, even if the code is the same, the
128+
``include/config/kernel.release`` generated during compilation
129+
will be different, which will eventually lead to binary differences.
130+
See ``scripts/setlocalversion`` for details.
131+
122132
.. _KBUILD_BUILD_TIMESTAMP: kbuild.html#kbuild-build-timestamp
123133
.. _KBUILD_BUILD_USER and KBUILD_BUILD_HOST: kbuild.html#kbuild-build-user-kbuild-build-host
124134
.. _KCFLAGS: kbuild.html#kcflags

0 commit comments

Comments
 (0)