mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
tools: Add -Werror by default to all tools/
And provide an option to ./configure to disable it. A follow-up patch will remove -Werror from every other Makefile in tools/. Signed-off-by: Anthony PERARD <anthony.perard@citrix.com> Reviewed-by: Luca Fancellu <luca.fancellu@arm.com> Acked-by: Andrew Cooper <andrew.cooper3@citrix.com> Release-acked-by: Henry Wang <Henry.Wang@arm.com>
This commit is contained in:
1 parent
fcdb9cdb95
commit
e4f5949c44
4 files changed
+32
No files matched your search
@@ -1,5 +1,6 @@
|
||||
-include $(XEN_ROOT)/config/Paths.mk
|
||||
|
||||
CONFIG_WERROR := @werror@
|
||||
CONFIG_RUMP := @CONFIG_RUMP@
|
||||
ifeq ($(CONFIG_RUMP),y)
|
||||
XEN_OS := NetBSDRump
|
||||
|
||||
@@ -133,6 +133,10 @@ endif
|
||||
|
||||
CFLAGS_libxenlight += $(CFLAGS_libxenctrl)
|
||||
|
||||
ifeq ($(CONFIG_WERROR),y)
|
||||
CFLAGS += -Werror
|
||||
endif
|
||||
|
||||
ifeq ($(debug),y)
|
||||
# Use -Og if available, -O0 otherwise
|
||||
dbg_opt_level := $(call cc-option,$(CC),-Og,-O0)
|
||||
|
||||
Vendored
+26
@@ -716,6 +716,7 @@ ocamltools
|
||||
monitors
|
||||
githttp
|
||||
rpath
|
||||
werror
|
||||
DEBUG_DIR
|
||||
XEN_DUMP_DIR
|
||||
XEN_PAGING_DIR
|
||||
@@ -805,6 +806,7 @@ with_xen_scriptdir
|
||||
with_xen_dumpdir
|
||||
with_rundir
|
||||
with_debugdir
|
||||
enable_werror
|
||||
enable_rpath
|
||||
enable_githttp
|
||||
enable_monitors
|
||||
@@ -1490,6 +1492,7 @@ Optional Features:
|
||||
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
|
||||
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
|
||||
--disable-largefile omit support for large files
|
||||
--disable-werror Build tools without -Werror (default is ENABLED)
|
||||
--enable-rpath Build tools with -Wl,-rpath,LIBDIR (default is
|
||||
DISABLED)
|
||||
--enable-githttp Download GIT repositories via HTTP (default is
|
||||
@@ -4111,6 +4114,29 @@ DEBUG_DIR=$debugdir_path
|
||||
|
||||
# Enable/disable options
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror;
|
||||
fi
|
||||
|
||||
|
||||
if test "x$enable_werror" = "xno"; then :
|
||||
|
||||
ax_cv_werror="n"
|
||||
|
||||
elif test "x$enable_werror" = "xyes"; then :
|
||||
|
||||
ax_cv_werror="y"
|
||||
|
||||
elif test -z $ax_cv_werror; then :
|
||||
|
||||
ax_cv_werror="y"
|
||||
|
||||
fi
|
||||
werror=$ax_cv_werror
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-rpath was given.
|
||||
if test "${enable_rpath+set}" = set; then :
|
||||
enableval=$enable_rpath;
|
||||
|
||||
@@ -81,6 +81,7 @@ m4_include([../m4/header.m4])
|
||||
AX_XEN_EXPAND_CONFIG()
|
||||
|
||||
# Enable/disable options
|
||||
AX_ARG_DEFAULT_ENABLE([werror], [Build tools without -Werror])
|
||||
AX_ARG_DEFAULT_DISABLE([rpath], [Build tools with -Wl,-rpath,LIBDIR])
|
||||
AX_ARG_DEFAULT_DISABLE([githttp], [Download GIT repositories via HTTP])
|
||||
AX_ARG_DEFAULT_ENABLE([monitors], [Disable xenstat and xentop monitoring tools])
|
||||
|
||||