Reproducible builds. Chroot environment, date and config.
Hi all,
Looking for reproducible builds in the Slackware Sub-Forum I only found 3 threads. One in 2015 other in 2016 and on 2021. But nothing relevant for mi question. Maybe I'm little daring. Maybe I have to much free time. Maybe I hope Slackware can do it. I am now playing with chroot to try made an environment for reproducible builds. From my understand to do a reproducible build there are 2 requirements, same date "SOURCE_DATE_EPOCH" and same environment. I am not an expert on C, compiler, environments, ... So sorry if I'm very wrong. From now i am trying to change the date on chroot to fix the SOURCE_DATE_EPOCH. I looking deeper to change the system date. Code:
[root@arcadia sis]# unshare -T -- chroot /tmp/HugeSlackBuildchroot/ /bin/bash --norc I installed desired packages on the chroot to build a random package and checksum it. Actually I use the random ncdu to test. I need the same packages installed on the environment rigth? That are trivial to install desired packages on a chroot. Done. I appreciate if someone can point me in the right way. I think containers are not the way, too heavy. I am on a rabbit hole? Can chroot do same as a container from the point of view of making a reproducible build? Construct same environment, date, etc... How many thinks are needed on the environment to make a reproducible build? From env: Code:
[root@arcadia tmp]# env I am looking deeper on internet but some help are welcome. I do not believe that I lost time if I do not get to a good end, at least I always learn something. I wrote some garbage scripts in Github from which I am doing the tests. https://github.com/VielLosero/HugeSlackBuilds All welcome. Thanks in advance. Edited: Maybe no the right forum Viel. |
All times are GMT -5. The time now is 02:38 PM. |