Skip to content

Commit

Permalink
Win32: Update clean commands for bundled gems
Browse files Browse the repository at this point in the history
  • Loading branch information
nobu committed Dec 27, 2024
1 parent e109400 commit adbbc91
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions win32/Makefile.sub
Original file line number Diff line number Diff line change
Expand Up @@ -1281,10 +1281,19 @@ distclean-local::
-$(Q)$(RMDIRS) $(arch_hdrdir:/=\)\ruby
-$(Q)$(RMDIR) win32

.bundle/clean:: .bundle/clean.sub
.bundle/distclean:: .bundle/distclean.sub
.bundle/realclean:: .bundle/realclean.sub

.bundle/clean.sub:: ext/clean.mk
.bundle/distclean.sub:: ext/distclean.mk
.bundle/realclean.sub:: ext/realclean.mk

ext/clean.mk ext/distclean.mk ext/realclean.mk::
$(Q)if exist $(EXTS_MK) $(MAKE) -k -f $(EXTS_MK) top_srcdir=$(srcdir) $(*F)

ext/clean gems/clean ext/distclean gems/distclean ext/realclean gems/realclean::
ext/clean.sub ext/distclean.sub ext/realclean.sub \
.bundle/clean.sub .bundle/distclean.sub .bundle/realclean.sub::
$(Q)cd $(@D) 2>nul && (for /R $(EXTS) %I in (.) \
do $(Q)if exist %I\Makefile ( \
cd %I && ( \
Expand All @@ -1297,11 +1306,14 @@ ext/clean gems/clean ext/distclean gems/distclean ext/realclean gems/realclean::
$(RMDIRS) %I \
))) || @

ext/distclean gems/distclean ext/realclean gems/realclean::
ext/distclean ext/realclean .bundle/distclean .bundle/realclean::
$(Q)cd $(@D) 2>nul && (for /R $(EXTS) %I in (exts.mk*) \
do $(Q)(del %I & rmdir %~dpI)) || @
-$(Q)rmdir $(@D) 2> nul || @

.bundle/realclean::
@$(RMALL) $(tooldir)/bunlder/*.lock $(srcdir)/.bundle

gc/clean gc/distclean gc/realclean::
- for /D %G in (gc\*) do (pushd %G && $(MAKE) TARGET_SO_DIR=./ $(@F) & popd) || $(NULLCMD)
gc/distclean gc/realclean::
Expand Down

0 comments on commit adbbc91

Please sign in to comment.