From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934156AbbELWDE (ORCPT ); Tue, 12 May 2015 18:03:04 -0400 Received: from lists.s-osg.org ([54.187.51.154]:55263 "EHLO lists.s-osg.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933812AbbELWDC (ORCPT ); Tue, 12 May 2015 18:03:02 -0400 Message-ID: <55527893.4070305@osg.samsung.com> Date: Tue, 12 May 2015 16:02:59 -0600 From: Shuah Khan Organization: Samsung Open Source Group User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 MIME-Version: 1.0 To: tyler.baker@linaro.org CC: Andy Lutomirski , Kevin Hilman , John Stultz , Darren Hart , Michael Ellerman , David Herrmann , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" Subject: Re: [PATCH 1/2] selftests/lib.mk: fix INSTALL_RULE References: <1431467947-29847-1-git-send-email-tyler.baker@linaro.org> <1431467947-29847-2-git-send-email-tyler.baker@linaro.org> In-Reply-To: <1431467947-29847-2-git-send-email-tyler.baker@linaro.org> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05/12/2015 03:59 PM, tyler.baker@linaro.org wrote: > From: Tyler Baker This is odd. Did you use git send-email to send the patches? -- Shuah > > This patch fixes the INSTALL_RULE to gracefully handle the case where > TEST_PROGS and TEST_PROGS_EXTENDED and TEST_FILES are not set. In this case, > install is called without any SOURCE arguments causing make install to fail. > The proposed fix is to loop over the items in these variables and only call > install if there is a test artifact present. > > Signed-off-by: Tyler Baker > --- > tools/testing/selftests/lib.mk | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/tools/testing/selftests/lib.mk b/tools/testing/selftests/lib.mk > index ee412ba..89dd785f 100644 > --- a/tools/testing/selftests/lib.mk > +++ b/tools/testing/selftests/lib.mk > @@ -13,10 +13,12 @@ run_tests: all > > define INSTALL_RULE > mkdir -p $(INSTALL_PATH) > - @for TEST_DIR in $(TEST_DIRS); do\ > + @for TEST_DIR in $(TEST_DIRS); do \ > cp -r $$TEST_DIR $(INSTALL_PATH); \ > done; > - install -t $(INSTALL_PATH) $(TEST_PROGS) $(TEST_PROGS_EXTENDED) $(TEST_FILES) > + @for ARTIFACT in $(TEST_PROGS) $(TEST_PROGS_EXTENDED) $(TEST_FILES); do \ > + install -t $(INSTALL_PATH) $$ARTIFACT; \ > + done; > endef > > install: all > -- Shuah Khan Sr. Linux Kernel Developer Open Source Innovation Group Samsung Research America (Silicon Valley) shuahkh@osg.samsung.com | (970) 217-8978 From mboxrd@z Thu Jan 1 00:00:00 1970 From: shuahkh@osg.samsung.com (Shuah Khan) Date: Tue, 12 May 2015 16:02:59 -0600 Subject: [PATCH 1/2] selftests/lib.mk: fix INSTALL_RULE In-Reply-To: <1431467947-29847-2-git-send-email-tyler.baker@linaro.org> References: <1431467947-29847-1-git-send-email-tyler.baker@linaro.org> <1431467947-29847-2-git-send-email-tyler.baker@linaro.org> Message-ID: <55527893.4070305@osg.samsung.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On 05/12/2015 03:59 PM, tyler.baker at linaro.org wrote: > From: Tyler Baker This is odd. Did you use git send-email to send the patches? -- Shuah > > This patch fixes the INSTALL_RULE to gracefully handle the case where > TEST_PROGS and TEST_PROGS_EXTENDED and TEST_FILES are not set. In this case, > install is called without any SOURCE arguments causing make install to fail. > The proposed fix is to loop over the items in these variables and only call > install if there is a test artifact present. > > Signed-off-by: Tyler Baker > --- > tools/testing/selftests/lib.mk | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/tools/testing/selftests/lib.mk b/tools/testing/selftests/lib.mk > index ee412ba..89dd785f 100644 > --- a/tools/testing/selftests/lib.mk > +++ b/tools/testing/selftests/lib.mk > @@ -13,10 +13,12 @@ run_tests: all > > define INSTALL_RULE > mkdir -p $(INSTALL_PATH) > - @for TEST_DIR in $(TEST_DIRS); do\ > + @for TEST_DIR in $(TEST_DIRS); do \ > cp -r $$TEST_DIR $(INSTALL_PATH); \ > done; > - install -t $(INSTALL_PATH) $(TEST_PROGS) $(TEST_PROGS_EXTENDED) $(TEST_FILES) > + @for ARTIFACT in $(TEST_PROGS) $(TEST_PROGS_EXTENDED) $(TEST_FILES); do \ > + install -t $(INSTALL_PATH) $$ARTIFACT; \ > + done; > endef > > install: all > -- Shuah Khan Sr. Linux Kernel Developer Open Source Innovation Group Samsung Research America (Silicon Valley) shuahkh at osg.samsung.com | (970) 217-8978