sim: call SIM_AC_OPTION_WARNINGS(no) in remaining ports
We want all ports to opt into extra warnings as the default compiler settings lets a lot slide. Opt all the ports that haven't already in to the warning system. None of them build with -Werror, so disable that by default. Hopefully someone finds these important enough to start fixing at some point.
This commit is contained in:
parent
a0c38f0d70
commit
5c1008a41f
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/bpf/configure
vendored
109
sim/bpf/configure
vendored
@ -788,6 +788,9 @@ enable_sim_endian
|
||||
enable_sim_alignment
|
||||
enable_sim_scache
|
||||
enable_sim_default_model
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
enable_cgen_maint
|
||||
'
|
||||
ac_precious_vars='build_alias
|
||||
@ -1448,6 +1451,11 @@ Optional Features:
|
||||
Specify simulator execution cache size
|
||||
--enable-sim-default-model=model
|
||||
Specify default model to simulate
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
--enable-cgen-maint=DIR build cgen generated files
|
||||
|
||||
Optional Packages:
|
||||
@ -12934,7 +12942,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12937 "configure"
|
||||
#line 12945 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13040,7 +13048,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13043 "configure"
|
||||
#line 13051 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13777,6 +13785,103 @@ fi
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
cgen_maint=no
|
||||
cgen=guile
|
||||
cgendir='$(srcdir)/../../cgen'
|
||||
|
@ -9,6 +9,7 @@ SIM_AC_OPTION_ENDIAN([], [LITTLE])
|
||||
SIM_AC_OPTION_ALIGNMENT(NONSTRICT_ALIGNMENT)
|
||||
SIM_AC_OPTION_SCACHE(16384)
|
||||
SIM_AC_OPTION_DEFAULT_MODEL([bpf-def])
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
SIM_AC_OPTION_CGEN_MAINT
|
||||
|
||||
SIM_AC_OUTPUT
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/erc32/configure
vendored
109
sim/erc32/configure
vendored
@ -782,6 +782,9 @@ enable_sim_environment
|
||||
enable_sim_inline
|
||||
with_pkgversion
|
||||
with_bugurl
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
'
|
||||
ac_precious_vars='build_alias
|
||||
host_alias
|
||||
@ -1431,6 +1434,11 @@ Optional Features:
|
||||
environment
|
||||
--enable-sim-inline=inlines
|
||||
Specify which functions should be inlined
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
|
||||
Optional Packages:
|
||||
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
|
||||
@ -12916,7 +12924,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12919 "configure"
|
||||
#line 12927 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13022,7 +13030,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13025 "configure"
|
||||
#line 13033 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13573,6 +13581,103 @@ _ACEOF
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
# In the Cygwin environment, we need some additional flags.
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cygwin" >&5
|
||||
$as_echo_n "checking for cygwin... " >&6; }
|
||||
|
@ -18,6 +18,7 @@ AC_INIT(Makefile.in)
|
||||
sinclude(../common/acinclude.m4)
|
||||
|
||||
SIM_AC_COMMON
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
|
||||
# In the Cygwin environment, we need some additional flags.
|
||||
AC_CACHE_CHECK([for cygwin], sim_cv_os_cygwin,
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/frv/configure
vendored
109
sim/frv/configure
vendored
@ -788,6 +788,9 @@ enable_sim_endian
|
||||
enable_sim_alignment
|
||||
enable_sim_scache
|
||||
enable_sim_default_model
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
enable_cgen_maint
|
||||
enable_sim_trapdump
|
||||
enable_sim_hardware
|
||||
@ -1449,6 +1452,11 @@ Optional Features:
|
||||
Specify simulator execution cache size
|
||||
--enable-sim-default-model=model
|
||||
Specify default model to simulate
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
--enable-cgen-maint=DIR build cgen generated files
|
||||
--enable-sim-trapdump Make unknown traps dump the registers
|
||||
--enable-sim-hardware=LIST
|
||||
@ -12938,7 +12946,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12941 "configure"
|
||||
#line 12949 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13044,7 +13052,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13047 "configure"
|
||||
#line 13055 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13722,6 +13730,103 @@ fi
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
cgen_maint=no
|
||||
cgen=guile
|
||||
cgendir='$(srcdir)/../../cgen'
|
||||
|
@ -8,6 +8,7 @@ SIM_AC_OPTION_ENDIAN(BIG)
|
||||
SIM_AC_OPTION_ALIGNMENT(STRICT_ALIGNMENT)
|
||||
SIM_AC_OPTION_SCACHE(16384)
|
||||
SIM_AC_OPTION_DEFAULT_MODEL(fr500)
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
SIM_AC_OPTION_CGEN_MAINT
|
||||
|
||||
#
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/h8300/configure
vendored
109
sim/h8300/configure
vendored
@ -782,6 +782,9 @@ with_pkgversion
|
||||
with_bugurl
|
||||
enable_sim_endian
|
||||
enable_sim_alignment
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
'
|
||||
ac_precious_vars='build_alias
|
||||
host_alias
|
||||
@ -1436,6 +1439,11 @@ Optional Features:
|
||||
--enable-sim-alignment=align
|
||||
Specify strict, nonstrict or forced alignment of
|
||||
memory accesses
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
|
||||
Optional Packages:
|
||||
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
|
||||
@ -12921,7 +12929,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12924 "configure"
|
||||
#line 12932 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13027,7 +13035,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13030 "configure"
|
||||
#line 13038 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13670,6 +13678,103 @@ fi
|
||||
fi
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
for ac_header in sys/param.h
|
||||
do :
|
||||
ac_fn_c_check_header_mongrel "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default"
|
||||
|
@ -6,6 +6,7 @@ SIM_AC_COMMON
|
||||
|
||||
SIM_AC_OPTION_ENDIAN(BIG)
|
||||
SIM_AC_OPTION_ALIGNMENT(NONSTRICT_ALIGNMENT)
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
|
||||
AC_CHECK_HEADERS(sys/param.h)
|
||||
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/iq2000/configure
vendored
109
sim/iq2000/configure
vendored
@ -787,6 +787,9 @@ enable_sim_endian
|
||||
enable_sim_alignment
|
||||
enable_sim_scache
|
||||
enable_sim_default_model
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
enable_cgen_maint
|
||||
enable_sim_hardware
|
||||
'
|
||||
@ -1447,6 +1450,11 @@ Optional Features:
|
||||
Specify simulator execution cache size
|
||||
--enable-sim-default-model=model
|
||||
Specify default model to simulate
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
--enable-cgen-maint=DIR build cgen generated files
|
||||
--enable-sim-hardware=LIST
|
||||
Specify the hardware to be included in the build.
|
||||
@ -12935,7 +12943,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12938 "configure"
|
||||
#line 12946 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13041,7 +13049,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13044 "configure"
|
||||
#line 13052 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13719,6 +13727,103 @@ fi
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
cgen_maint=no
|
||||
cgen=guile
|
||||
cgendir='$(srcdir)/../../cgen'
|
||||
|
@ -8,6 +8,7 @@ SIM_AC_OPTION_ENDIAN(BIG)
|
||||
SIM_AC_OPTION_ALIGNMENT(STRICT_ALIGNMENT)
|
||||
SIM_AC_OPTION_SCACHE(16384)
|
||||
SIM_AC_OPTION_DEFAULT_MODEL(iq2000)
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
SIM_AC_OPTION_CGEN_MAINT
|
||||
|
||||
SIM_AC_OPTION_HARDWARE(yes,"","")
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/lm32/configure
vendored
109
sim/lm32/configure
vendored
@ -787,6 +787,9 @@ enable_sim_endian
|
||||
enable_sim_alignment
|
||||
enable_sim_scache
|
||||
enable_sim_default_model
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
enable_cgen_maint
|
||||
enable_sim_hardware
|
||||
'
|
||||
@ -1447,6 +1450,11 @@ Optional Features:
|
||||
Specify simulator execution cache size
|
||||
--enable-sim-default-model=model
|
||||
Specify default model to simulate
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
--enable-cgen-maint=DIR build cgen generated files
|
||||
--enable-sim-hardware=LIST
|
||||
Specify the hardware to be included in the build.
|
||||
@ -12935,7 +12943,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12938 "configure"
|
||||
#line 12946 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13041,7 +13049,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13044 "configure"
|
||||
#line 13052 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13719,6 +13727,103 @@ fi
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
cgen_maint=no
|
||||
cgen=guile
|
||||
cgendir='$(srcdir)/../../cgen'
|
||||
|
@ -8,6 +8,7 @@ SIM_AC_OPTION_ENDIAN(BIG)
|
||||
SIM_AC_OPTION_ALIGNMENT(STRICT_ALIGNMENT,STRICT_ALIGNMENT)
|
||||
SIM_AC_OPTION_SCACHE(16384)
|
||||
SIM_AC_OPTION_DEFAULT_MODEL(lm32)
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
SIM_AC_OPTION_CGEN_MAINT
|
||||
SIM_AC_OPTION_HARDWARE(yes,,lm32cpu lm32timer lm32uart)
|
||||
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/m32r/configure
vendored
109
sim/m32r/configure
vendored
@ -789,6 +789,9 @@ enable_sim_endian
|
||||
enable_sim_alignment
|
||||
enable_sim_scache
|
||||
enable_sim_default_model
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
enable_cgen_maint
|
||||
enable_sim_hardware
|
||||
'
|
||||
@ -1449,6 +1452,11 @@ Optional Features:
|
||||
Specify simulator execution cache size
|
||||
--enable-sim-default-model=model
|
||||
Specify default model to simulate
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
--enable-cgen-maint=DIR build cgen generated files
|
||||
--enable-sim-hardware=LIST
|
||||
Specify the hardware to be included in the build.
|
||||
@ -12937,7 +12945,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12940 "configure"
|
||||
#line 12948 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13043,7 +13051,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13046 "configure"
|
||||
#line 13054 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13721,6 +13729,103 @@ fi
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
cgen_maint=no
|
||||
cgen=guile
|
||||
cgendir='$(srcdir)/../../cgen'
|
||||
|
@ -8,6 +8,7 @@ SIM_AC_OPTION_ENDIAN(BIG)
|
||||
SIM_AC_OPTION_ALIGNMENT(STRICT_ALIGNMENT)
|
||||
SIM_AC_OPTION_SCACHE(16384)
|
||||
SIM_AC_OPTION_DEFAULT_MODEL(m32r/d)
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
SIM_AC_OPTION_CGEN_MAINT
|
||||
|
||||
case "${target_alias}" in
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* sim-main.h: Include config.h.
|
||||
|
109
sim/or1k/configure
vendored
109
sim/or1k/configure
vendored
@ -788,6 +788,9 @@ enable_sim_alignment
|
||||
enable_sim_bitsize
|
||||
enable_sim_scache
|
||||
enable_sim_default_model
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
enable_cgen_maint
|
||||
'
|
||||
ac_precious_vars='build_alias
|
||||
@ -1448,6 +1451,11 @@ Optional Features:
|
||||
Specify simulator execution cache size
|
||||
--enable-sim-default-model=model
|
||||
Specify default model to simulate
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
--enable-cgen-maint=DIR build cgen generated files
|
||||
|
||||
Optional Packages:
|
||||
@ -12934,7 +12942,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12937 "configure"
|
||||
#line 12945 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13040,7 +13048,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13043 "configure"
|
||||
#line 13051 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13777,6 +13785,103 @@ fi
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking default sim environment setting" >&5
|
||||
$as_echo_n "checking default sim environment setting... " >&6; }
|
||||
sim_environment="ALL_ENVIRONMENT"
|
||||
|
@ -9,6 +9,7 @@ SIM_AC_OPTION_ALIGNMENT(STRICT_ALIGNMENT)
|
||||
SIM_AC_OPTION_BITSIZE([32], [31], [32])
|
||||
SIM_AC_OPTION_SCACHE(16384)
|
||||
SIM_AC_OPTION_DEFAULT_MODEL([or1200])
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
SIM_AC_OPTION_ENVIRONMENT
|
||||
SIM_AC_OPTION_INLINE()
|
||||
SIM_AC_OPTION_CGEN_MAINT
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* cpu.h (pc): Change to an extern.
|
||||
|
109
sim/rl78/configure
vendored
109
sim/rl78/configure
vendored
@ -780,6 +780,9 @@ enable_sim_environment
|
||||
enable_sim_inline
|
||||
with_pkgversion
|
||||
with_bugurl
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
'
|
||||
ac_precious_vars='build_alias
|
||||
host_alias
|
||||
@ -1429,6 +1432,11 @@ Optional Features:
|
||||
environment
|
||||
--enable-sim-inline=inlines
|
||||
Specify which functions should be inlined
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
|
||||
Optional Packages:
|
||||
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
|
||||
@ -12914,7 +12922,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12917 "configure"
|
||||
#line 12925 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13020,7 +13028,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13023 "configure"
|
||||
#line 13031 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13571,6 +13579,103 @@ _ACEOF
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
for ac_header in getopt.h
|
||||
do :
|
||||
ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
|
||||
|
@ -22,6 +22,7 @@ AC_INIT(Makefile.in)
|
||||
sinclude(../common/acinclude.m4)
|
||||
|
||||
SIM_AC_COMMON
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
|
||||
AC_CHECK_HEADERS(getopt.h)
|
||||
|
||||
|
@ -1,3 +1,8 @@
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* configure.ac: Call SIM_AC_OPTION_WARNINGS.
|
||||
* configure: Regenerate.
|
||||
|
||||
2021-01-11 Mike Frysinger <vapier@gentoo.org>
|
||||
|
||||
* config.in, configure: Regenerate.
|
||||
|
109
sim/rx/configure
vendored
109
sim/rx/configure
vendored
@ -780,6 +780,9 @@ enable_sim_environment
|
||||
enable_sim_inline
|
||||
with_pkgversion
|
||||
with_bugurl
|
||||
enable_werror
|
||||
enable_build_warnings
|
||||
enable_sim_build_warnings
|
||||
enable_cycle_accurate
|
||||
enable_cycle_stats
|
||||
'
|
||||
@ -1431,6 +1434,11 @@ Optional Features:
|
||||
environment
|
||||
--enable-sim-inline=inlines
|
||||
Specify which functions should be inlined
|
||||
--enable-werror treat compile warnings as errors
|
||||
--enable-build-warnings enable build-time compiler warnings if gcc is used
|
||||
--enable-sim-build-warnings
|
||||
enable SIM specific build-time compiler warnings if
|
||||
gcc is used
|
||||
--disable-cycle-accurate
|
||||
Disable cycle accurate simulation (faster runtime)
|
||||
--disable-cycle-stats Disable cycle statistics (faster runtime)
|
||||
@ -12919,7 +12927,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 12922 "configure"
|
||||
#line 12930 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13025,7 +13033,7 @@ else
|
||||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 13028 "configure"
|
||||
#line 13036 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
@ -13576,6 +13584,103 @@ _ACEOF
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-werror was given.
|
||||
if test "${enable_werror+set}" = set; then :
|
||||
enableval=$enable_werror; case "${enableval}" in
|
||||
yes | y) ERROR_ON_WARNING="yes" ;;
|
||||
no | n) ERROR_ON_WARNING="no" ;;
|
||||
*) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
||||
# Enable -Werror by default when using gcc
|
||||
if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
|
||||
ERROR_ON_WARNING=yes
|
||||
fi
|
||||
|
||||
WERROR_CFLAGS=""
|
||||
|
||||
build_warnings="-Wall -Wdeclaration-after-statement -Wpointer-arith \
|
||||
-Wpointer-sign \
|
||||
-Wno-unused -Wunused-value -Wunused-function \
|
||||
-Wno-switch -Wno-char-subscripts -Wmissing-prototypes
|
||||
-Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type \
|
||||
-Wold-style-declaration -Wold-style-definition"
|
||||
|
||||
# Enable -Wno-format by default when using gcc on mingw since many
|
||||
# GCC versions complain about %I64.
|
||||
case "${host}" in
|
||||
*-*-mingw32*) build_warnings="$build_warnings -Wno-format" ;;
|
||||
*) build_warnings="$build_warnings -Wformat-nonliteral" ;;
|
||||
esac
|
||||
|
||||
# Check whether --enable-build-warnings was given.
|
||||
if test "${enable_build_warnings+set}" = set; then :
|
||||
enableval=$enable_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
# Check whether --enable-sim-build-warnings was given.
|
||||
if test "${enable_sim_build_warnings+set}" = set; then :
|
||||
enableval=$enable_sim_build_warnings; case "${enableval}" in
|
||||
yes) ;;
|
||||
no) build_warnings="-w";;
|
||||
,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${build_warnings} ${t}";;
|
||||
*,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
|
||||
build_warnings="${t} ${build_warnings}";;
|
||||
*) build_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
|
||||
esac
|
||||
if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
|
||||
echo "Setting GDB specific compiler warning flags = $build_warnings" 6>&1
|
||||
fi
|
||||
fi
|
||||
WARN_CFLAGS=""
|
||||
if test "x${build_warnings}" != x -a "x$GCC" = xyes
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler warning flags" >&5
|
||||
$as_echo_n "checking compiler warning flags... " >&6; }
|
||||
# Separate out the -Werror flag as some files just cannot be
|
||||
# compiled with it enabled.
|
||||
for w in ${build_warnings}; do
|
||||
case $w in
|
||||
-Werr*) WERROR_CFLAGS=-Werror ;;
|
||||
*) # Check that GCC accepts it
|
||||
saved_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS $w"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
WARN_CFLAGS="${WARN_CFLAGS} $w"
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$saved_CFLAGS"
|
||||
esac
|
||||
done
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${WARN_CFLAGS} ${WERROR_CFLAGS}" >&5
|
||||
$as_echo "${WARN_CFLAGS} ${WERROR_CFLAGS}" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
for ac_header in getopt.h
|
||||
do :
|
||||
ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
|
||||
|
@ -22,6 +22,7 @@ AC_INIT(Makefile.in)
|
||||
sinclude(../common/acinclude.m4)
|
||||
|
||||
SIM_AC_COMMON
|
||||
SIM_AC_OPTION_WARNINGS(no)
|
||||
|
||||
AC_CHECK_HEADERS(getopt.h)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user