Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp5018412ybe; Tue, 17 Sep 2019 00:53:49 -0700 (PDT) X-Google-Smtp-Source: APXvYqzcIepyIGBKmOi6L49qop3InN89TdTjBdBbQsjFCiFbfaCxqWyPXmhz/Ui3aIQaWUA4d/X6 X-Received: by 2002:aa7:ce81:: with SMTP id y1mr3326942edv.188.1568706829255; Tue, 17 Sep 2019 00:53:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568706829; cv=none; d=google.com; s=arc-20160816; b=AYVFdz7E3OqUU5cTEu3PBfqSl3lUUnEucTmCMRX5f97yzRnbttE/onEVWeMly2PHQO Ym+Es4ZIDW0NQit1fa2SMDWWqixwezJbfy8/4G9VTYJW2v3q2HpEFp6TRVTHfGKGYiwE RkXM3BnTvNIlu/5VkxW8tRLEO6muvWaZ2d9a4u/owT3MoMTro8ozASufyL8Ve3yxnRjl zL2RtBvjqgIzJvFB+TJf+BgUvCtRpx66r3bOdPSVQD5ShQnJpUvMUXyR3G376AO8n5o0 GOMD2wpejoz7Ei1ju+cFoFHkUMaYaVTbfxSPY7elwgr1BxrQhBNaCciRVoR31t7gQZ5y i5Fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from; bh=zpJIje3IAiTFPgzuA0LjDPdGxGpCjCXVAKKg6bDYq+w=; b=kFa1A4D6WJb88YGBP70r3Zfn1qT7i9QFhM1hMzeYgMl/eGVyFP0OpZ53qNlf35Qs2E PEf87UZKJMOdVHqHSQRy3CvZ2fkJgTDpzWUeuAGW0+Sm2Tx3lAZln1ztAzez3BtsAps2 uVXbDZfiWNscmsHnPX4zMntJym6WXlLPZja9s22dihl7xS7/448xqE+cJKoL7iRQ/EHu uHYJ8ljo3x+8EUokNLVrTfWf4+nfrW/D4FjQV3kZT4RvNSnwUQxzOor9LhPHliBgnpat SjFl3fxQSbgzfMzRFbGok/sKLpFJjYPSvd6JMFKOzmOdP9RmkYcS8//MoIlsTWm1Xe3S Hxng== 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 rh23si695112ejb.75.2019.09.17.00.53.26; Tue, 17 Sep 2019 00:53:49 -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 S1732207AbfIPVfw (ORCPT + 99 others); Mon, 16 Sep 2019 17:35:52 -0400 Received: from mail-out.m-online.net ([212.18.0.10]:52656 "EHLO mail-out.m-online.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728552AbfIPVfw (ORCPT ); Mon, 16 Sep 2019 17:35:52 -0400 Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 46XKKt6p0Kz1r7hh; Mon, 16 Sep 2019 23:35:46 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 46XKKt4s1Pz1qsD2; Mon, 16 Sep 2019 23:35:46 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id vL_Z3Yvzkzi9; Mon, 16 Sep 2019 23:35:45 +0200 (CEST) X-Auth-Info: 7Yzorz4cL64cpIXYMwEei+hYY6VSe697biienY//MW0u7gRp/4RLUg4/7I3tvenS Received: from igel.home (ppp-46-244-165-89.dynamic.mnet-online.de [46.244.165.89]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPSA; Mon, 16 Sep 2019 23:35:45 +0200 (CEST) Received: by igel.home (Postfix, from userid 1000) id A03192C0173; Mon, 16 Sep 2019 23:35:44 +0200 (CEST) From: Andreas Schwab To: Andrii Nakryiko Cc: Ivan Khoronzhuk , Alexei Starovoitov , Daniel Borkmann , Yonghong Song , "David S. Miller" , Jakub Kicinski , Jesper Dangaard Brouer , john fastabend , open list , Networking , bpf , clang-built-linux@googlegroups.com, sergei.shtylyov@cogentembedded.com Subject: Re: [PATCH v3 bpf-next 01/14] samples: bpf: makefile: fix HDR_PROBE "echo" References: <20190916105433.11404-1-ivan.khoronzhuk@linaro.org> <20190916105433.11404-2-ivan.khoronzhuk@linaro.org> X-Yow: I always wanted a NOSE JOB!! Date: Mon, 16 Sep 2019 23:35:44 +0200 In-Reply-To: (Andrii Nakryiko's message of "Mon, 16 Sep 2019 13:13:23 -0700") Message-ID: <8736gvexfz.fsf@igel.home> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sep 16 2019, Andrii Nakryiko wrote: > On Mon, Sep 16, 2019 at 3:59 AM Ivan Khoronzhuk > wrote: >> >> echo should be replaced with echo -e to handle '\n' correctly, but >> instead, replace it with printf as some systems can't handle echo -e. >> >> Signed-off-by: Ivan Khoronzhuk >> --- >> samples/bpf/Makefile | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/samples/bpf/Makefile b/samples/bpf/Makefile >> index 1d9be26b4edd..f50ca852c2a8 100644 >> --- a/samples/bpf/Makefile >> +++ b/samples/bpf/Makefile >> @@ -201,7 +201,7 @@ endif >> >> # Don't evaluate probes and warnings if we need to run make recursively >> ifneq ($(src),) >> -HDR_PROBE := $(shell echo "\#include \n struct list_head { int a; }; int main() { return 0; }" | \ >> +HDR_PROBE := $(shell printf "\#include \n struct list_head { int a; }; int main() { return 0; }" | \ > > printf change is fine, but I'm confused about \# at the beginning of > the string. From the NEWS of make 4.3: * WARNING: Backward-incompatibility! Number signs (#) appearing inside a macro reference or function invocation no longer introduce comments and should not be escaped with backslashes: thus a call such as: foo := $(shell echo '#') is legal. Previously the number sign needed to be escaped, for example: foo := $(shell echo '\#') Now this latter will resolve to "\#". If you want to write makefiles portable to both versions, assign the number sign to a variable: H := \# foo := $(shell echo '$H') This was claimed to be fixed in 3.81, but wasn't, for some reason. To detect this change search for 'nocomment' in the .FEATURES variable. Andreas. -- Andreas Schwab, schwab@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1 "And now for something completely different."