mirror of
https://github.com/xzeldon/htop.git
synced 2024-12-25 23:35:45 +00:00
configure: add option --enable-werror
Adds the compiler flag -Werror to fail on warnings. Useful for CI runs.
This commit is contained in:
parent
0b276f80f1
commit
57254cdd05
@ -12,7 +12,7 @@ applications_DATA = htop.desktop
|
||||
pixmapdir = $(datadir)/pixmaps
|
||||
pixmap_DATA = htop.png
|
||||
|
||||
AM_CFLAGS = -pedantic -Wall $(wextra_flag) -std=c99 -D_XOPEN_SOURCE_EXTENDED -DSYSCONFDIR=\"$(sysconfdir)\" -I"$(top_srcdir)/$(my_htop_platform)"
|
||||
AM_CFLAGS += -pedantic -Wall $(wextra_flag) -std=c99 -D_XOPEN_SOURCE_EXTENDED -DSYSCONFDIR=\"$(sysconfdir)\" -I"$(top_srcdir)/$(my_htop_platform)"
|
||||
AM_LDFLAGS =
|
||||
AM_CPPFLAGS = -DNDEBUG
|
||||
|
||||
|
@ -295,6 +295,9 @@ then
|
||||
])
|
||||
fi
|
||||
|
||||
AC_ARG_ENABLE([werror], [AS_HELP_STRING([--enable-werror], [Treat warnings as errors (default: warnings are not errors)])], [enable_werror="$enableval"], [enable_werror=no])
|
||||
AS_IF([test "x$enable_werror" = "xyes"], [AM_CFLAGS="$AM_CFLAGS -Werror"])
|
||||
AC_SUBST([AM_CFLAGS])
|
||||
|
||||
# Bail out on errors.
|
||||
# ----------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user