# which are marked as Phony.
#
.PHONY: all dynamic bytecodelib bytecodelib-install
# which are marked as Phony.
#
.PHONY: all dynamic bytecodelib bytecodelib-install
-.PHONY: clean distclean install test bytecode prdirs
+.PHONY: clean cleandeps distclean install test bytecode prdirs
###########################################################################
# Miscellaneous paths and commands:
###########################################################################
# Miscellaneous paths and commands:
#---------------------------------------------------------
ifdef DIRS
#---------------------------------------------------------
ifdef DIRS
-all install clean test bytecode ::
+all install clean cleandeps test bytecode ::
$(VERB) for dir in ${DIRS}; do \
(cd $$dir; $(MAKE) $@) || exit 1; \
done
$(VERB) for dir in ${DIRS}; do \
(cd $$dir; $(MAKE) $@) || exit 1; \
done
all :: $(addsuffix /.makeall , $(PARALLEL_DIRS))
install :: $(addsuffix /.makeinstall , $(PARALLEL_DIRS))
clean :: $(addsuffix /.makeclean , $(PARALLEL_DIRS))
all :: $(addsuffix /.makeall , $(PARALLEL_DIRS))
install :: $(addsuffix /.makeinstall , $(PARALLEL_DIRS))
clean :: $(addsuffix /.makeclean , $(PARALLEL_DIRS))
+cleandeps:: $(addsuffix /.makecleandeps, $(PARALLEL_DIRS))
test :: $(addsuffix /.maketest , $(PARALLEL_DIRS))
bytecode :: $(addsuffix /.makebytecode, $(PARALLEL_DIRS))
test :: $(addsuffix /.maketest , $(PARALLEL_DIRS))
bytecode :: $(addsuffix /.makebytecode, $(PARALLEL_DIRS))
-%/.makeall %/.makeinstall %/.makeclean %/.maketest %/.makebytecode:
+%/.makeall %/.makeinstall %/.makeclean %/.makecleandeps %/.maketest \
+ %/.makebytecode:
$(VERB) cd $(@D); $(MAKE) $(subst $(@D)/.make,,$@)
endif
# Handle directories that may or may not exist
ifdef OPTIONAL_DIRS
$(VERB) cd $(@D); $(MAKE) $(subst $(@D)/.make,,$@)
endif
# Handle directories that may or may not exist
ifdef OPTIONAL_DIRS
-all install clean test bytecode ::
+all install clean cleandeps test bytecode ::
$(VERB) for dir in ${OPTIONAL_DIRS}; do \
if [ -d $$dir ]; \
then\
$(VERB) for dir in ${OPTIONAL_DIRS}; do \
if [ -d $$dir ]; \
then\
#
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(MAKECMDGOALS),distclean)
#
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(MAKECMDGOALS),distclean)
+ifneq ($(MAKECMDGOALS),cleandeps)
ifneq ($(SourceDepend),)
-include $(SourceDepend)
endif
endif
endif
ifneq ($(SourceDepend),)
-include $(SourceDepend)
endif
endif
endif
+endif
+
+cleandeps::
+ $(VERB) rm -f $(SourceDepend)
+
# which are marked as Phony.
#
.PHONY: all dynamic bytecodelib bytecodelib-install
# which are marked as Phony.
#
.PHONY: all dynamic bytecodelib bytecodelib-install
-.PHONY: clean distclean install test bytecode prdirs
+.PHONY: clean cleandeps distclean install test bytecode prdirs
###########################################################################
# Miscellaneous paths and commands:
###########################################################################
# Miscellaneous paths and commands:
#---------------------------------------------------------
ifdef DIRS
#---------------------------------------------------------
ifdef DIRS
-all install clean test bytecode ::
+all install clean cleandeps test bytecode ::
$(VERB) for dir in ${DIRS}; do \
(cd $$dir; $(MAKE) $@) || exit 1; \
done
$(VERB) for dir in ${DIRS}; do \
(cd $$dir; $(MAKE) $@) || exit 1; \
done
all :: $(addsuffix /.makeall , $(PARALLEL_DIRS))
install :: $(addsuffix /.makeinstall , $(PARALLEL_DIRS))
clean :: $(addsuffix /.makeclean , $(PARALLEL_DIRS))
all :: $(addsuffix /.makeall , $(PARALLEL_DIRS))
install :: $(addsuffix /.makeinstall , $(PARALLEL_DIRS))
clean :: $(addsuffix /.makeclean , $(PARALLEL_DIRS))
+cleandeps:: $(addsuffix /.makecleandeps, $(PARALLEL_DIRS))
test :: $(addsuffix /.maketest , $(PARALLEL_DIRS))
bytecode :: $(addsuffix /.makebytecode, $(PARALLEL_DIRS))
test :: $(addsuffix /.maketest , $(PARALLEL_DIRS))
bytecode :: $(addsuffix /.makebytecode, $(PARALLEL_DIRS))
-%/.makeall %/.makeinstall %/.makeclean %/.maketest %/.makebytecode:
+%/.makeall %/.makeinstall %/.makeclean %/.makecleandeps %/.maketest \
+ %/.makebytecode:
$(VERB) cd $(@D); $(MAKE) $(subst $(@D)/.make,,$@)
endif
# Handle directories that may or may not exist
ifdef OPTIONAL_DIRS
$(VERB) cd $(@D); $(MAKE) $(subst $(@D)/.make,,$@)
endif
# Handle directories that may or may not exist
ifdef OPTIONAL_DIRS
-all install clean test bytecode ::
+all install clean cleandeps test bytecode ::
$(VERB) for dir in ${OPTIONAL_DIRS}; do \
if [ -d $$dir ]; \
then\
$(VERB) for dir in ${OPTIONAL_DIRS}; do \
if [ -d $$dir ]; \
then\
#
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(MAKECMDGOALS),distclean)
#
ifneq ($(MAKECMDGOALS),clean)
ifneq ($(MAKECMDGOALS),distclean)
+ifneq ($(MAKECMDGOALS),cleandeps)
ifneq ($(SourceDepend),)
-include $(SourceDepend)
endif
endif
endif
ifneq ($(SourceDepend),)
-include $(SourceDepend)
endif
endif
endif
+endif
+
+cleandeps::
+ $(VERB) rm -f $(SourceDepend)
+