Skip to content

Commit 63ec90f

Browse files
ihamasahir0y
authored andcommitted
um: ensure make ARCH=um mrproper removes arch/$(SUBARCH)/include/generated/
In this workflow: $ make ARCH=um defconfig && make ARCH=um -j8 [snip] $ make ARCH=um mrproper [snip] $ make ARCH=um defconfig O=./build_um && make ARCH=um -j8 O=./build_um [snip] CC scripts/mod/empty.o In file included from ../include/linux/types.h:6, from ../include/linux/mod_devicetable.h:12, from ../scripts/mod/devicetable-offsets.c:3: ../include/uapi/linux/types.h:5:10: fatal error: asm/types.h: No such file or directory 5 | #include <asm/types.h> | ^~~~~~~~~~~~~ compilation terminated. make[2]: *** [../scripts/Makefile.build:100: scripts/mod/devicetable-offsets.s] Error 1 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/home/iha/sdb/opensource/lkmp/linux-kselftest.git/Makefile:1140: prepare0] Error 2 make[1]: Leaving directory '/home/iha/sdb/opensource/lkmp/linux-kselftest.git/build_um' make: *** [Makefile:180: sub-make] Error 2 The cause of the error was because arch/$(SUBARCH)/include/generated files weren't properly cleaned by `make ARCH=um mrproper`. Fixes: a788b2e ("kbuild: check arch/$(SRCARCH)/include/generated before out-of-tree build") Reported-by: Theodore Ts'o <[email protected]> Suggested-by: Masahiro Yamada <[email protected]> Signed-off-by: Vitor Massaru Iha <[email protected]> Reviewed-by: Brendan Higgins <[email protected]> Tested-by: Brendan Higgins <[email protected]> Link: https://groups.google.com/forum/#!msg/kunit-dev/QmA27YEgEgI/hvS1kiz2CwAJ Signed-off-by: Masahiro Yamada <[email protected]>
1 parent 62d0fd5 commit 63ec90f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

arch/um/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,7 @@ export CFLAGS_vmlinux := $(LINK-y) $(LINK_WRAPS) $(LD_FLAGS_CMDLINE)
140140
# When cleaning we don't include .config, so we don't include
141141
# TT or skas makefiles and don't clean skas_ptregs.h.
142142
CLEAN_FILES += linux x.i gmon.out
143+
MRPROPER_DIRS += arch/$(SUBARCH)/include/generated
143144

144145
archclean:
145146
@find . \( -name '*.bb' -o -name '*.bbg' -o -name '*.da' \

0 commit comments

Comments
 (0)