Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3842553ybb; Mon, 23 Mar 2020 08:41:03 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsjgjT1unANbFMOmMGxtJTVwwuEjDJGaA5nSXLalGMQ+hhl6uj4GaPBXqERAHpzE1dn4JrZ X-Received: by 2002:a9d:837:: with SMTP id 52mr17688316oty.354.1584978063305; Mon, 23 Mar 2020 08:41:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584978063; cv=none; d=google.com; s=arc-20160816; b=WGtwrLogc3NnE0/s2cjorGsi54FtjMGVh86875ZcP4wFfz+lM1tyI9mHWNuripSB6H WePu8+Acm9vnqNALSyuZbvVKDuFGGtLNKYbkhf4UeUU93b+/aEaRE4eAe0vXoNQCh1YJ ffHAnEFRJ7/OvAVmAY1P+GLLF5W92XJNV3ji0vwLqC6Q67VFlYJ3cxbCNKT36BSV0vJd aqsvYkT8CpSkkZ/KH5ZMZNFf7sjfQtRheKdPwBvYOmhcpsoudm9JHQw3KiLPjpuVtrbl gpxrMSRbx0jAt7yWcysaHa2gICWdGqP1LDYgK0aOg1ITvU9EAO4qNxExHtwPev4Eb3bq HzjQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:cc:from:references:to:subject:dkim-signature; bh=/VQhSGzeCQS0yeDt+CdYjwLKRilwhat61408+BIx6kg=; b=g/B4vpuL6yVVVrV0AwW9LSb4HU8deKfAr2AjTjA0nvw2keL+HcNvRXuhAjzsITn8tK pQYiMREPsSs5IVaBCLqYqfgG5ioxRufQWbJKOId+isy1w1kIIUfh3oAvXKRemnT1lRjS 7EE7xraVB9acvEHJ8ancblQ9HS3iuAsgiKAem/302M4eHZYcr/CW6KITr4EPVs/HELXP C8cqA9QZtCuNbe7LzbpzCcqkyeJ21HCDp9vNpA7kY8Eq/l+P+s/qSg4wRDaokshjBPYk mOpo+KWL8kZFNjEHhEYgWeIoeQXelYzCl+Igcv3mKrKX0lJf/OrXdgyVpUJHBiDbQSAF aYTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=KNgh82ob; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id j22si7291270otk.107.2020.03.23.08.40.49; Mon, 23 Mar 2020 08:41:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=KNgh82ob; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1727379AbgCWPk2 (ORCPT + 99 others); Mon, 23 Mar 2020 11:40:28 -0400 Received: from mail.kernel.org ([198.145.29.99]:40874 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726049AbgCWPk1 (ORCPT ); Mon, 23 Mar 2020 11:40:27 -0400 Received: from [192.168.1.112] (c-24-9-64-241.hsd1.co.comcast.net [24.9.64.241]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id BBB5420409; Mon, 23 Mar 2020 15:40:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1584978027; bh=aEPoTGtrihRR9CH44YGoaszH2LRi7APPappXtHmIFNk=; h=Subject:To:References:From:Cc:Date:In-Reply-To:From; b=KNgh82obI3osbkUxHnuobfS9X7n1lCRLSiAiWlyeFI9Yc+/taXeC72yNyrqn0o0Sb IJHCafFadCeJiyrWniexKrnkgZYeWzY/KeLph4cThEXqPbV32P1qPXx4D3VNK6oV5g BbikkzEiPRzSs3VmfhhDHFOzAezxobj46Ii2/Ce8= Subject: Re: [PATCH 1/2] kvm: selftests: Fix no directory error when OUTPUT specified To: Xiaoyao Li , Paolo Bonzini , linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org References: <20200315093425.33600-1-xiaoyao.li@intel.com> <20200315093425.33600-2-xiaoyao.li@intel.com> From: shuah Cc: shuah Message-ID: <99584925-69e7-7dab-7dd9-ee920ac343a0@kernel.org> Date: Mon, 23 Mar 2020 09:40:26 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: <20200315093425.33600-2-xiaoyao.li@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 3/15/20 3:34 AM, Xiaoyao Li wrote: > When build kvm selftests to an specified directory with > > make OUTPUT=~/kvm-selftests > > it encouters following error: btw lib.mk can't handle relative paths yet. The problems you are seeing are related to that as well. This relative path issue should be fixed in lib.mk and not in individual tests. > > /usr/bin/ld: cannot open output file > /home/lxy/kvm-selftests/x86_64/cr4_cpuid_sync_test: No such file or > directory > collect2: error: ld returned 1 exit status > make: *** [../lib.mk:141: > /home/lxy/kvm-selftests/x86_64/cr4_cpuid_sync_test] Error 1 > > Signed-off-by: Xiaoyao Li > --- > tools/testing/selftests/kvm/Makefile | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/tools/testing/selftests/kvm/Makefile b/tools/testing/selftests/kvm/Makefile > index d91c53b726e6..86797e0242d4 100644 > --- a/tools/testing/selftests/kvm/Makefile > +++ b/tools/testing/selftests/kvm/Makefile > @@ -66,6 +66,7 @@ LDFLAGS += -pthread $(no-pie-option) $(pgste-option) > # After inclusion, $(OUTPUT) is defined and > # $(TEST_GEN_PROGS) starts with $(OUTPUT)/ > include ../lib.mk > +x := $(shell mkdir -p $(sort $(dir $(TEST_GEN_PROGS)))) lib.mk would have created the directory. thanks, -- Shuah