Skip to content

Commit

Permalink
Turn on -Werror=implicit-function-declaration
Browse files Browse the repository at this point in the history
GCC 4.4, the minimum compiler version, supports this option.  Unlike
other warnings, -Wimplicit-function-declaration warnings should be
independent of compiler versions, so this change should not cause
compiler-specific build failures.
  • Loading branch information
Florian Weimer committed Sep 10, 2014
1 parent 9d3a350 commit e6fb958
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
8 changes: 8 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
2014-09-10 Florian Weimer <fweimer@redhat.com>

* Makeconfig (gccwarn-c): Turn implicit-function-declaration
warnings into errors.

* stdlib/tst-tls-atexit-lib.c: Include <stdlib.h>, for the
__cxa_thread_atexit_impl prototype.

2014-09-09 Steve Ellcey <sellcey@mips.com>

* sysdeps/mips/preconfigure: Put code inside mips* case statement.
Expand Down
2 changes: 1 addition & 1 deletion Makeconfig
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ else
+gccwarn := -Wall -Wwrite-strings -Winline
endif
+gccwarn += -Wundef
+gccwarn-c = -Wstrict-prototypes
+gccwarn-c = -Wstrict-prototypes -Werror=implicit-function-declaration

# We do not depend on the address of constants in different files to be
# actually different, so allow the compiler to merge them all.
Expand Down
2 changes: 2 additions & 0 deletions stdlib/tst-tls-atexit-lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */

#include <stdlib.h>

extern void *__dso_handle;

typedef struct
Expand Down

0 comments on commit e6fb958

Please sign in to comment.