Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp765235pxb; Thu, 19 Nov 2020 13:16:00 -0800 (PST) X-Google-Smtp-Source: ABdhPJwbJjIKYIwzRhqeiBjaliVNApiVnaCArdKId+VtlyPrZqR+ACt3+Q4r4DLmStPv46NnHBHD X-Received: by 2002:a05:6402:14c6:: with SMTP id f6mr36280909edx.359.1605820560583; Thu, 19 Nov 2020 13:16:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605820560; cv=none; d=google.com; s=arc-20160816; b=G1qXxc15CoLc3rKIHoN+sHeyTvkdPMkS6KD2HjhcQ+3UqSimqcxF5XTkq0LfLlyRPe Y9PqSuTQLnF4/JP4Luyl0KzWBRptPh0xSSJvxS1q5eRnMOIFuOkLPO22HrdP0zu2n2nj fsEcdS56/Ssacs0CnELWldILw1NCHhjfMJN/MGm+onlWZW/iCmoxvX+UmBLkySe+0t1A 7Rh00SCUEHCLDetSmHEh09sr3e8Gu+i2fiyc3PGOLBBD96B0Ih1IA5g0/rmJbei+/V3C ZI1wjNQYAV7oH2OQIV84IJP4WCpxqEkF0MIltN3avTMx39qoLXcEzHrc4cKXYI0FpRV1 v4EQ== 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; bh=tZGj0oIna+UduCQLR0+PjVPjVl9hL9hj6VDeUHmIQpA=; b=0zygvtR4GOvf+iButaFRC24XnQ+DWj4M1iiyKxLm9E/vlLIe8iwiEYRgWKNyYjRqAw wzREJkKncj83lqnb8diJGrb4lYw7/9bpWN5AzyZlbwB2Xt8pEAHfIzMTPA2VQElIH5ut 0HA8szpNvOXkRt2f+50rtQdDmf8+umQiAKLgkeyZoeG/yfjXhu5qyqUlUGum6TL2QCVF XuGerVGiekvggkEpaIMwWwGyJz0uuftrbEnp9Kq8AzhvWqkIBxC2H6jricaFwWDeTiiu 2++22OTwYPFVbCIQRulDWynjFjOajiF4LbNKKy1MPCXHmknZnd1n//CmOBHO6bImn8mt IrUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=mswBFci1; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n2si691373edi.362.2020.11.19.13.15.38; Thu, 19 Nov 2020 13:16:00 -0800 (PST) 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=@google.com header.s=20161025 header.b=mswBFci1; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726868AbgKSVOO (ORCPT + 99 others); Thu, 19 Nov 2020 16:14:14 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41852 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726810AbgKSVOO (ORCPT ); Thu, 19 Nov 2020 16:14:14 -0500 Received: from mail-pl1-x641.google.com (mail-pl1-x641.google.com [IPv6:2607:f8b0:4864:20::641]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 01E89C0617A7 for ; Thu, 19 Nov 2020 13:14:14 -0800 (PST) Received: by mail-pl1-x641.google.com with SMTP id k7so3670976plk.3 for ; Thu, 19 Nov 2020 13:14:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=tZGj0oIna+UduCQLR0+PjVPjVl9hL9hj6VDeUHmIQpA=; b=mswBFci17dGbCtf84CRFOcgst+BzEvYcSvutJupIJsxPzrnAaZM58FBbcME4BQOd3I WX4GKvP31SkrTbEIk+/yGrSQLDEdsRJnR9Kdauz2KbGlpOT4MRbqxZsGeRFblBKz83vU IkuFiuB97Xx4I6/2zcoZU1431r2zCJeJsfXcsZZhi0T8RyYO4ydPGiECVbpNlk8i2OQx yCdMfrMhX0GWQSfEO7IEK8vN5UivuFmllua/U5sUbGXMMya+3naXZ5kCxelw1ZnNqtGC O+GagxXO6Uur8HF5Y6oi+1cp00ppga2qZaOizSy8dYbqs/Cax63LxvD6kyZv/ACf51R2 grLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=tZGj0oIna+UduCQLR0+PjVPjVl9hL9hj6VDeUHmIQpA=; b=ixNthrm0WmmTOxcXAdQjG56oEe1/ISQx0ud1HOdh/teAHjyG9CDfl4pualbG9Jqtv+ VZ2kkEmd174rL3pwFj1q5bOvrbAIEtAZU2nmPY6c8VGiJEuQiQ4sAmVV8s7PIBkC7JgQ 2E59RUwQ3z4a/y+P8DOkkpYN75z6IEVCc/9h6//Pykxu+8D3ZYYMZ7bOrUNd1k/D3a6w ZhWloWnQdK/fmSpBDsXy0MzJ5Lpf+Oy1QH5OwMtQC6uFVwPFuMurxXUBiJYYlvX7/sfv s0hR9YoCY3XJrKmo7pjlUF72utoao1NojAgZYkVD8U09l+UYpTldIaB2gII0qdMm0vjx Ni4g== X-Gm-Message-State: AOAM530+RbEe5gmmQ7IIZw9FLqQNacUOfOH79ipPG9s++ZOETPZswktY QxKNJcRueh52uFmxvTB8UAeudqbwHsHU6/rVCJG0Pw== X-Received: by 2002:a17:902:b28a:b029:d5:f36b:44af with SMTP id u10-20020a170902b28ab02900d5f36b44afmr9918635plr.51.1605820453161; Thu, 19 Nov 2020 13:14:13 -0800 (PST) MIME-Version: 1.0 References: <20201119085022.3606135-1-davidgow@google.com> In-Reply-To: <20201119085022.3606135-1-davidgow@google.com> From: Brendan Higgins Date: Thu, 19 Nov 2020 13:14:02 -0800 Message-ID: Subject: Re: [RFC PATCH] bpf: preload: Fix build error when O= is set To: David Gow Cc: Alexei Starovoitov , Daniel Borkmann , =?UTF-8?B?VG9rZSBIw7hpbGFuZC1Kw7hyZ2Vuc2Vu?= , netdev@vger.kernel.org, bpf@vger.kernel.org, Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Nov 19, 2020 at 12:50 AM David Gow wrote: > > If BPF_PRELOAD is enabled, and an out-of-tree build is requested with > make O=, compilation seems to fail with: > > tools/scripts/Makefile.include:4: *** O=.kunit does not exist. Stop. > make[4]: *** [../kernel/bpf/preload/Makefile:8: kernel/bpf/preload/libbpf.a] Error 2 > make[3]: *** [../scripts/Makefile.build:500: kernel/bpf/preload] Error 2 > make[2]: *** [../scripts/Makefile.build:500: kernel/bpf] Error 2 > make[2]: *** Waiting for unfinished jobs.... > make[1]: *** [.../Makefile:1799: kernel] Error 2 > make[1]: *** Waiting for unfinished jobs.... > make: *** [Makefile:185: __sub-make] Error 2 > > By the looks of things, this is because the (relative path) O= passed on > the command line is being passed to the libbpf Makefile, which then > can't find the directory. Given OUTPUT= is being passed anyway, we can > work around this by explicitly setting an empty O=, which will be > ignored in favour of OUTPUT= in tools/scripts/Makefile.include. > > Signed-off-by: David Gow Seems sensible to me. I have no strong feeling as to whether we just turn this off on UML or whether we do the fix you proposed here though. Nevertheless, I would like to see *some* fix go in before v5.10 is released. Reviewed-by: Brendan Higgins