1 # SPDX-License-Identifier: GPL-2.0 1 # SPDX-License-Identifier: GPL-2.0 2 TEST_GEN_PROGS := switch_endian_test 2 TEST_GEN_PROGS := switch_endian_test 3 3 4 EXTRA_CLEAN = $(OUTPUT)/*.o $(OUTPUT)/check-re 4 EXTRA_CLEAN = $(OUTPUT)/*.o $(OUTPUT)/check-reversed.S 5 5 6 top_srcdir = ../../../../.. 6 top_srcdir = ../../../../.. 7 include ../../lib.mk 7 include ../../lib.mk 8 include ../flags.mk 8 include ../flags.mk 9 9 10 ASFLAGS += -O2 -Wall -g -nostdlib -m64 10 ASFLAGS += -O2 -Wall -g -nostdlib -m64 11 11 12 $(OUTPUT)/switch_endian_test: ASFLAGS += -I $( 12 $(OUTPUT)/switch_endian_test: ASFLAGS += -I $(OUTPUT) 13 $(OUTPUT)/switch_endian_test: $(OUTPUT)/check- 13 $(OUTPUT)/switch_endian_test: $(OUTPUT)/check-reversed.S 14 14 15 $(OUTPUT)/check-reversed.o: $(OUTPUT)/check.o 15 $(OUTPUT)/check-reversed.o: $(OUTPUT)/check.o 16 $(CROSS_COMPILE)objcopy -j .text --rev 16 $(CROSS_COMPILE)objcopy -j .text --reverse-bytes=4 -O binary $< $@ 17 17 18 $(OUTPUT)/check-reversed.S: $(OUTPUT)/check-re 18 $(OUTPUT)/check-reversed.S: $(OUTPUT)/check-reversed.o 19 hexdump -v -e '/1 ".byte 0x%02X\n"' $< 19 hexdump -v -e '/1 ".byte 0x%02X\n"' $< > $@
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.