[Nix-dev] Deterministic(bit-perfect) Builds

Vladimír Čunát vcunat at gmail.com
Tue Jun 25 13:54:30 CEST 2013


On 06/25/2013 01:20 PM, Vladimír Čunát wrote:
> On 06/25/2013 11:43 AM, phreedom at yandex.ru wrote:
>>> Wouldn't it be more certain/universal to LD_PRELOAD or something to
>>> achieve that the system time always looks the same to any build-time
>>> tool? (e.g. UNIX time =0)
>>
>> This is a bit platform-specific and there may be other gotchas like
>> getting the
>> mtime using stat instead of querying system time. Other impurities in
>> static
>> libs are uid/gid of the file.
>
> I would think that the file timestamps also originate from system time
> so we could kill more birds with one stone... but I don't have a clue
> whether/how such a sandbox can be done easily (in Linux; I assume our
> main target for purity is Linux, the others are impure for other reasons
> as well).

Ah, I knew I've seen the answer before, somewhere... libfaketime :-)

https://github.com/wolfcw/libfaketime/blob/master/README


Vlada


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3251 bytes
Desc: S/MIME Cryptographic Signature
Url : http://lists.science.uu.nl/pipermail/nix-dev/attachments/20130625/1dd8f5bc/attachment.bin 


More information about the nix-dev mailing list