diff options
author | Dodji Seketeli <dodji@redhat.com> | 2024-05-15 13:33:20 +0200 |
---|---|---|
committer | Dodji Seketeli <dodji@redhat.com> | 2024-05-15 15:21:01 +0200 |
commit | b1e8e15becdb70237bd698344a0edbcb90d89583 (patch) | |
tree | a5c24c3b8a41521a6133c3f22fb52ed9830a8470 | |
parent | ca2319b97336a5230c0fd71184f8135b15544ef1 (diff) | |
download | libabigail-upstream-master.tar.gz |
configure: Fix detection of BTF header to enable the BTF front-endupstream-master
Cestmir Kalina reported that running configure with --enable-btf with
no BTF header present on the system wrongly leads to the BTF
front-end of libabigail being enabled, and later leads to
compilation/installation errors.
This patch fixes that by ensuring that the ENABLE_BTF variable set by
the --enable-btf option handling code is not reused later during
actual btf.h header file detection code.
* configure.ac: Use a new HAS_BTF_HEADERS to store the detection
status for the btf.h header. Emit a better notice message when
the BTF header file is found.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
Tested-by: Cestmir Kalina <ckalina@redhat.com>
-rw-r--r-- | configure.ac | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index c6e1ad64..e118a9c0 100644 --- a/configure.ac +++ b/configure.ac @@ -391,10 +391,10 @@ dnl configure BTF usage BPF_LIBS= if test x$ENABLE_BTF != xno; then AC_CHECK_HEADER([bpf/btf.h], - [ENABLE_BTF=yes], + [HAS_BTF_HEADERS=yes], [AC_MSG_NOTICE([could not find bpf/btf.h])]) - if test x$ENABLE_BTF = xyes; then - AC_MSG_NOTICE([enable BTF support]) + if test x$HAS_BTF_HEADERS = xyes; then + AC_MSG_NOTICE([found BTF header file so enabling BTF support]) ENABLE_BTF=yes AC_DEFINE([WITH_BTF], 1, [Defined if user enabled BTF usage]) |