tinycc-devel
[Top][All Lists]
Advanced

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

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


From: grischka
Subject: Re: [Tinycc-devel] Push reproducible builds script? (for windows)
Date: Tue, 26 Sep 2017 17:26:13 +0200
User-agent: Thunderbird 2.0.0.23 (Windows/20090812)

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

Not in principle.

Except I'd appreciate some concept to advise users which method to build
tcc on or for windows to use best in what situation.

We do support:
* msys with the normal ./configure && make && make install
* also cygwin with ./configure --cross-prefix=mingw32- && make && make install
* also cygwin with Jullien's Makefile from win32
* just mingw's gcc or msvc's cl with build-tcc.bat from win32, including
  option to install, no sh-shell required.
* maybe your reproducible build script, with again its own advantages as
  well as drawbacks.

What is your recommendation?  And how (if any) can we make sure that it
will reach users?

-- gr




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:
  http://lists.nongnu.org/archive/html/tinycc-devel/2016-10/msg00146.html

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:
  9fcbdd83e8a2a2c67ab6e1fb529b8f33

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

Any objections that I push it to mob?

- avih



------------------------------------------------------------------------

_______________________________________________
Tinycc-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/tinycc-devel




reply via email to

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