From 418a272f4ab4221c37a9272d48fd31d5ac1bddc1 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Wed, 4 Sep 2019 07:46:25 +0000 Subject: [dotest] Avoid the need for LEVEL= makefile boilerplate Summary: Instead of each test case knowing its depth relative to the test root, we can just have dotest add the folder containing Makefile.rules to the include path. This was motivated by r370616, though I have been wanting to do this ever since we moved to building tests out-of-tree. The only manually modified files in this patch are lldbinline.py and plugins/builder_base.py. The rest of the patch has been produced by this shell command: find . \( -name Makefile -o -name '*.mk' \) -exec sed --in-place -e '/LEVEL *:\?=/d' -e '1,2{/^$/d}' -e 's,\$(LEVEL)/,,' {} + Reviewers: teemperor, aprantl, espindola, jfb Subscribers: emaste, javed.absar, arichardson, christof, arphaman, lldb-commits Differential Revision: https://reviews.llvm.org/D67083 llvm-svn: 370845 --- .../Python/lldbsuite/test/commands/process/attach-resume/Makefile | 4 +--- lldb/packages/Python/lldbsuite/test/commands/process/attach/Makefile | 4 +--- .../lldbsuite/test/commands/process/attach/attach_denied/Makefile | 4 +--- .../lldbsuite/test/commands/process/launch-with-shellexpand/Makefile | 4 +--- lldb/packages/Python/lldbsuite/test/commands/process/launch/Makefile | 4 +--- 5 files changed, 5 insertions(+), 15 deletions(-) (limited to 'lldb/packages/Python/lldbsuite/test/commands/process') diff --git a/lldb/packages/Python/lldbsuite/test/commands/process/attach-resume/Makefile b/lldb/packages/Python/lldbsuite/test/commands/process/attach-resume/Makefile index ea27ca7dec2..dc1d28d1c03 100644 --- a/lldb/packages/Python/lldbsuite/test/commands/process/attach-resume/Makefile +++ b/lldb/packages/Python/lldbsuite/test/commands/process/attach-resume/Makefile @@ -1,7 +1,5 @@ -LEVEL = ../../../make - CXX_SOURCES := main.cpp ENABLE_THREADS := YES EXE := AttachResume -include $(LEVEL)/Makefile.rules +include Makefile.rules diff --git a/lldb/packages/Python/lldbsuite/test/commands/process/attach/Makefile b/lldb/packages/Python/lldbsuite/test/commands/process/attach/Makefile index 91c895cf68d..8a52f8fcd47 100644 --- a/lldb/packages/Python/lldbsuite/test/commands/process/attach/Makefile +++ b/lldb/packages/Python/lldbsuite/test/commands/process/attach/Makefile @@ -1,7 +1,5 @@ -LEVEL = ../../../make - CXX_SOURCES := main.cpp EXE := ProcessAttach -include $(LEVEL)/Makefile.rules +include Makefile.rules diff --git a/lldb/packages/Python/lldbsuite/test/commands/process/attach/attach_denied/Makefile b/lldb/packages/Python/lldbsuite/test/commands/process/attach/attach_denied/Makefile index d7926a98402..a694d36ac0d 100644 --- a/lldb/packages/Python/lldbsuite/test/commands/process/attach/attach_denied/Makefile +++ b/lldb/packages/Python/lldbsuite/test/commands/process/attach/attach_denied/Makefile @@ -1,12 +1,10 @@ -LEVEL = ../../../../make - CXX_SOURCES := main.cpp EXE := AttachDenied all: AttachDenied sign -include $(LEVEL)/Makefile.rules +include Makefile.rules sign: entitlements.plist AttachDenied ifeq ($(OS),Darwin) diff --git a/lldb/packages/Python/lldbsuite/test/commands/process/launch-with-shellexpand/Makefile b/lldb/packages/Python/lldbsuite/test/commands/process/launch-with-shellexpand/Makefile index 314f1cb2f07..99998b20bcb 100644 --- a/lldb/packages/Python/lldbsuite/test/commands/process/launch-with-shellexpand/Makefile +++ b/lldb/packages/Python/lldbsuite/test/commands/process/launch-with-shellexpand/Makefile @@ -1,5 +1,3 @@ -LEVEL = ../../../make - CXX_SOURCES := main.cpp -include $(LEVEL)/Makefile.rules +include Makefile.rules diff --git a/lldb/packages/Python/lldbsuite/test/commands/process/launch/Makefile b/lldb/packages/Python/lldbsuite/test/commands/process/launch/Makefile index 54d1c2bf7f3..eff77274c7b 100644 --- a/lldb/packages/Python/lldbsuite/test/commands/process/launch/Makefile +++ b/lldb/packages/Python/lldbsuite/test/commands/process/launch/Makefile @@ -1,7 +1,5 @@ -LEVEL = ../../../make - CXX_SOURCES := main.cpp #CXX_SOURCES := print-cwd.cpp -include $(LEVEL)/Makefile.rules +include Makefile.rules -- cgit v1.2.3