Skip to content

Commit

Permalink
* common.mk (distclean-enc, realclean-enc): do not call clean of
Browse files Browse the repository at this point in the history
  enc.mk twice or more.

* enc/depend (cleanobjs): added deffile.

* lib/mkmf.rb (create_makefile): removes deffile at clean instead
  of distclean.

* win32/Makefile.sub (miniruby, LIBRUBY_SO): removes lib and exp
  files.

* win32/Makefile.sub (clean, distclean): have moved to common.mk.

* win32/rmdirs.bat: omits `not empty' message.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21790 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
  • Loading branch information
nobu committed Jan 27, 2009
1 parent 882cb2e commit c938de2
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 16 deletions.
19 changes: 18 additions & 1 deletion ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,20 @@
Tue Jan 27 11:03:52 2009 Nobuyoshi Nakada <[email protected]>

* common.mk (distclean-enc, realclean-enc): do not call clean of
enc.mk twice or more.

* enc/depend (cleanobjs): added deffile.

* lib/mkmf.rb (create_makefile): removes deffile at clean instead
of distclean.

* win32/Makefile.sub (miniruby, LIBRUBY_SO): removes lib and exp
files.

* win32/Makefile.sub (clean, distclean): have moved to common.mk.

* win32/rmdirs.bat: omits `not empty' message.

Tue Jan 27 10:15:33 2009 Nobuyoshi Nakada <[email protected]>

* transcode.c (struct rb_transcoding): added ary member for debug.
Expand Down Expand Up @@ -46,7 +63,7 @@ Sun Jan 25 12:02:56 2009 Nobuyoshi Nakada <[email protected]>

Sun Jan 25 11:50:20 2009 Nobuyoshi Nakada <[email protected]>

* lib/mkmf.rb (create_makefile):fixed the variables order because
* lib/mkmf.rb (create_makefile): fixed the variables order because
converter proc refers the separator.

Sun Jan 25 11:25:10 2009 Nobuyoshi Nakada <[email protected]>
Expand Down
9 changes: 4 additions & 5 deletions common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -346,8 +346,6 @@ clean-local::
@$(RM) $(PROGRAM) $(WPROGRAM) miniruby$(EXEEXT) dmyext.$(OBJEXT) $(ARCHFILE) .*.time
@$(RM) *.inc y.tab.c y.output encdb.h transdb.h
clean-ext::
clean-enc:
@-$(MAKE) -f $(ENC_MK) $(MFLAGS) clean
clean-golf:
@$(RM) $(GORUBY)$(EXEEXT) $(GOLFOBJS)
clean-rdoc:
Expand All @@ -360,8 +358,6 @@ distclean-local:: clean-local
@$(RM) config.cache config.log config.status config.status.lineno $(PRELUDES)
@$(RM) *~ *.bak *.stackdump core *.core gmon.out $(PREP)
distclean-ext::
distclean-enc: clean-enc
@-$(MAKE) -f $(ENC_MK) $(MFLAGS) distclean
distclean-golf: clean-golf
@$(RM) $(GOLFPRELUDES)
distclean-rdoc:
Expand All @@ -372,10 +368,13 @@ realclean:: realclean-ext realclean-local realclean-enc realclean-golf realclean
realclean-local:: distclean-local
@$(RM) parse.c parse.h lex.c newline.c revision.h
realclean-ext::
realclean-enc:: distclean-enc
realclean-golf: distclean-golf
realclean-extout: distclean-extout

clean-enc distclean-enc realclean-enc:
@echo $(@:-enc=ing) encodings
@-$(MAKE) -f $(ENC_MK) $(MFLAGS) $(@:-enc=)

check: test test-all

btest: miniruby$(EXEEXT) PHONY
Expand Down
1 change: 1 addition & 0 deletions enc/depend
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
% dependencies = encs + trans
% cleanlibs = Shellwords.shellwords(CONFIG["cleanlibs"] || "")
% cleanobjs = Shellwords.shellwords(CONFIG["cleanobjs"] || "")
% cleanobjs << "$*.def" if deffile
% rule_subst = CONFIG["RULE_SUBST"] || "%s"
% transvpath = rule_subst.dup.sub!(/\{[^{}]+\}/, '$(TRANSVPATH)/') || "enc/trans/%s"
% transvpath_prefix = (rule_subst.dup.sub!(/\{[^{}]+\}/, '{$(TRANSVPATH)}') || "") % ""
Expand Down
4 changes: 2 additions & 2 deletions lib/mkmf.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1599,7 +1599,7 @@ def create_makefile(target, srcprefix = nil)
makedef = %{-e "puts 'EXPORTS', '#{EXPORT_PREFIX}Init_$(TARGET)'"}
end
if makedef
$distcleanfiles << '$(DEFFILE)'
$cleanfiles << '$(DEFFILE)'
origdef = deffile
deffile = "$(TARGET)-$(arch).def"
end
Expand Down Expand Up @@ -1649,7 +1649,7 @@ def create_makefile(target, srcprefix = nil)
mfile.print "
TARGET_SO = #{($extout ? '$(RUBYARCHDIR)/' : '')}$(DLLIB)
CLEANLIBS = #{n}.#{CONFIG['DLEXT']} #{config_string('cleanlibs') {|t| t.gsub(/\$\*/) {n}}}
CLEANOBJS = *.#{$OBJEXT} #{config_string('cleanobjs') {|t| t.gsub(/\$\*/, '$(TARGET)')}} *.bak
CLEANOBJS = *.#{$OBJEXT} #{config_string('cleanobjs') {|t| t.gsub(/\$\*/, "$(TARGET)#{deffile ? '-$(arch)': ''}")} if target} *.bak
all: #{$extout ? "install" : target ? "$(DLLIB)" : "Makefile"}
static: $(STATIC_LIB)#{$extout ? " install-rb" : ""}
Expand Down
9 changes: 2 additions & 7 deletions win32/Makefile.sub
Original file line number Diff line number Diff line change
Expand Up @@ -661,6 +661,7 @@ miniruby: miniruby$(EXEEXT)
miniruby$(EXEEXT):
@echo. $(LIBS)
$(PURIFY) $(CC) $(MAINOBJ) $(MINIOBJS) $(COMMONOBJS) $(DMYEXT) $(LIBS) -Fe$@ $(LDFLAGS)
@$(RM) miniruby.lib miniruby.exp
miniruby.exe -v
$(LDSHARED_1)
$(LDSHARED_2)
Expand Down Expand Up @@ -696,6 +697,7 @@ $(LIBRUBY_SO): $(LIBRUBY_A) $(DLDOBJS) $(RUBYDEF) $(RUBY_SO_NAME).res
$(LDSHARED) $(MAINOBJ) $(DLDOBJS) $(LIBRUBY_A) \
$(RUBY_SO_NAME).res $(LIBS) -Fe$@ $(LDFLAGS) \
$(LIBRUBY_DLDFLAGS)
@$(RM) dummy.lib dummy.exp
$(LDSHARED_0)
$(LDSHARED_1)
$(LDSHARED_2)
Expand All @@ -712,9 +714,6 @@ clean-local::
@$(RM) $(RUBY_INSTALL_NAME).res $(RUBYW_INSTALL_NAME).res $(RUBY_SO_NAME).res
@$(RM) *.map *.pdb *.ilk *.exp $(RUBYDEF) ext\ripper\y.output

clean:
@-rmdir $(EXTOUT:/=\)\$(arch)

distclean-local::
@$(RM) ext\config.cache $(RBCONFIG:/=\) $(CONFIG_H:/=\)
@$(RM) $(RUBY_INSTALL_NAME).rc $(RUBYW_INSTALL_NAME).rc $(RUBY_SO_NAME).rc
Expand All @@ -724,10 +723,6 @@ distclean-local::
distclean-rdoc:
@-$(RMALL) $(RDOCOUT:/=\)

distclean:
@-rmdir $(EXTOUT:/=\)\$(arch)
@-rmdir $(EXTOUT:/=\)

clean-ext distclean-ext realclean-ext::
!if "$(EXTS)" != ""
@for %I in ($(EXTS)) \
Expand Down
2 changes: 1 addition & 1 deletion win32/rmdirs.bat
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if "%1" == "" goto :end
if not exist "%dir%\." goto :begin
if "%dir%" == "." goto :begin
if "%dir%" == ".." goto :begin
rd "%dir%" || goto :begin
rd "%dir%" 2> nul || goto :begin
:trim_sep
if not /%dir:~-1%/ == /\/ goto :trim_base
set dir=%dir:~0,-1%
Expand Down

0 comments on commit c938de2

Please sign in to comment.