From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marius Bakke Subject: [PATCH 0/1] gnu: gcc@5: Make __DATE__ and __TIME__ macros reproducible. Date: Sat, 21 Jan 2017 12:36:21 +0100 Message-ID: <20170121113622.11721-1-mbakke@fastmail.com> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60472) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cUtyh-0007YU-QB for guix-devel@gnu.org; Sat, 21 Jan 2017 06:37:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cUtyc-0002oU-Ue for guix-devel@gnu.org; Sat, 21 Jan 2017 06:37:03 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:44638) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cUtyc-0002na-NX for guix-devel@gnu.org; Sat, 21 Jan 2017 06:36:58 -0500 List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org Cc: Marius Bakke Hello Guix! This patch should obsolete the 'snippets' that mess with the __DATE__ and __TIME__ macros in GCC. It is a backport of the following two commits: https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=e3e8c48c4a494d9da741c1c8ea6c4c0b7c4ff934 https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=dfa5c0d3f3e23e4fdb14857a42de376d9ff8601c ...with the ChangeLog entries omitted for easier maintenance. They *should* be functionally identical to Debians patches: https://anonscm.debian.org/viewvc/gcccvs/branches/sid/gcc-5/debian/patches/ ...but I have not verified this. Any takers? Tested with the following shell session: $ cat date.c #include int main() { printf( "__DATE__ says: %s \n", __DATE__ ); printf( "__TIME__ says: %s \n", __TIME__ ); return 0; } $ ./pre-inst-env guix environment --ad-hoc gcc@5 binutils glibc [env]$ gcc date.c && ./a.out __DATE__ says: Jan 21 2017 __TIME__ says: 11:28:06 [env]$ SOURCE_DATE_EPOCH=42 gcc date.c && ./a.out __DATE__ says: Jan 1 1970 __TIME__ says: 00:00:42 Note: the patch is against 'master' but is intended for 'core-updates'. \o/ Marius Bakke (1): gnu: gcc@5: Respect SOURCE_DATE_EPOCH in __DATE__ and __TIME__ macros. gnu/local.mk | 2 + gnu/packages/gcc.scm | 4 +- .../patches/gcc-5-source-date-epoch-1.patch | 223 +++++++++++ .../patches/gcc-5-source-date-epoch-2.patch | 410 +++++++++++++++++++++ 4 files changed, 638 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/gcc-5-source-date-epoch-1.patch create mode 100644 gnu/packages/patches/gcc-5-source-date-epoch-2.patch -- 2.11.0