On Sat, Jan 12, 2019 at 4:07 PM Norihiro Tanaka <nori...@kcn.ne.jp> wrote: > I pulled current master of grep from git repository and built it on > fedora 29, and recieved following error. > > When we have no pcre library, DIE() in Pcompile and Pexecute is called, > but noreturn attribute is set to their functions. ... > pcresearch.c: In function 'Pcompile': > pcresearch.c:114:1: error: function might be candidate for attribute > 'noreturn' [-Werror=suggest-attribute=noreturn] > Pcompile (char *pattern, size_t size, reg_syntax_t ignored)
Thank you for the report. Technically, we could fix it by adding more ifdefs, but I think it would not be worthwhile to accommodate this use case. To resolve that, I suggest to install libpcre. Otherwise, when building without PCRE support, please either avoid the configure-time --enable-gcc-warnings option or invoke make with the "WERROR_CFLAGS=" option to suppress -Werror.