Received: by 10.213.65.68 with SMTP id h4csp808372imn; Tue, 27 Mar 2018 09:08:30 -0700 (PDT) X-Google-Smtp-Source: AG47ELvg2YtSwODVkq6PxhFD7hn4zToEKMOO1Qje/g3F65tKsgMPE/YnYbSnN1KpMMNvTyKWVkDP X-Received: by 2002:a17:902:1744:: with SMTP id i62-v6mr27647577pli.62.1522166909948; Tue, 27 Mar 2018 09:08:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522166909; cv=none; d=google.com; s=arc-20160816; b=VbJcN1z6ooAb3iV3m/JhitVl9WI+2DwPlM/W7ioTAccRiIOhEkDh+6+/8kt7GiqiCu Rjlin2lE4QQkntGyvk5YzaUhnDDkrPZ9J3NKCXJdxaz/PdMW2XtAo16Wb6YlfgPaskkV 4tMHcMELBwcYVVFcp+Z94XFYB2Uy9z7tpPd716C9v9JyO4xPOwHIPXg8hF93HmiTt+q0 xQltsSbIDuQwf4fXnlAa34iiz4osBAYmvAYDhTzFaKUMi5dHxt2dDT+4YSx98oVmgAlN ODOn3KFKqJQvUyExMIU0tLOBmMAROI2h0RbE1hBVp/0kFzDOKsjsLONxdFg0T/N4fD5C 2U4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=7JlaULysr9kTlzpddmC3wuiRCAWSV1KqT18S4yPnoW4=; b=pBdnaw6YI98OCBdpXqI+lUzwYzNh3y3G9mzHLJtb9RcvV/29wIB63nb5F3SBY+g7iL KxDgDEso5Lkd1B6vUhsAuONVVjjxDUA5yyRwnZkRK3i6CqhCkMAb919e56dCBLXrKubX xAIcmeioK1wSOnOctVPzOjUOqg8Kd2jQdg/dek+5Zv5N3+SkHah5+cD29CJ2XNbZfUbb rUlEiX5sNEZTe3hPPV3FgvJTSeZ4OF1kCY2n91NyLBFoBmm4GSO2BulSEsKYO+rW/R2z tuWKJUGhCTrEFJl3fOCDsqSI/YsjjFyma31xg9IEdh7VhCdrLJzXay9NMvC1AVTTIG+y NahA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q64si1147646pfq.371.2018.03.27.09.08.11; Tue, 27 Mar 2018 09:08:29 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752861AbeC0QGa (ORCPT + 99 others); Tue, 27 Mar 2018 12:06:30 -0400 Received: from mail.efficios.com ([167.114.142.138]:51784 "EHLO mail.efficios.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752582AbeC0QGX (ORCPT ); Tue, 27 Mar 2018 12:06:23 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.efficios.com (Postfix) with ESMTP id 233A61A5176; Tue, 27 Mar 2018 12:06:22 -0400 (EDT) Received: from mail.efficios.com ([127.0.0.1]) by localhost (mail02.efficios.com [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id 2OVZCImavg5F; Tue, 27 Mar 2018 12:06:21 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by mail.efficios.com (Postfix) with ESMTP id 669301A5137; Tue, 27 Mar 2018 12:06:21 -0400 (EDT) X-Virus-Scanned: amavisd-new at efficios.com Received: from mail.efficios.com ([127.0.0.1]) by localhost (mail02.efficios.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id 0imdf7MU7eSH; Tue, 27 Mar 2018 12:06:21 -0400 (EDT) Received: from thinkos.internal.efficios.com (192-222-157-41.qc.cable.ebox.net [192.222.157.41]) by mail.efficios.com (Postfix) with ESMTPSA id 0430A1A511B; Tue, 27 Mar 2018 12:06:21 -0400 (EDT) From: Mathieu Desnoyers To: Peter Zijlstra , "Paul E . McKenney" , Boqun Feng , Andy Lutomirski , Dave Watson Cc: linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, Paul Turner , Andrew Morton , Russell King , Thomas Gleixner , Ingo Molnar , "H . Peter Anvin" , Andrew Hunter , Andi Kleen , Chris Lameter , Ben Maurer , Steven Rostedt , Josh Triplett , Linus Torvalds , Catalin Marinas , Will Deacon , Michael Kerrisk , Mathieu Desnoyers , linux-kselftest@vger.kernel.org Subject: [RFC PATCH for 4.17 14/21] selftests: lib.mk: Introduce OVERRIDE_TARGETS Date: Tue, 27 Mar 2018 12:05:35 -0400 Message-Id: <20180327160542.28457-15-mathieu.desnoyers@efficios.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180327160542.28457-1-mathieu.desnoyers@efficios.com> References: <20180327160542.28457-1-mathieu.desnoyers@efficios.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Introduce OVERRIDE_TARGETS to allow tests to express dependencies on header files and .so, which require to override the selftests lib.mk targets. Signed-off-by: Mathieu Desnoyers Acked-by: Shuah Khan CC: Russell King CC: Catalin Marinas CC: Will Deacon CC: Thomas Gleixner CC: Paul Turner CC: Andrew Hunter CC: Peter Zijlstra CC: Andy Lutomirski CC: Andi Kleen CC: Dave Watson CC: Chris Lameter CC: Ingo Molnar CC: "H. Peter Anvin" CC: Ben Maurer CC: Steven Rostedt CC: "Paul E. McKenney" CC: Josh Triplett CC: Linus Torvalds CC: Andrew Morton CC: Boqun Feng CC: linux-kselftest@vger.kernel.org CC: linux-api@vger.kernel.org --- tools/testing/selftests/lib.mk | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/testing/selftests/lib.mk b/tools/testing/selftests/lib.mk index 7de482a0519d..3d4bdeb072b2 100644 --- a/tools/testing/selftests/lib.mk +++ b/tools/testing/selftests/lib.mk @@ -105,6 +105,9 @@ COMPILE.S = $(CC) $(ASFLAGS) $(CPPFLAGS) $(TARGET_ARCH) -c LINK.S = $(CC) $(ASFLAGS) $(CPPFLAGS) $(LDFLAGS) $(TARGET_ARCH) endif +# Selftest makefiles can override those targets by setting +# OVERRIDE_TARGETS = 1. +ifeq ($(OVERRIDE_TARGETS),) $(OUTPUT)/%:%.c $(LINK.c) $^ $(LDLIBS) -o $@ @@ -113,5 +116,6 @@ $(OUTPUT)/%.o:%.S $(OUTPUT)/%:%.S $(LINK.S) $^ $(LDLIBS) -o $@ +endif .PHONY: run_tests all clean install emit_tests -- 2.11.0