mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Fallback mkdir_p
to as_mkdir_p
Assume `mkdir -p` to be race-free on recent systems. And we do not provide install-sh anyway.
This commit is contained in:
parent
cd94842922
commit
67e54ce408
2 changed files with 11 additions and 11 deletions
13
configure.ac
13
configure.ac
|
@ -32,6 +32,7 @@ m4_include([tool/m4/ruby_func_attribute.m4])dnl
|
|||
m4_include([tool/m4/ruby_mingw32.m4])dnl
|
||||
m4_include([tool/m4/ruby_prepend_option.m4])dnl
|
||||
m4_include([tool/m4/ruby_prog_gnu_ld.m4])dnl
|
||||
m4_include([tool/m4/ruby_prog_makedirs.m4])dnl
|
||||
m4_include([tool/m4/ruby_replace_funcs.m4])dnl
|
||||
m4_include([tool/m4/ruby_replace_type.m4])dnl
|
||||
m4_include([tool/m4/ruby_require_funcs.m4])dnl
|
||||
|
@ -491,17 +492,7 @@ AS_CASE(["$target_os"],
|
|||
AC_PROG_LN_S
|
||||
AC_PROG_MAKE_SET
|
||||
AC_PROG_INSTALL
|
||||
AC_PROG_MKDIR_P
|
||||
AS_IF([test "x$MKDIR_P" = "x -d"], [
|
||||
AS_IF([test x"$as_mkdir_p" != xfalse], [
|
||||
MKDIR_P='mkdir -p'
|
||||
echo "use 'mkdir -p' as MKDIR_P"
|
||||
], [
|
||||
AC_MSG_ERROR([mkdir -p is required])
|
||||
])
|
||||
])
|
||||
MAKEDIRS="$MKDIR_P"
|
||||
AC_SUBST(MAKEDIRS)
|
||||
RUBY_PROG_MAKEDIRS
|
||||
|
||||
AC_CHECK_PROG([DTRACE], [${ac_tool_prefix}dtrace], [${ac_tool_prefix}dtrace])
|
||||
AS_IF([test "$cross_compiling:$ac_cv_prog_DTRACE" = no: -a -n "$ac_tool_prefix"], [
|
||||
|
|
9
tool/m4/ruby_prog_makedirs.m4
Normal file
9
tool/m4/ruby_prog_makedirs.m4
Normal file
|
@ -0,0 +1,9 @@
|
|||
dnl -*- Autoconf -*-
|
||||
m4_defun([RUBY_PROG_MAKEDIRS],
|
||||
[m4_bpatsubst(m4_defn([AC_PROG_MKDIR_P]),
|
||||
[MKDIR_P=\"$ac_install_sh -d\"], [
|
||||
AS_IF([test "x$MKDIR_P" = "xfalse"], [AC_MSG_ERROR([mkdir -p is required])])
|
||||
MKDIR_P="mkdir -p"])
|
||||
]dnl
|
||||
AC_SUBST(MAKEDIRS, ["$MKDIR_P"])
|
||||
)
|
Loading…
Reference in a new issue