Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2270151pxj; Sun, 16 May 2021 20:45:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxtdoh67INyZA1yJB0B6zddBEsfZhram26kFr5cmy2RQy8x7TxbDcxW9Zm8KcU4Nxr6qpY7 X-Received: by 2002:a17:906:22c6:: with SMTP id q6mr59502856eja.275.1621223101995; Sun, 16 May 2021 20:45:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621223101; cv=none; d=google.com; s=arc-20160816; b=UB1xiLJy5qDcxb30ynt2Y2XLWLL4xbJUE9ZVNLTILApG0SsPu69WCI7k0FJOAq2vGP doqOmsln8fAjbBFyS3ZJ8OEG7B0hNaTLhTkqBn87zgnHODs3lnnganQpS3srmRpadjH4 tfxfPY12WcBVoOqEhNt0u5kGtVP/lZHdJ+OObi0f10xaJj2UvTth/GCK/YGEPnYgmg2V lQHwLNe8cobh7J6BLkMKwfw1RCwwYerxSYRFs/Tg+IZ3hwe8SR6w/LMtolZh98HxMHjf lKSV+8ZVg6tHz1prnFjwzgS7169fHTyWiOxF3TGAZE30GKCP/zmq2kKsKt69MA0oalpE GVLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature:dkim-filter; bh=GgOSs8zrb6fLGJr3oX36VWe647ayOr3nv+9MJ33ntoU=; b=lwVjfPVLANaX844NPvDjyvFN5Bv/ykTO9+xPTyD1es95VcEyvu4rIptIrFBWxw8/DV QUhDEWmzVAWqR0uu8mKgMyv9ogts5T3orzdDKnvKbTAANeIBIEE5vVKb52ws386nieuC XIEOLAqAHMecmg/LXKi8jIpeHvwkgm5n5ELKRE/QbNdJHZMgUCwBuhGuk2Kbep/1sz/O ROPD5d6kd6BBw5KLgv6q/LrMX5khPdBd4VuQN5Z7X0wzjx0OPCxyv5TdgYBuGrZDKQ19 EkVw0DjW+arOGmvYv5Vd7zocsqQTgXeUuxsrwycTw2nC48IUNRhFQdn6t2Qv5ghbj/z1 M0pA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=o2QF8k95; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k25si7122819ejg.471.2021.05.16.20.44.38; Sun, 16 May 2021 20:45:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=o2QF8k95; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233955AbhEQCwm (ORCPT + 99 others); Sun, 16 May 2021 22:52:42 -0400 Received: from conssluserg-05.nifty.com ([210.131.2.90]:19062 "EHLO conssluserg-05.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233907AbhEQCwk (ORCPT ); Sun, 16 May 2021 22:52:40 -0400 Received: from mail-pf1-f182.google.com (mail-pf1-f182.google.com [209.85.210.182]) (authenticated) by conssluserg-05.nifty.com with ESMTP id 14H2oqi6003301; Mon, 17 May 2021 11:50:52 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-05.nifty.com 14H2oqi6003301 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1621219852; bh=GgOSs8zrb6fLGJr3oX36VWe647ayOr3nv+9MJ33ntoU=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=o2QF8k95BMd8yhaXpsSiR12h1WwoGQhuf6AogBWQhx0hd6uZim4vlBPqoOtsyyeQQ cvU0I/NGzjEBHN6ahVL2tBSNez3Xr8xH1cByT+nQiwp6D+c1Mpzma1cjbVCZr1y7Gu R8P1XgddxgdgdtWSQr8lt7ZNlxhUU4llODBzipDIkRQfGLvbhbxTEqZ41FzvrTbiou tjJc4+JWh6kT6xsIxCIlpwHROtMNycDo9qyNZmTc+ocbbDrKhOsxW9ClbBljB9bgAq EOEHueRbdgTkZhDFS4gjiCRwoGMR7btphCV3/DhLSS4IRaF5gAbXGyqcbfmWlWazIU zbq0R1XRmUplg== X-Nifty-SrcIP: [209.85.210.182] Received: by mail-pf1-f182.google.com with SMTP id w1so1304944pfu.0; Sun, 16 May 2021 19:50:52 -0700 (PDT) X-Gm-Message-State: AOAM530HiufWOQlo4/mOUIBiR9hP5Ukp/gRQPa40892Ft6NdoKl0+r1e TeCLp/SbAlHhzHjKyYDWd2KW8i+HFMzc54G+Tow= X-Received: by 2002:aa7:94af:0:b029:28e:80ff:cc1d with SMTP id a15-20020aa794af0000b029028e80ffcc1dmr57693078pfl.63.1621219851803; Sun, 16 May 2021 19:50:51 -0700 (PDT) MIME-Version: 1.0 References: <20210512065201.35268-1-masahiroy@kernel.org> <20210512065201.35268-2-masahiroy@kernel.org> In-Reply-To: From: Masahiro Yamada Date: Mon, 17 May 2021 11:50:14 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 2/2] kbuild: remove libelf checks from top Makefile To: Andrii Nakryiko Cc: Linux Kbuild mailing list , Alexei Starovoitov , Andrii Nakryiko , Daniel Borkmann , John Fastabend , KP Singh , Martin KaFai Lau , Michal Marek , Song Liu , Yonghong Song , bpf , open list , Networking , Josh Poimboeuf , "Peter Zijlstra (Intel)" Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org (+CC: Josh, Peter) On Thu, May 13, 2021 at 4:36 AM Andrii Nakryiko wrote: > > On Tue, May 11, 2021 at 11:52 PM Masahiro Yamada wrote: > > > > I do not see a good reason why only the libelf development package must > > be so carefully checked. > > > > Kbuild generally does not check host tools or libraries. > > > > For example, x86_64 defconfig fails to build with no libssl development > > package installed. > > > > scripts/extract-cert.c:21:10: fatal error: openssl/bio.h: No such file or directory > > 21 | #include > > | ^~~~~~~~~~~~~~~ > > > > To solve the build error, you need to install libssl-dev or openssl-devel > > package, depending on your distribution. > > > > 'apt-file search', 'dnf provides', etc. is your frined to find a proper > > package to install. > > > > This commit removes all the libelf checks from the top Makefile. > > > > If libelf is missing, objtool will fail to build in a similar pattern: > > > > .../linux/tools/objtool/include/objtool/elf.h:10:10: fatal error: gelf.h: No such file or directory > > 10 | #include > > > > You need to install libelf-dev, libelf-devel, or elfutils-libelf-devel > > to proceed. > > > > Another remarkable change is, CONFIG_STACK_VALIDATION (without > > CONFIG_UNWINDER_ORC) previously continued to build with a warning, > > but now it will treat missing libelf as an error. > > > > This is just a one-time installation, so it should not matter to break > > a build and make a user install the package. > > > > BTW, the traditional way to handle such checks is autotool, but according > > to [1], I do not expect the kernel build would have similar scripting > > like './configure' does. > > > > [1]: https://lore.kernel.org/lkml/CA+55aFzr2HTZVOuzpHYDwmtRJLsVzE-yqg2DHpHi_9ePsYp5ug@mail.gmail.com/ > > > > Signed-off-by: Masahiro Yamada > > --- > > > > resolve_btfids part looks good to me: > > Acked-by: Andrii Nakryiko > > > Makefile | 78 +++++++++++---------------------------- > > scripts/Makefile.build | 2 - > > scripts/Makefile.modfinal | 2 - > > 3 files changed, 22 insertions(+), 60 deletions(-) > > > > [...] -- Best Regards Masahiro Yamada