From 9e5b5c79347e78cead061af5ef077c9a6d401bba Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Wed, 15 May 2013 20:06:26 +0300 Subject: [PATCH] Fixed nt/mingw-cfg.site to pass the configure step. --- nt/gnulib.mk | 36 +++++++++++++++++++++++++++++++++++- nt/inc/ms-w32.h | 7 +++---- nt/mingw-cfg.site | 7 ++++++- 3 files changed, 44 insertions(+), 6 deletions(-) diff --git a/nt/gnulib.mk b/nt/gnulib.mk index d0fa88239dc..3450baaf9bd 100644 --- a/nt/gnulib.mk +++ b/nt/gnulib.mk @@ -43,7 +43,7 @@ # the same distribution terms as the rest of that program. # # Generated by gnulib-tool. -# Reproduce by: gnulib-tool --import --dir=. --lib=libgnu --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=tests --aux-dir=build-aux --avoid=dup --avoid=errno --avoid=fchdir --avoid=fcntl --avoid=fstat --avoid=malloc-posix --avoid=msvc-inval --avoid=msvc-nothrow --avoid=open --avoid=openat-die --avoid=opendir --avoid=raise --avoid=save-cwd --avoid=select --avoid=sigprocmask --avoid=sys_types --avoid=threadlib --makefile-name=gnulib.mk --conditional-dependencies --no-libtool --macro-prefix=gl --no-vc-files alloca-opt c-ctype c-strcase careadlinkat close-stream crypto/md5 crypto/sha1 crypto/sha256 crypto/sha512 dtoastr dtotimespec dup2 environ execinfo faccessat fcntl-h fdatasync fdopendir filemode fstatat fsync getloadavg getopt-gnu gettime gettimeofday ignore-value intprops largefile lstat manywarnings memrchr mktime pselect pthread_sigmask putenv readlink readlinkat sig2str socklen stat-time stdalign stdarg stdbool stdio strftime strtoimax strtoumax symlink sys_stat sys_time time timer-time timespec-add timespec-sub unsetenv utimens warnings +# Reproduce by: gnulib-tool --import --dir=. --lib=libgnu --source-base=lib --m4-base=m4 --doc-base=doc --tests-base=tests --aux-dir=build-aux --avoid=dup --avoid=fchdir --avoid=fcntl --avoid=fstat --avoid=malloc-posix --avoid=msvc-inval --avoid=msvc-nothrow --avoid=open --avoid=openat-die --avoid=opendir --avoid=raise --avoid=save-cwd --avoid=select --avoid=sigprocmask --avoid=sys_types --avoid=threadlib --makefile-name=gnulib.mk --conditional-dependencies --no-libtool --macro-prefix=gl --no-vc-files alloca-opt c-ctype c-strcase careadlinkat close-stream crypto/md5 crypto/sha1 crypto/sha256 crypto/sha512 dtoastr dtotimespec dup2 environ execinfo faccessat fcntl-h fdatasync fdopendir filemode fstatat fsync getloadavg getopt-gnu gettime gettimeofday ignore-value intprops largefile lstat manywarnings memrchr mktime pselect pthread_sigmask putenv qacl readlink readlinkat sig2str socklen stat-time stdalign stdarg stdbool stdio strftime strtoimax strtoumax symlink sys_stat sys_time time timer-time timespec-add timespec-sub unsetenv utimens warnings MOSTLYCLEANFILES += core *.stackdump @@ -164,6 +164,40 @@ EXTRA_libgnu_a_SOURCES += dup2.c ## end gnulib module dup2 +## begin gnulib module errno + +BUILT_SOURCES += $(ERRNO_H) + +# We need the following in order to create when the system +# doesn't have one that is POSIX compliant. +if GL_GENERATE_ERRNO_H +errno.h: errno.in.h $(top_builddir)/config.status + $(AM_V_GEN)rm -f $@-t $@ && \ + { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ + sed -e 's|@''GUARD_PREFIX''@|GL|g' \ + -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ + -e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \ + -e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \ + -e 's|@''NEXT_ERRNO_H''@|$(NEXT_ERRNO_H)|g' \ + -e 's|@''EMULTIHOP_HIDDEN''@|$(EMULTIHOP_HIDDEN)|g' \ + -e 's|@''EMULTIHOP_VALUE''@|$(EMULTIHOP_VALUE)|g' \ + -e 's|@''ENOLINK_HIDDEN''@|$(ENOLINK_HIDDEN)|g' \ + -e 's|@''ENOLINK_VALUE''@|$(ENOLINK_VALUE)|g' \ + -e 's|@''EOVERFLOW_HIDDEN''@|$(EOVERFLOW_HIDDEN)|g' \ + -e 's|@''EOVERFLOW_VALUE''@|$(EOVERFLOW_VALUE)|g' \ + < $(srcdir)/errno.in.h; \ + } > $@-t && \ + mv $@-t $@ +else +errno.h: $(top_builddir)/config.status + rm -f $@ +endif +MOSTLYCLEANFILES += errno.h errno.h-t + +EXTRA_DIST += errno.in.h + +## end gnulib module errno + ## begin gnulib module euidaccess if gl_GNULIB_ENABLED_euidaccess diff --git a/nt/inc/ms-w32.h b/nt/inc/ms-w32.h index 24078f9a344..29c8e383893 100644 --- a/nt/inc/ms-w32.h +++ b/nt/inc/ms-w32.h @@ -346,11 +346,10 @@ extern struct tm *localtime_r (time_t const * restrict, struct tm * restrict); #define ENOTSUP ENOSYS #endif -/* WINDOWSNT doesn't define EOPNOTSUPP, and we don't have - 'configure' working yet so we can't rely on the Gnulib replacement - errno.h defining EOPNOTSUPP. Work around the problem by defining - it here. */ +/* In case lib/errno.h is not used. */ +#ifndef EOPNOTSUPP #define EOPNOTSUPP 130 +#endif #ifdef _MSC_VER typedef int sigset_t; diff --git a/nt/mingw-cfg.site b/nt/mingw-cfg.site index 78bfa2bb758..8faf8e0dafe 100644 --- a/nt/mingw-cfg.site +++ b/nt/mingw-cfg.site @@ -4,8 +4,13 @@ # We want to use getopt.h from gnulib ac_cv_header_getopt_h=no -# Implemented in w32.c +# ACL functions are implemented in w32.c +ac_cv_search_acl_get_file="none required" +ac_cv_func_acl_get_file=yes ac_cv_func_acl_set_file=yes +ac_cv_func_acl_free=yes +ac_cv_func_acl_from_text=yes +gl_cv_func_working_acl_get_file=yes # Autoconf's test program is not smart enough, and fails to detect gethostname ac_cv_func_gethostname=yes # Implemented as sys_select in w32proc.c -- 2.11.4.GIT