Lines 18961-19097
fi
Link Here
|
18961 |
# ------------- mkdir required for win32 compatibility ------------ |
18961 |
# ------------- mkdir required for win32 compatibility ------------ |
18962 |
# WIN32 mkdir takes only one argument, POSIX takes two. |
18962 |
# WIN32 mkdir takes only one argument, POSIX takes two. |
18963 |
# #include "misc.h" where mkdir is required. |
18963 |
# #include "misc.h" where mkdir is required. |
18964 |
# =========================================================================== |
|
|
18965 |
# http://www.gnu.org/software/autoconf-archive/ax_func_mkdir.html |
18966 |
# =========================================================================== |
18967 |
# |
18968 |
# SYNOPSIS |
18969 |
# |
18970 |
# AX_FUNC_MKDIR |
18971 |
# |
18972 |
# DESCRIPTION |
18973 |
# |
18974 |
# Check whether mkdir() is mkdir or _mkdir, and whether it takes one or |
18975 |
# two arguments. |
18976 |
# |
18977 |
# This macro can define HAVE_MKDIR, HAVE__MKDIR, and MKDIR_TAKES_ONE_ARG, |
18978 |
# which are expected to be used as follows: |
18979 |
# |
18980 |
# #if HAVE_MKDIR |
18981 |
# # if MKDIR_TAKES_ONE_ARG |
18982 |
# /* MinGW32 */ |
18983 |
# # define mkdir(a, b) mkdir(a) |
18984 |
# # endif |
18985 |
# #else |
18986 |
# # if HAVE__MKDIR |
18987 |
# /* plain Windows 32 */ |
18988 |
# # define mkdir(a, b) _mkdir(a) |
18989 |
# # else |
18990 |
# # error "Don't know how to create a directory on this system." |
18991 |
# # endif |
18992 |
# #endif |
18993 |
# |
18994 |
# LICENSE |
18995 |
# |
18996 |
# Copyright (c) 2008 Alexandre Duret-Lutz <adl@gnu.org> |
18997 |
# |
18998 |
# This program is free software; you can redistribute it and/or modify it |
18999 |
# under the terms of the GNU General Public License as published by the |
19000 |
# Free Software Foundation; either version 2 of the License, or (at your |
19001 |
# option) any later version. |
19002 |
# |
19003 |
# This program is distributed in the hope that it will be useful, but |
19004 |
# WITHOUT ANY WARRANTY; without even the implied warranty of |
19005 |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General |
19006 |
# Public License for more details. |
19007 |
# |
19008 |
# You should have received a copy of the GNU General Public License along |
19009 |
# with this program. If not, see <http://www.gnu.org/licenses/>. |
19010 |
# |
19011 |
# As a special exception, the respective Autoconf Macro's copyright owner |
19012 |
# gives unlimited permission to copy, distribute and modify the configure |
19013 |
# scripts that are the output of Autoconf when processing the Macro. You |
19014 |
# need not follow the terms of the GNU General Public License when using |
19015 |
# or distributing such scripts, even though portions of the text of the |
19016 |
# Macro appear in them. The GNU General Public License (GPL) does govern |
19017 |
# all other use of the material that constitutes the Autoconf Macro. |
19018 |
# |
19019 |
# This special exception to the GPL applies to versions of the Autoconf |
19020 |
# Macro released by the Autoconf Archive. When you make and distribute a |
19021 |
# modified version of the Autoconf Macro, you may extend this special |
19022 |
# exception to the GPL to apply to your modified version as well. |
19023 |
|
18964 |
|
19024 |
#serial 4 |
|
|
19025 |
|
18965 |
|
19026 |
# This is what autoupdate's m4 run will expand. It fires |
18966 |
$as_echo "#define HAVE_MKDIR 1" >>confdefs.h |
19027 |
# the warning (with _au_warn_XXX), outputs it into the |
|
|
19028 |
# updated configure.ac (with AC_DIAGNOSE), and then outputs |
19029 |
# the replacement expansion. |
19030 |
|
19031 |
|
19032 |
# This is an auxiliary macro that is also run when |
19033 |
# autoupdate runs m4. It simply calls m4_warning, but |
19034 |
# we need a wrapper so that each warning is emitted only |
19035 |
# once. We break the quoting in m4_warning's argument in |
19036 |
# order to expand this macro's arguments, not AU_DEFUN's. |
19037 |
|
19038 |
|
19039 |
# Finally, this is the expansion that is picked up by |
19040 |
# autoconf. It tells the user to run autoupdate, and |
19041 |
# then outputs the replacement expansion. We do not care |
19042 |
# about autoupdate's warning because that contains |
19043 |
# information on what to do *after* running autoupdate. |
19044 |
|
19045 |
|
19046 |
|
19047 |
|
19048 |
for ac_func in mkdir _mkdir |
19049 |
do : |
19050 |
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
19051 |
ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
19052 |
if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
19053 |
cat >>confdefs.h <<_ACEOF |
19054 |
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
19055 |
_ACEOF |
19056 |
|
19057 |
fi |
19058 |
done |
19059 |
|
19060 |
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mkdir takes one argument" >&5 |
19061 |
$as_echo_n "checking whether mkdir takes one argument... " >&6; } |
19062 |
if ${ac_cv_mkdir_takes_one_arg+:} false; then : |
19063 |
$as_echo_n "(cached) " >&6 |
19064 |
else |
19065 |
cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
19066 |
/* end confdefs.h. */ |
19067 |
|
19068 |
#include <sys/stat.h> |
19069 |
#if HAVE_UNISTD_H |
19070 |
# include <unistd.h> |
19071 |
#endif |
19072 |
|
19073 |
int |
19074 |
main () |
19075 |
{ |
19076 |
mkdir ("."); |
19077 |
; |
19078 |
return 0; |
19079 |
} |
19080 |
_ACEOF |
19081 |
if ac_fn_c_try_compile "$LINENO"; then : |
19082 |
ac_cv_mkdir_takes_one_arg=yes |
19083 |
else |
19084 |
ac_cv_mkdir_takes_one_arg=no |
19085 |
fi |
19086 |
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
19087 |
fi |
19088 |
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mkdir_takes_one_arg" >&5 |
19089 |
$as_echo "$ac_cv_mkdir_takes_one_arg" >&6; } |
19090 |
if test x"$ac_cv_mkdir_takes_one_arg" = xyes; then |
19091 |
|
19092 |
$as_echo "#define MKDIR_TAKES_ONE_ARG 1" >>confdefs.h |
19093 |
|
19094 |
fi |
19095 |
|
18967 |
|
19096 |
|
18968 |
|
19097 |
# ------------- Type used for "Coord" type ------------------- |
18969 |
# ------------- Type used for "Coord" type ------------------- |