Skip to content

Commit

Permalink
save-build-env: Strip out MAKEOPTS
Browse files Browse the repository at this point in the history
MAKEOPTS contains a host specific value. If the same package is built
on a host with different core counts, the binpkgs will have different
hashes. This change drops MAKEOPTS after src_install so that it's not
included in final environment.gz.

Bug: https://bugs.gentoo.org/914441
Signed-off-by: Raul E Rangel <rrangel@chromium.org>
  • Loading branch information
Raul E Rangel committed Mar 21, 2024
1 parent b276077 commit da62937
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions bin/save-ebuild-env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ __save_ebuild_env() {
unset S __E_DESTTREE __E_INSDESTTREE __E_DOCDESTTREE __E_EXEDESTTREE \
PORTAGE_DOCOMPRESS_SIZE_LIMIT PORTAGE_DOCOMPRESS \
PORTAGE_DOCOMPRESS_SKIP PORTAGE_DOSTRIP PORTAGE_DOSTRIP_SKIP
# This value contains build host specific configuration. We want
# binpkgs generated on different sized hosts to be identical,
# so strip this value from the binpkg. It's also not needed for
# installing / removing a package.
unset MAKEOPTS
if [[ -n ${PYTHONPATH} &&
${PYTHONPATH%%:*} -ef ${PORTAGE_PYM_PATH} ]] ; then
if [[ ${PYTHONPATH} == *:* ]] ; then
Expand Down

0 comments on commit da62937

Please sign in to comment.