Skip to content

Commit aead781

Browse files
tuananhlfcWilliam Breathitt Gray
authored and
William Breathitt Gray
committedJul 24, 2023
tools/counter: Makefile: Replace rmdir by rm to avoid make,clean failure
Use rm -df instead of rmdir -p since rmdir requires the directory exist so it causes "make -C tools clean" failed if someone only builds other tools but not counter. Fixes: 228354e ("tools/counter: Makefile: Remove lingering 'include' directories on make clean") Signed-off-by: Anh Tuan Phan <[email protected]> Link: https://lore.kernel.org/r/[email protected]/ Signed-off-by: William Breathitt Gray <[email protected]>
1 parent 272ffb9 commit aead781

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed
 

‎tools/counter/Makefile

+2-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ $(OUTPUT)counter_example: $(COUNTER_EXAMPLE)
4040
clean:
4141
rm -f $(ALL_PROGRAMS)
4242
rm -rf $(OUTPUT)include/linux/counter.h
43-
rmdir -p $(OUTPUT)include/linux
43+
rm -df $(OUTPUT)include/linux
44+
rm -df $(OUTPUT)include
4445
find $(or $(OUTPUT),.) -name '*.o' -delete -o -name '\.*.d' -delete
4546

4647
install: $(ALL_PROGRAMS)

0 commit comments

Comments
 (0)
Please sign in to comment.