Skip to content

Commit 6fbd956

Browse files
authored
Merge pull request #1881 from petterreinholdtsen/clean-headers-mods-scripts
Remove more generated files in the clean target
2 parents f41ae48 + 567ecb5 commit 6fbd956

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

debian/rules.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ endif
6060
override_dh_auto_clean:
6161
dh_auto_clean
6262
py3clean .
63-
if [ -r src/Makefile.inc -a -r src/config.status ]; then cd src && $(MAKE) clean -s; fi
63+
if [ -r src/Makefile.inc -a -r src/config.status ]; then cd src && $(MAKE) clean modclean -s; fi
6464
rm -f Makefile.inc
6565
rm -f src/config.log src/config.status
6666
rm -f $(for i in $(find . -name "*.in"); do basename $i .in; done)

src/Makefile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ default: $(INFILES)
316316
# is listed here. Note that due to $(INCLUDE), defined above, the include
317317
# files in the source tree are the ones used when building linuxcnc. The copy
318318
# in ../include is used when building external components of linuxcnc.
319-
HEADERS := \
319+
SRCHEADERS := \
320320
emc/linuxcnc.h \
321321
emc/ini/emcIniFile.hh \
322322
emc/ini/iniaxis.hh \
@@ -439,7 +439,7 @@ HEADERS := \
439439

440440
# the "headers" target installs all the header files in ../include
441441
.PHONY: headers
442-
HEADERS := $(patsubst %,../include/%,$(foreach h,$(HEADERS),$(notdir $h)))
442+
HEADERS := $(patsubst %,../include/%,$(foreach h,$(SRCHEADERS),$(notdir $h)))
443443
headers: $(HEADERS)
444444

445445
# install header files as part of the build
@@ -503,7 +503,11 @@ pythonclean:
503503
find . -name __pycache__ | xargs -r rm -r
504504
python: $(PYTARGETS)
505505
userspace: python
506-
clean: docclean pythonclean cscopeclean
506+
inclean:
507+
$(RM) $(INFILES)
508+
headersclean:
509+
$(RM) $(HEADERS)
510+
clean: docclean pythonclean cscopeclean inclean headersclean
507511

508512
# This is the gateway into the crazy world of "kbuild", the linux 2.6 system
509513
# for building kernel modules. Other kernel module build styles need to be

0 commit comments

Comments
 (0)