GNU bug report logs -
#44535
grep-3.6 released [stable]
Previous Next
Reported by: Andreas Schwab <schwab <at> suse.de>
Date: Mon, 9 Nov 2020 16:14:02 UTC
Severity: normal
Done: Paul Eggert <eggert <at> cs.ucla.edu>
Bug is archived. No further changes may be made.
Full log
Message #14 received at 44535 <at> debbugs.gnu.org (full text, mbox):
On 11/9/20 8:12 AM, Andreas Schwab wrote:
> grep 3.6 fails to build:
>
> test-nl_langinfo-mt.c: In function 'threadN_func':
> test-nl_langinfo-mt.c:185:1: error: no return statement in function returning non-void [-Werror=return-type]
> 185 | }
> | ^
> cc1: some warnings being treated as errors
> make[4]: *** [Makefile:4221: test-nl_langinfo-mt.o] Error 1
We have dueling compilers here, as Sun C complains if the return statements are
present[1], whereas gcc -Wreturn-type complains if they're absent. Since the
return statements are clearly bogus and unnecessary I'm inclined to continue to
omit them.
> https://build.opensuse.org/package/live_build_log/home:Andreas_Schwab:Factory/grep/f/x86_64
This says you're configuring with CFLAGS='... -Werror=return-type ...'. If you
omit the "-Werror=return-type" option the problem should go away. For 'grep',
that option is more trouble than it's worth. (Perhaps someone should file a GCC
bug report....)
For the recommended set of warning options for compiling 'grep', you can use
'./configure --enable-gcc-warnings' instead.
[1]
https://git.savannah.gnu.org/cgit/gnulib.git/commit/?id=bd90572c031a25e559907ae0c2b9fd3aa632893b
This bug report was last modified 4 years and 183 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.