Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp912723pxm; Sat, 26 Feb 2022 00:53:57 -0800 (PST) X-Google-Smtp-Source: ABdhPJy9J98mi9bhY1zCgEF+G/rSREoWKXMtgc7kWYVHOh2FHNNBtmI91LNr8ME0+ZmvisX7euyB X-Received: by 2002:a50:a6c2:0:b0:410:a328:3c86 with SMTP id f2-20020a50a6c2000000b00410a3283c86mr10445749edc.55.1645865637518; Sat, 26 Feb 2022 00:53:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645865637; cv=none; d=google.com; s=arc-20160816; b=RDLc+3f5m0I3ZScbSGYvlKCBVw+WRx9jw8xE7hBCUtHYbx7yZmDizzQOnQx8pKrHfL OST9KbxsvQdU8ZfyqU9egQGUUBAGzZCOz4d4nCsBp5351tt9qy9t179TotiuDkpw66lp PL4QIcNNZSychcyN0ba63hOCnMz4NB7jbws6WRLJjEjuWaB10EM0uP+IIG/lx3Bu0dDk k3NPiJzk0Xt9xK8rQ3J0XNBQm40+NrVrcsTUIuEVQtl+bXnG7QA7GxHJ+9VJBhGJLHin G7ZxK7Yyu6cxOemYjoFL7HrVKK5w80TxPwfLSLX6VRCotlOZXrAujGp0CM+rnybySZgh KS/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:to:content-language:subject:cc:user-agent:mime-version :date:message-id:dkim-signature; bh=Xz7H/as8z85O22VktEdmDMRSY0+/MRPpiWClqPNpHUo=; b=DSqaWPMHmIjqx1VjpJ/PZZFnlJ+UIcNDTbWBQeKGMByTNU5cffWVYjZoLYo9mw2Ed5 D54UXmTp8MHaZ3BRPaCm5tdMmBNjHRetgdOJL4zg/DsTS/PXnzgvjtSHZiwY+451vHc5 zr0DHLmhKCtru0ernUu4/ZPLKQURwj8xByT7jMJwlsuOQK/njTDn5zI1LK/DY+ComqWx 50o1VPFjV0KIRyuD92ztj+Cqem/MLk8qY/PFKrMQD8Y5KkNgFiYZDzhFiiL/EanojiI8 EEzWSAKGxOlO1G30rrryuuOX4h9dKiSXIGt7cEFJPp5dbdg5+hKwJlC5uWAxbZ/b6p/t UpLA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=Xn9QwQfM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e17-20020a170906505100b006cf834b30e3si2997444ejk.598.2022.02.26.00.53.35; Sat, 26 Feb 2022 00:53:57 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=Xn9QwQfM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230154AbiBZHdQ (ORCPT + 99 others); Sat, 26 Feb 2022 02:33:16 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48974 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229924AbiBZHdQ (ORCPT ); Sat, 26 Feb 2022 02:33:16 -0500 Received: from bhuna.collabora.co.uk (bhuna.collabora.co.uk [46.235.227.227]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4B5D5E29; Fri, 25 Feb 2022 23:32:33 -0800 (PST) Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: usama.anjum) with ESMTPSA id 9BF0D1F467EE DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1645860752; bh=pkiELR9DhTQvRNgxhSnFGTRWf9t9Px/bkmVM9uFDx0s=; h=Date:Cc:Subject:To:References:From:In-Reply-To:From; b=Xn9QwQfM2sX+J9TBkV0MJldNdwZS66ytIF0Nhk7uimN7o/Bvde6mkwbgKDD5vRAO5 jxFz4Iok+PElmZTYbj/S98NUJ1JKBV6xbUPDpqyFRFCp7c2E7o6qsZ4uPpuNLQjcFk xAPgftBpgOa/kFXKLHdZzRJ5T31xPBIvH1DfwkEPjmVZUnkGYJ+dPaT3aOVqBc58rQ tLLDWhma7wbGPF238K3kwrVKI9Rvm7cDu9KWhKMNEMSZ4wEEJQ+GB+OV2p+Bq+6uG9 mnK0P8mk2WvJsKgRNRqt8a38Aqox1Q0wYhRWlLSN1BDSeyHdtAnuFxh46Nuc4R7l3v 5w2XnRAG5F3rw== Message-ID: Date: Sat, 26 Feb 2022 12:32:23 +0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.6.0 Cc: usama.anjum@collabora.com, kernel@collabora.com, kernelci@groups.io, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, bpf@vger.kernel.org Subject: Re: [PATCH V2] selftests: Fix build when $(O) points to a relative path Content-Language: en-US To: Shuah Khan , Shuah Khan , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Song Liu , Yonghong Song , John Fastabend , KP Singh References: <20220216223817.1386745-1-usama.anjum@collabora.com> <46489cd9-fb7a-5a4b-7f36-1c9f6566bd93@collabora.com> <63870982-62ba-97f2-5ee2-d4457a7a5cdb@linuxfoundation.org> <9a643612-ea85-7b28-a792-770927836d43@linuxfoundation.org> From: Muhammad Usama Anjum In-Reply-To: <9a643612-ea85-7b28-a792-770927836d43@linuxfoundation.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2/26/22 2:13 AM, Shuah Khan wrote: > On 2/25/22 11:01 AM, Shuah Khan wrote: >> On 2/25/22 10:22 AM, Muhammad Usama Anjum wrote: >>> Any thoughts about it? >>> >> >> No to post please. >> >>> On 2/17/22 3:38 AM, Muhammad Usama Anjum wrote: >>>> Build of bpf and tc-testing selftests fails when the relative path of >>>> the build directory is specified. >>>> >>>> make -C tools/testing/selftests O=build0 >>>> make[1]: Entering directory >>>> '/linux_mainline/tools/testing/selftests/bpf' >>>> ../../../scripts/Makefile.include:4: *** O=build0 does not exist.  >>>> Stop. >>>> make[1]: Entering directory >>>> '/linux_mainline/tools/testing/selftests/tc-testing' >>>> ../../../scripts/Makefile.include:4: *** O=build0 does not exist.  >>>> Stop. >>>> >>>> Makefiles of bpf and tc-testing include scripts/Makefile.include file. >>>> This file has sanity checking inside it which checks the output path. >>>> The output path is not relative to the bpf or tc-testing. The sanity >>>> check fails. Expand the output path to get rid of this error. The >>>> fix is >>>> the same as mentioned in commit 150a27328b68 ("bpf, preload: Fix build >>>> when $(O) points to a relative path"). >>>> >>>> Signed-off-by: Muhammad Usama Anjum >>>> --- >>>> Changes in V2: >>>> Add more explaination to the commit message. >>>> Support make install as well. >> > > Does the same happen when you use make kselftest-all? No, this problem doesn't appear when using make kselftest-all. As separate output directory build was broken in kernel's top most Makefile i.e., make kselftest-all O=dir. (I've sent separate patch to fix this: https://lore.kernel.org/lkml/20220223191016.1658728-1-usama.anjum@collabora.com/) So people must have been using kselftest's internal Makefile directly to keep object files in separate directory i.e., make -C tools/testing/selftests O=dir and in this way the build of these tests (bpf, tc-testing) fail. This patch is fixing those build errors. > > I am unable to reproduce what you are seeing? make -C tools/testing/selftests O=dir should reproduce this problem. > > thanks, > -- Shuah >