aboutsummaryrefslogtreecommitdiffstats
path: root/enc/depend
diff options
context:
space:
mode:
Diffstat (limited to 'enc/depend')
-rw-r--r--enc/depend11
1 files changed, 10 insertions, 1 deletions
diff --git a/enc/depend b/enc/depend
index de0e092a00..f5eeafe9dc 100644
--- a/enc/depend
+++ b/enc/depend
@@ -1,4 +1,6 @@
-! encs = (Dir.open($srcdir) {|d| d.grep(/.+\.c\z/)} - BUILTIN_ENCS).each {|e| e.chomp!(".c")}
+! encs = Dir.open($srcdir) {|d| d.grep(/.+\.c\z/)} - BUILTIN_ENCS
+! encs.each {|e| e.chomp!(".c")}
+! encs = encs.sort_by {|e| e.split(/(\d+)/).map {|n| Integer(n) rescue n}}
VPATH = <% %w[$(arch_hdrdir)/ruby $(hdrdir)/ruby $(top_srcdir) $(srcdir)].join(CONFIG["PATH_SEPARATOR"]) %>
@@ -22,3 +24,10 @@ $(ENCSODIR)/<%e%>.$(DLEXT): <%e%>.$(OBJEXT)
! encs.each do |e|
<%e%>.$(OBJEXT): <%e%>.c
! end
+
+clean:
+ $(RM) $(ENCSOS)
+ $(RM) $(ENCOBJS)
+
+distclean: clean
+ $(RM) enc.mk