[PATCH] D17741: adds __FILE_BASENAME__ builtin macro
Nolan O'Brien via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 3 07:54:43 PST 2019
I believe reproducible build projects simply move their source to `/tmp/build` or something else that’s consistent to deal with `__FILE__` currently. They’d probably appreciate this to avoid file copying during `make` builds
Nolan O'Brien
Sent from my iPhone
> On Jan 3, 2019, at 7:47 AM, Roman Lebedev <lebedev.ri at gmail.com> wrote:
>
> Just a thought: reproducible builds will surely be interested in this.
> Did gcc already solve this problem? And if yes, it would be best to be
> compatible.
>
> On Thu, Jan 3, 2019 at 6:41 PM Nolan O'Brien via Phabricator via
> cfe-commits <cfe-commits at lists.llvm.org> wrote:
>>
>> NSProgrammer added a comment.
>>
>> To throw in my 2 cents. I don’t really have a preference between a compiler flag vs a different macro that’s just for the file name sans path prefix. But I have a real need for this to get into clang: with 1.2 million lines of code, the regular placement of log statements and custom asserts leads to megabytes in binary size from all the __FILE__ usages, and that could easily be a few hundred KB with this kind of support in clang.
>>
>>
>> CHANGES SINCE LAST ACTION
>> https://reviews.llvm.org/D17741/new/
>>
>> https://reviews.llvm.org/D17741
>>
>>
>>
>> _______________________________________________
>> cfe-commits mailing list
>> cfe-commits at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
More information about the cfe-commits
mailing list