Commit 0428f621 authored by Eli Schwartz's avatar Eli Schwartz Committed by Allan McRae
Browse files

makepkg: add the $startdir to package .BUILDINFO



This value is needed for reproducible builds. The reason is because
$BUILDDIR changes its behavior depending on whether it is the same as
$startdir, and the result is that we cannot know whether $srcdir (the
path that is potentially embedded into the final package) is actually
"$BUILDDIR/src" or "$BUILDDIR/$pkgbase/src".
Signed-off-by: Eli Schwartz's avatarEli Schwartz <eschwartz@archlinux.org>
Signed-off-by: Allan McRae's avatarAllan McRae <allan@archlinux.org>
parent 1e23b458
......@@ -53,6 +53,9 @@ BUILDINFO file format.
*builddir*::
The directory where the package was built.
*startdir*::
The directory from which makepkg was executed.
*buildenv (array)*::
The build environment specified in makepkg.conf.
......
......@@ -626,7 +626,7 @@ write_pkginfo() {
}
write_buildinfo() {
write_kv_pair "format" "1"
write_kv_pair "format" "2"
write_kv_pair "pkgname" "$pkgname"
write_kv_pair "pkgbase" "$pkgbase"
......@@ -643,6 +643,7 @@ write_buildinfo() {
write_kv_pair "packager" "${PACKAGER}"
write_kv_pair "builddate" "${SOURCE_DATE_EPOCH}"
write_kv_pair "builddir" "${BUILDDIR}"
write_kv_pair "startdir" "${startdir}"
write_kv_pair "buildenv" "${BUILDENV[@]}"
write_kv_pair "options" "${OPTIONS[@]}"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment