From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753445AbdHOQdt (ORCPT ); Tue, 15 Aug 2017 12:33:49 -0400 Received: from mail-oi0-f42.google.com ([209.85.218.42]:35009 "EHLO mail-oi0-f42.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752602AbdHOQdq (ORCPT ); Tue, 15 Aug 2017 12:33:46 -0400 From: =?UTF-8?q?Daniel=20D=C3=ADaz?= To: linux-kernel@vger.kernel.org Cc: acme@kernel.org, peterz@infradead.org, mingo@redhat.com, =?UTF-8?q?Daniel=20D=C3=ADaz?= Subject: [PATCH] tools lib bpf: Fix double file test in Makefile Date: Tue, 15 Aug 2017 11:33:30 -0500 Message-Id: <1502814810-960-1-git-send-email-daniel.diaz@linaro.org> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The Makefile verifies the same file exists twice: test -f ../../../include/uapi/linux/bpf.h -a \ -f ../../../include/uapi/linux/bpf.h The purpose of the check is to ensure the diff (immediately after the test) doesn't fail with these two files: /tools/include/uapi/linux/bpf.h /include/uapi/linux/bpf.h Same recipe for bpf_common: test -f ../../../include/uapi/linux/bpf_common.h -a \ -f ../../../include/uapi/linux/bpf_common.h This corrects the location of the tests. Signed-off-by: Daniel Díaz --- tools/lib/bpf/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/lib/bpf/Makefile b/tools/lib/bpf/Makefile index 1f5300e..9216c31 100644 --- a/tools/lib/bpf/Makefile +++ b/tools/lib/bpf/Makefile @@ -154,10 +154,10 @@ all: fixdep $(VERSION_FILES) all_cmd all_cmd: $(CMD_TARGETS) $(BPF_IN): force elfdep bpfdep - @(test -f ../../../include/uapi/linux/bpf.h -a -f ../../../include/uapi/linux/bpf.h && ( \ + @(test -f ../../include/uapi/linux/bpf.h -a -f ../../../include/uapi/linux/bpf.h && ( \ (diff -B ../../include/uapi/linux/bpf.h ../../../include/uapi/linux/bpf.h >/dev/null) || \ echo "Warning: tools/include/uapi/linux/bpf.h differs from kernel" >&2 )) || true - @(test -f ../../../include/uapi/linux/bpf_common.h -a -f ../../../include/uapi/linux/bpf_common.h && ( \ + @(test -f ../../include/uapi/linux/bpf_common.h -a -f ../../../include/uapi/linux/bpf_common.h && ( \ (diff -B ../../include/uapi/linux/bpf_common.h ../../../include/uapi/linux/bpf_common.h >/dev/null) || \ echo "Warning: tools/include/uapi/linux/bpf_common.h differs from kernel" >&2 )) || true $(Q)$(MAKE) $(build)=libbpf -- 2.7.4