[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Tinycc-devel] Push reproducible builds script? (for windows)

From: avih
Subject: [Tinycc-devel] Push reproducible builds script? (for windows)
Date: Tue, 26 Sep 2017 13:40:03 +0000 (UTC)

I'd like to push my reproducible build script to mob, are there objections?

In a nutshell, it's a shell script which builds windows tcc distribution (4 of
them actually: 32, 64, cross 32->64 and 64->32) with reproducible output
regardless of the host or initial CC (in fact, it just doesn't care at all what
the host is or which CC is used), and then prints a checksum of the output.

Tested with several versions of gcc, clang, tcc, cl (msvc compiler), on
different systems (linux 32/64, msys2/mingw, osx, freebsd, busybox on windows,
and others), and it always produces identical output for any git revision.

I've been using this script for my tcc builds, and had no issues with it. The
resulting tcc binaries can be used as CC for the normal configure && make &&
make test procedure and the result passes all tests.

It's similar to win32/build-tcc.bat and win32/Makefile but I think it has few
advantages over them:

- Works on any OS and with any compiler

- Deterministic/identical output regardless of the host/compiler.

- Simple posix shell script which doesn't require dev tools (other than
  a compiler binary), such that it can even run in busybox on windows without
  any further tools (and use a tcc or cl compiler).

This is pretty much the same as I posted about a year ago:

With the following minimal differences:
- Try to find a compiler automatically (gcc/cc/tcc/cl) if CC is not set.
- Use the new "tcc -ar" instead of tinylibmaker .
- Now also works on freebsd (following commit abd1532 from yesterday).

E.g. for the current mob ( 8deb05c ) the reproducible build signature is:

Find the recent version attached (to test: place it at the win32 dir and run).

Any objections that I push it to mob?

- avih

Attachment: build-tcc-reproducible.sh
Description: Binary data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]