Skip to content

Commit 7e0cf1c

Browse files
committed
selftests/powerpc: Fix Makefiles for headers_install change
Commit b2d35fa ("selftests: add headers_install to lib.mk") introduced a requirement that Makefiles more than one level below the selftests directory need to define top_srcdir, but it didn't update any of the powerpc Makefiles. This broke building all the powerpc selftests with eg: make[1]: Entering directory '/src/linux/tools/testing/selftests/powerpc' BUILD_TARGET=/src/linux/tools/testing/selftests/powerpc/alignment; mkdir -p $BUILD_TARGET; make OUTPUT=$BUILD_TARGET -k -C alignment all make[2]: Entering directory '/src/linux/tools/testing/selftests/powerpc/alignment' ../../lib.mk:20: ../../../../scripts/subarch.include: No such file or directory make[2]: *** No rule to make target '../../../../scripts/subarch.include'. make[2]: Failed to remake makefile '../../../../scripts/subarch.include'. Makefile:38: recipe for target 'alignment' failed Fix it by setting top_srcdir in the affected Makefiles. Fixes: b2d35fa ("selftests: add headers_install to lib.mk") Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
1 parent 2483ef0 commit 7e0cf1c

File tree

17 files changed

+17
-0
lines changed

17 files changed

+17
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
TEST_GEN_PROGS := copy_first_unaligned alignment_handler
22

3+
top_srcdir = ../../../../..
34
include ../../lib.mk
45

56
$(TEST_GEN_PROGS): ../harness.c ../utils.c

tools/testing/selftests/powerpc/benchmarks/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ TEST_GEN_FILES := exec_target
44

55
CFLAGS += -O2
66

7+
top_srcdir = ../../../../..
78
include ../../lib.mk
89

910
$(TEST_GEN_PROGS): ../harness.c

tools/testing/selftests/powerpc/cache_shape/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ all: $(TEST_PROGS)
55

66
$(TEST_PROGS): ../harness.c ../utils.c
77

8+
top_srcdir = ../../../../..
89
include ../../lib.mk
910

1011
clean:

tools/testing/selftests/powerpc/copyloops/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ TEST_GEN_PROGS := copyuser_64_t0 copyuser_64_t1 copyuser_64_t2 \
1717

1818
EXTRA_SOURCES := validate.c ../harness.c stubs.S
1919

20+
top_srcdir = ../../../../..
2021
include ../../lib.mk
2122

2223
$(OUTPUT)/copyuser_64_t%: copyuser_64.S $(EXTRA_SOURCES)

tools/testing/selftests/powerpc/dscr/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ TEST_GEN_PROGS := dscr_default_test dscr_explicit_test dscr_user_test \
33
dscr_inherit_test dscr_inherit_exec_test dscr_sysfs_test \
44
dscr_sysfs_thread_test
55

6+
top_srcdir = ../../../../..
67
include ../../lib.mk
78

89
$(OUTPUT)/dscr_default_test: LDLIBS += -lpthread

tools/testing/selftests/powerpc/math/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# SPDX-License-Identifier: GPL-2.0
22
TEST_GEN_PROGS := fpu_syscall fpu_preempt fpu_signal vmx_syscall vmx_preempt vmx_signal vsx_preempt
33

4+
top_srcdir = ../../../../..
45
include ../../lib.mk
56

67
$(TEST_GEN_PROGS): ../harness.c

tools/testing/selftests/powerpc/mm/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ noarg:
55
TEST_GEN_PROGS := hugetlb_vs_thp_test subpage_prot prot_sao segv_errors
66
TEST_GEN_FILES := tempfile
77

8+
top_srcdir = ../../../../..
89
include ../../lib.mk
910

1011
$(TEST_GEN_PROGS): ../harness.c

tools/testing/selftests/powerpc/pmu/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ noarg:
55
TEST_GEN_PROGS := count_instructions l3_bank_test per_event_excludes
66
EXTRA_SOURCES := ../harness.c event.c lib.c ../utils.c
77

8+
top_srcdir = ../../../../..
89
include ../../lib.mk
910

1011
all: $(TEST_GEN_PROGS) ebb

tools/testing/selftests/powerpc/pmu/ebb/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ TEST_GEN_PROGS := reg_access_test event_attributes_test cycles_test \
1717
lost_exception_test no_handler_test \
1818
cycles_with_mmcr2_test
1919

20+
top_srcdir = ../../../../../..
2021
include ../../../lib.mk
2122

2223
$(TEST_GEN_PROGS): ../../harness.c ../../utils.c ../event.c ../lib.c \

tools/testing/selftests/powerpc/primitives/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ CFLAGS += -I$(CURDIR)
22

33
TEST_GEN_PROGS := load_unaligned_zeropad
44

5+
top_srcdir = ../../../../..
56
include ../../lib.mk
67

78
$(TEST_GEN_PROGS): ../harness.c

tools/testing/selftests/powerpc/ptrace/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ TEST_PROGS := ptrace-gpr ptrace-tm-gpr ptrace-tm-spd-gpr \
44
ptrace-tm-spd-vsx ptrace-tm-spr ptrace-hwbreak ptrace-pkey core-pkey \
55
perf-hwbreak
66

7+
top_srcdir = ../../../../..
78
include ../../lib.mk
89

910
all: $(TEST_PROGS)

tools/testing/selftests/powerpc/signal/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ $(TEST_PROGS): ../harness.c ../utils.c signal.S
88
CFLAGS += -maltivec
99
signal_tm: CFLAGS += -mhtm
1010

11+
top_srcdir = ../../../../..
1112
include ../../lib.mk
1213

1314
clean:

tools/testing/selftests/powerpc/stringloops/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ endif
2929

3030
ASFLAGS = $(CFLAGS)
3131

32+
top_srcdir = ../../../../..
3233
include ../../lib.mk
3334

3435
$(TEST_GEN_PROGS): $(EXTRA_SOURCES)

tools/testing/selftests/powerpc/switch_endian/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ ASFLAGS += -O2 -Wall -g -nostdlib -m64
55

66
EXTRA_CLEAN = $(OUTPUT)/*.o $(OUTPUT)/check-reversed.S
77

8+
top_srcdir = ../../../../..
89
include ../../lib.mk
910

1011
$(OUTPUT)/switch_endian_test: $(OUTPUT)/check-reversed.S

tools/testing/selftests/powerpc/syscalls/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ TEST_GEN_PROGS := ipc_unmuxed
22

33
CFLAGS += -I../../../../../usr/include
44

5+
top_srcdir = ../../../../..
56
include ../../lib.mk
67

78
$(TEST_GEN_PROGS): ../harness.c

tools/testing/selftests/powerpc/tm/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ TEST_GEN_PROGS := tm-resched-dscr tm-syscall tm-signal-msr-resv tm-signal-stack
66
tm-vmxcopy tm-fork tm-tar tm-tmspr tm-vmx-unavail tm-unavailable tm-trap \
77
$(SIGNAL_CONTEXT_CHK_TESTS) tm-sigreturn
88

9+
top_srcdir = ../../../../..
910
include ../../lib.mk
1011

1112
$(TEST_GEN_PROGS): ../harness.c ../utils.c

tools/testing/selftests/powerpc/vphn/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ TEST_GEN_PROGS := test-vphn
22

33
CFLAGS += -m64
44

5+
top_srcdir = ../../../../..
56
include ../../lib.mk
67

78
$(TEST_GEN_PROGS): ../harness.c

0 commit comments

Comments
 (0)