From: Benedikt Morbach <bmorb...@redhat.com> This ensures that rebuilds of an srpm result in the same .py{c,o} files, even if the source files were modified during the build. This should make the builds of most python packages reproducible.
The downside here is that we don't preserve the mtime of the sources anymore. However, as of right now a user can't tell by looking at a file on disk if it has the original source mtime or was modified during build, which makes having the mtime near useless anyway, in my opinion. --- scripts/brp-python-bytecompile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/brp-python-bytecompile b/scripts/brp-python-bytecompile index 39fca60..6d93441 100644 --- a/scripts/brp-python-bytecompile +++ b/scripts/brp-python-bytecompile @@ -14,7 +14,7 @@ fi # Figure out how deep we need to descend. We could pick an insanely high # number and hope it's enough, but somewhere, somebody's sure to run into it. -depth=`(find "$RPM_BUILD_ROOT" -type f -name "*.py" -print0 ; echo /) | \ +depth=`(find "$RPM_BUILD_ROOT" -type f -name "*.py" -exec touch "$RPM_CHANGELOG_DATE" {} \+ -print0 ; echo /) | \ xargs -0 -n 1 dirname | sed 's,[^/],,g' | sort -u | tail -n 1 | wc -c` if [ -z "$depth" -o "$depth" -le "1" ]; then exit 0 -- 2.0.4 _______________________________________________ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint