Skip to content

Allow defining of uname value for reproducible builds #5671

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

jelly
Copy link
Contributor

@jelly jelly commented Jun 5, 2020

Extend configure.ac to accept PHP_UNAME as env variable to set the value of the
PHP_UNAME define in a reproducible manner. This allows distributions to set a
fixed value for php_uname and keep the default behaviour if PHP_UNAME is not
set.

Motivation: https://reproducible-builds.org/

Extend configure.ac to accept PHP_UNAME as env variable to set the value of the
PHP_UNAME define in a reproducible manner. This allows distributions to set a
fixed value for php_uname and keep the default behaviour if PHP_UNAME is not
set.

Motivation: https://reproducible-builds.org/
@jelly
Copy link
Contributor Author

jelly commented Jun 5, 2020

It's currently not reproducible due to the recording of uname:

│ │  /* uname -a output */
│ │ -#define PHP_UNAME "Linux pierre 5.6.11-arch1-1 #1 SMP PREEMPT Wed, 06 May 2020 17:32:37 +0000 x86_64 GNU/Linux"                                                                                      
│ │ +#define PHP_UNAME "Linux php29646 4.19.0-5-amd64 #1 SMP Debian 4.19.37-5+deb10u1 (2019-07-19) x86_64 GNU/Linux"                                                                                      

Also note that Debian carries this patch for a while which would become obsolete. https://salsa.debian.org/php-team/php/-/blob/master-7.2/debian/patches/0036-php-5.4.9-fixheader.patch

@Girgias
Copy link
Member

Girgias commented Jun 6, 2020

I am no expert in build systems, but is this the only thing preventing from getting reproducible builds?
I would imagine that there are more things blocking the road to this.

Anyway I'm all for getting reproducible builds for php-src. :)

@jelly
Copy link
Contributor Author

jelly commented Jun 6, 2020

It's one of the last issues, another issue is phar.phar containing timestamps which should adhere to SOURCE_DATE_EPOCH. See this diff. https://tests.reproducible-builds.org/debian/rb-pkg/buster/amd64/diffoscope-results/php7.3.html

@Girgias
Copy link
Member

Girgias commented Jun 6, 2020

It's one of the last issues, another issue is phar.phar containing timestamps which should adhere to SOURCE_DATE_EPOCH. See this diff. https://tests.reproducible-builds.org/debian/rb-pkg/buster/amd64/diffoscope-results/php7.3.html

Well that's somewhat good to hear that we're mostly there to get reproducible builds then. :)

@remicollet
Copy link
Member

+1 as we also use the same patch in CentOS / Fedora / RHEL for years.

@php-pulls php-pulls closed this in d21b1c5 Jun 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants