mirror of
https://github.com/openRuyi-Project/gcc.git
synced 2026-10-03 23:48:37 +00:00
c-common.c (get_source_date_epoch): New function...
gcc/c-family/ChangeLog: 2016-04-28 Eduard Sanou <dhole@openmailbox.org> Matthias Klose <doko@debian.org> * c-common.c (get_source_date_epoch): New function, gets the environment variable SOURCE_DATE_EPOCH and parses it as long long with error handling. * c-common.h (get_source_date_epoch): Prototype. * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch. gcc/ChangeLog: 2016-04-28 Eduard Sanou <dhole@openmailbox.org> Matthias Klose <doko@debian.org> * doc/cppenv.texi: Document SOURCE_DATE_EPOCH environment variable. libcpp/ChangeLog: 2016-04-28 Eduard Sanou <dhole@openmailbox.org> Matthias Klose <doko@debian.org> * include/cpplib.h (cpp_init_source_date_epoch): Prototype. * init.c (cpp_init_source_date_epoch): New function. * internal.h: Added source_date_epoch variable to struct cpp_reader to store a reproducible date. * macro.c (_cpp_builtin_macro_text): Set pfile->date timestamp from pfile->source_date_epoch instead of localtime if source_date_epoch is set, to be used for __DATE__ and __TIME__ macros to help reproducible builds. Co-Authored-By: Matthias Klose <doko@debian.org> From-SVN: r235550
This commit is contained in:
committed by
Matthias Klose
co-authored by
Matthias Klose
parent
a564d35095
commit
174f66220d
@@ -1,3 +1,15 @@
|
||||
2016-04-28 Eduard Sanou <dhole@openmailbox.org>
|
||||
Matthias Klose <doko@debian.org>
|
||||
|
||||
* include/cpplib.h (cpp_init_source_date_epoch): Prototype.
|
||||
* init.c (cpp_init_source_date_epoch): New function.
|
||||
* internal.h: Added source_date_epoch variable to struct
|
||||
cpp_reader to store a reproducible date.
|
||||
* macro.c (_cpp_builtin_macro_text): Set pfile->date timestamp from
|
||||
pfile->source_date_epoch instead of localtime if source_date_epoch is
|
||||
set, to be used for __DATE__ and __TIME__ macros to help reproducible
|
||||
builds.
|
||||
|
||||
2016-04-13 Bernd Schmidt <bschmidt@redhat.com>
|
||||
|
||||
Patch from Roger Orr <rogero@howzatt.demon.co.uk>
|
||||
|
||||
Reference in New Issue
Block a user