Permalink
Browse files

* configure.in (RMDIR): use --ignore-fail-on-non-empty if possible.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28708 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
  • Loading branch information...
nobu committed Jul 21, 2010
1 parent 3afa012 commit 6abe539cfc9b91178be7e1d75173165dcf6ca1bc
Showing with 15 additions and 6 deletions.
  1. +3 −1 ChangeLog
  2. +2 −1 Makefile.in
  3. +6 −2 configure.in
  4. +2 −0 enc/Makefile.in
  5. +2 −2 enc/depend
View
@@ -1,4 +1,6 @@
-Thu Jul 22 03:23:03 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
+Thu Jul 22 06:26:48 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * configure.in (RMDIR): use --ignore-fail-on-non-empty if possible.
* configure.in (RUBY_EXTERN): FUNCTION-BODY was missing.
View
@@ -105,6 +105,7 @@ MAKEDIRS = @MKDIR_P@
CP = cp
MV = mv
RM = rm -f
+RMDIR = @RMDIR@
RMDIRS = @RMDIRS@
RMALL = @RMALL@
NM = @NM@
@@ -273,7 +274,7 @@ clean-ext distclean-ext realclean-ext::
done
distclean-ext realclean-ext::
- @-rmdir ext 2> /dev/null || true
+ @-$(RMDIR) ext 2> /dev/null || true
clean-extout:
@-$(RMDIRS) $(EXTOUT) 2> /dev/null || true
View
@@ -361,10 +361,14 @@ AC_USE_SYSTEM_EXTENSIONS
AC_SUBST(RM, ['rm -f'])
AC_SUBST(CP, ['cp'])
RMDIRS='$(top_srcdir)/tool/rmdirs'
+RMDIR=rmdir
mkdir "rmdirs_$$_test" "rmdirs_$$_test/a"
-rmdir -p "rmdirs_$$_test/a" 2>/dev/null &&
-{ test -d "rmdirs_$$_test" || RMDIRS='rmdir -p'; }
+rmdir --ignore-fail-on-non-empty "rmdirs_$$_test" 2>/dev/null &&
+RMDIR='rmdir --ignore-fail-on-non-empty'
+$RMDIR -p "rmdirs_$$_test/a" 2>/dev/null &&
+{ test -d "rmdirs_$$_test" || RMDIRS="$RMDIR -p"; }
rmdir "rmdirs_$$_test/a" "rmdirs_$$_test" 2>/dev/null
+AC_SUBST(RMDIR)
AC_SUBST(RMDIRS)
AC_SUBST(RMALL, ['rm -fr'])
View
@@ -48,6 +48,8 @@ RUBY = $(MINIRUBY)
WORKDIRS = $(ENCSODIR) $(TRANSSODIR) enc enc/trans
RM = @RM@
+RMDIR = @RMDIR@
+RMDIRS = @RMDIRS@
MAKEDIRS = @MAKEDIRS@
.SUFFIXES: .trans
View
@@ -133,11 +133,11 @@ clean:
@$(RM) <%=pathrep[clean]%>
% end
% %w[$(TRANSSODIR) $(ENCSODIR)].each do|dir|
- @-rmdir <%=pathrep[dir]%>
+ @-$(RMDIR) <%=pathrep[dir]%>
% end
clean-srcs:
@$(RM) <%=pathrep['$(TRANSCSRCS)']%>
% %w[enc/trans enc].each do|dir|
- @-rmdir <%=pathrep[dir]%>
+ @-$(RMDIR) <%=pathrep[dir]%>
% end

0 comments on commit 6abe539

Please sign in to comment.