aboutsummaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorDaniel Lange <DLange@git.local>2021-10-15 09:03:04 +0200
committerDaniel Lange <DLange@git.local>2021-10-15 09:03:04 +0200
commit30ce3b4c264c51c98f280e88e23792ff7deb2317 (patch)
treef9730c54ab9d86ce57ce636f2fba1fdc03f46072 /configure.ac
parent69f439eff387a6ecb52734e400b297a3c85f2285 (diff)
downloaddebian_htop-30ce3b4c264c51c98f280e88e23792ff7deb2317.tar.gz
debian_htop-30ce3b4c264c51c98f280e88e23792ff7deb2317.tar.bz2
debian_htop-30ce3b4c264c51c98f280e88e23792ff7deb2317.zip
New upstream version 3.1.1upstream/3.1.1
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac42
1 files changed, 37 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac
index e93afbd..1b72222 100644
--- a/configure.ac
+++ b/configure.ac
@@ -6,7 +6,7 @@
# ----------------------------------------------------------------------
AC_PREREQ([2.69])
-AC_INIT([htop], [3.1.0], [htop@groups.io], [], [https://htop.dev/])
+AC_INIT([htop], [3.1.1], [htop@groups.io], [], [https://htop.dev/])
AC_CONFIG_SRCDIR([htop.c])
AC_CONFIG_AUX_DIR([build-aux])
@@ -253,6 +253,7 @@ AC_SEARCH_LIBS([clock_gettime], [rt])
AC_CHECK_FUNCS([ \
clock_gettime \
+ dladdr \
faccessat \
fstatat \
host_get_clock_service \
@@ -261,9 +262,6 @@ AC_CHECK_FUNCS([ \
readlinkat \
])
-# Add -lexecinfo if needed
-AC_SEARCH_LIBS([backtrace], [execinfo])
-
if test "$my_htop_platform" = darwin; then
AC_CHECK_FUNCS([mach_timebase_info])
fi
@@ -409,6 +407,36 @@ if test "x$enable_affinity" = xyes; then
fi
+AC_ARG_ENABLE([unwind],
+ [AS_HELP_STRING([--enable-unwind],
+ [enable unwind support for printing backtraces; requires libunwind @<:@default=check@:>@])],
+ [],
+ [enable_unwind=check])
+case "$enable_unwind" in
+ check)
+ enable_unwind=yes
+ if test "$enable_static" = yes; then
+ AC_CHECK_LIB([lzma], [lzma_index_buffer_decode])
+ fi
+ AC_CHECK_LIB([unwind], [backtrace], [], [enable_unwind=no])
+ AC_CHECK_HEADERS([libunwind.h], [], [enable_unwind=no])
+ ;;
+ no)
+ ;;
+ yes)
+ AC_CHECK_LIB([unwind], [backtrace], [], [AC_MSG_ERROR([can not find required library libunwind])])
+ AC_CHECK_HEADERS([libunwind.h], [], [AC_MSG_ERROR([can not find require header file libunwind.h])])
+ ;;
+ *)
+ AC_MSG_ERROR([bad value '$enable_unwind' for --enable-unwind])
+ ;;
+esac
+if test "x$enable_unwind" = xno; then
+ # Fall back to backtrace(3) and add -lexecinfo if needed
+ AC_SEARCH_LIBS([backtrace], [execinfo])
+fi
+
+
AC_ARG_ENABLE([hwloc],
[AS_HELP_STRING([--enable-hwloc],
[enable hwloc support for CPU affinity; disables affinity support; requires libhwloc @<:@default=no@:>@])],
@@ -426,6 +454,7 @@ case "$enable_hwloc" in
;;
esac
+
AC_ARG_WITH([os-release],
[AS_HELP_STRING([--with-os-release=FILE],
[location of an os-release file @<:@default=/etc/os-release@:>@])],
@@ -639,7 +668,9 @@ AS_VAR_IF(CACHEVAR,yes,
AS_VAR_POPDEF([CACHEVAR])dnl
])dnl AX_CHECK_COMPILE_FLAGS
-AX_CHECK_COMPILE_FLAG([-Wnull-dereference], [AM_CFLAGS="$AM_CFLAGS -Wnull-dereference"], , [-Werror])
+AX_CHECK_COMPILE_FLAG([-Wextra-semi-stmt], [AM_CFLAGS="$AM_CFLAGS -Wextra-semi-stmt"], , [-Werror=unknown-warning-option]) dnl the autoconf check itself generates -Wextra-semi-stmt
+AX_CHECK_COMPILE_FLAG([-Wimplicit-int-conversion], [AM_CFLAGS="$AM_CFLAGS -Wimplicit-int-conversion"], , [-Werror])
+AX_CHECK_COMPILE_FLAG([-Wnull-dereference], [AM_CFLAGS="$AM_CFLAGS -Wnull-dereference"], , [-Werror])
AC_ARG_ENABLE([werror],
[AS_HELP_STRING([--enable-werror],
@@ -715,6 +746,7 @@ AC_MSG_RESULT([
(Linux) capabilities: $enable_capabilities
unicode: $enable_unicode
affinity: $enable_affinity
+ unwind: $enable_unwind
hwloc: $enable_hwloc
debug: $enable_debug
static: $enable_static

© 2014-2024 Faster IT GmbH | imprint | privacy policy