Message ID | 875xvf70va.fsf@redhat.com |
---|---|
State | New |
Headers |
Return-Path: <libabigail-bounces+patchwork=sourceware.org@sourceware.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id BE5E8384AB45 for <patchwork@sourceware.org>; Wed, 15 May 2024 11:47:47 +0000 (GMT) X-Original-To: libabigail@sourceware.org Delivered-To: libabigail@sourceware.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 24E773858D20 for <libabigail@sourceware.org>; Wed, 15 May 2024 11:47:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 24E773858D20 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 24E773858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1715773663; cv=none; b=Sde+5BfR/frUUIDYuGkEKMCuVkKvkzgnYYn5ETiDibbpeFkfDSxisXbKEgmLG7OOsB9Xg6SISl0HtsvmfNBvz1iZbLZfG9KCRSYNqDvwKZyJLlDZUsmrKTRWagkrYiPRfyZCBP8z9+1AfwstU8NxeQ0hc++mtaguLAK2D9JLJwk= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1715773663; c=relaxed/simple; bh=ix8JsoKXl60ajWd8ULymCf9bdBWViC4zaySVUfMrSUE=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=PgMflN0GC0Xd9wsJqUQTNRRUuKih8weOUM6BwRINiVNjDMutIaFBF0UfoRBom9v6JWOwJYqOJ1Uv5EsluLmbBmLOEfSm0zRLLB5snhHSf5hENSRKkIOOQt3iNYOKfeKYqdYvr5BktztQWcbZIOukmRwoTyJBZzCjhO+cOUNwOLU= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1715773661; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type; bh=QPTf7d3SszR3467BAfjCVoZzhSrSl+qXdPfmIaBWhF0=; b=Ns39jbHA+csrDCA9JJ3KXm7872vqQjxFVcOU+4D8yJw9w/YNOfuEv18NlVTb6H+nkrVta+ hZgArOZRPXEEtHdcOkCjU2BJZNL9e6FjiYq8R88QE3RwjEqDWZkItv2sRfpCWnsRByQeTR +n6iqSg9Ranz4j8crink+wJfvGGXUOs= Received: from mail-qv1-f69.google.com (mail-qv1-f69.google.com [209.85.219.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-92-MYqCLfSZO0SIPvy-rq7CyQ-1; Wed, 15 May 2024 07:47:40 -0400 X-MC-Unique: MYqCLfSZO0SIPvy-rq7CyQ-1 Received: by mail-qv1-f69.google.com with SMTP id 6a1803df08f44-6a0dd95cbc6so63937136d6.1 for <libabigail@sourceware.org>; Wed, 15 May 2024 04:47:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715773660; x=1716378460; h=mime-version:user-agent:message-id:date:organization:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=QPTf7d3SszR3467BAfjCVoZzhSrSl+qXdPfmIaBWhF0=; b=PZbYh15Mrq4VU/9Bazot0Ufx0fG6nj924ul5Qxv0CICH9Pj7Fvx2lxdj0DS7EjkR5n AQTv5iJduCMr+WN2wlD8CwDqZpzWVxgCP7Km9a9ZWCHsrQ6u1nSusvBLyafuYr/Zcigo farLnY+R0UwHuWnPFp2gCQNWakrDzEG17FA97tdih5i70YVeJZXpFEEbV9dD2R9ZwTle HQbfHWgFI99QBENGFsYLGyVfXGykYY1Iiwo3rYXZKTIQTCa1IrVUB8xV3QtM9udHtodK jsSRKQbOL5Fu+KpPBVg2k+02zuR06cFYO3iGDeiSCVadnsrCsAiCiC4AKsyZ6vfcEmji e4VQ== X-Gm-Message-State: AOJu0Yyws/NrQkwSjuSmd21vd69f1PwPBSdO5jjf5JKUSknxmrvzQOjj /iEAXNiZH75gAHHm/aPQEJURwppiAKZWGEndy66CHiJ5b45xIJD70VG0nCo6AnIhdw3sVZpESJO yyvp9p4qXDcG/8aG6JH0inYRbgzJfIWKD5tRrH0F3561LPUHkWXiUfVObB1XdZko/rg== X-Received: by 2002:a05:6214:319e:b0:6a3:5bb8:12dd with SMTP id 6a1803df08f44-6a35bb83836mr4971806d6.56.1715773659918; Wed, 15 May 2024 04:47:39 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGOcDO6rJ2/11FDlIbGMUEtz6CgzzNivbwZ2EhYxK9EzVhUJG3COUHF+wHeTKr8mpSWbWA19A== X-Received: by 2002:a05:6214:319e:b0:6a3:5bb8:12dd with SMTP id 6a1803df08f44-6a35bb83836mr4971656d6.56.1715773659559; Wed, 15 May 2024 04:47:39 -0700 (PDT) Received: from localhost (88-120-130-27.subs.proxad.net. [88.120.130.27]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6a15f194d2esm62618436d6.68.2024.05.15.04.47.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 May 2024 04:47:39 -0700 (PDT) Received: by localhost (Postfix, from userid 1000) id 3BB07C1B73C1; Wed, 15 May 2024 13:47:37 +0200 (CEST) From: Dodji Seketeli <dodji@redhat.com> To: ckalina@redhat.com Cc: libabigail@sourceware.org Subject: [PATCH, RFC] configure: Fix detection of BTF header to enable the BTF front-end Organization: Red Hat / France X-Operating-System: AlmaLinux 9.3 X-URL: http://www.redhat.com Date: Wed, 15 May 2024 13:47:37 +0200 Message-ID: <875xvf70va.fsf@redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-12.4 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libabigail@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Mailing list of the Libabigail project <libabigail.sourceware.org> List-Unsubscribe: <https://sourceware.org/mailman/options/libabigail>, <mailto:libabigail-request@sourceware.org?subject=unsubscribe> List-Archive: <https://sourceware.org/pipermail/libabigail/> List-Post: <mailto:libabigail@sourceware.org> List-Help: <mailto:libabigail-request@sourceware.org?subject=help> List-Subscribe: <https://sourceware.org/mailman/listinfo/libabigail>, <mailto:libabigail-request@sourceware.org?subject=subscribe> Errors-To: libabigail-bounces+patchwork=sourceware.org@sourceware.org |
Series |
[RFC] configure: Fix detection of BTF header to enable the BTF front-end
|
|
Commit Message
Dodji Seketeli
May 15, 2024, 11:47 a.m. UTC
Hello,
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.
OK to apply to the mainline if it passes the CI tests?
Thanks.
Signed-off-by: Dodji Seketeli <dodji@redhat.com>
---
configure.ac | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
Comments
On Wed, May 15, 2024 at 01:47:37PM GMT, Dodji Seketeli wrote: > Hello, > > 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. > > OK to apply to the mainline if it passes the CI tests? > Thanks. Tested-by: Cestmir Kalina <ckalina@redhat.com> > > Signed-off-by: Dodji Seketeli <dodji@redhat.com> > --- > configure.ac | 6 +++--- > 1 file 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]) > -- > 2.39.3 > > > -- > Dodji >
Čestmír Kalina <ckalina@redhat.com> writes: > On Wed, May 15, 2024 at 01:47:37PM GMT, Dodji Seketeli wrote: >> Hello, >> >> 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. >> >> OK to apply to the mainline if it passes the CI tests? >> Thanks. > > Tested-by: Cestmir Kalina <ckalina@redhat.com> Thanks! Incidentally, the CI build did pass. So I have applied the patch to the mainline. Many thanks for taking the time to report the issue and for testing the patch. [...] Cheers,
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])