<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Wed, Aug 24, 2016 at 11:07 AM, Reid Kleckner <span dir="ltr"><<a href="mailto:rnk@google.com" target="_blank">rnk@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><p dir="ltr">It's still hacky, but I bet -U__DATE__ -D__DATE__=x still works.</p></blockquote><div>That's a good idea, but it seems to trigger "warning: undefining builtin macro [-Wbuiltin-macro-redefined]" instead.<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><p dir="ltr">Sent from phone</p>
<div class="gmail_extra"><br><div class="gmail_quote"><div><div class="gmail-h5">On Aug 24, 2016 7:53 AM, "Nico Weber via cfe-dev" <<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a>> wrote:<br type="attribution"></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div><div class="gmail-h5"><div dir="ltr">Hi,<div><br></div><div>we're trying to make our build more deterministic. Several third-party libraries we depend on use __DATE__ and __TIME__, which makes that part of the build nondeterministic. So we'd like to force both of them to a fixed value via some flag.</div><div><br></div><div>-D__DATE__= -D__TIME__= kind of works, but it triggers Wbuiltin-macro-redefi<wbr>ned warnings (and it also causes a crash when using them with pchs). Is using -D flags the right approach for this? It seems a bit hacky. Would there be interest in adding a (say) -ffixed-date-time=1997-07-16T1<wbr>9:20+01:00 flag that sets the initial value of __DATE__ and __TIME__ so that we don't have to redefine them?</div><div><br></div><div>Nico</div></div>
<br></div></div>______________________________<wbr>_________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div></div>
</blockquote></div><br></div></div>