ac_subst_files=''
ac_user_opts='
enable_option_checking
-with_mingw_progs
+with_cross_bootstrap
with_windows_headers
with_windows_libs
'
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --without-mingw-progs do not build programs using the mingw toolchain
- (useful for cross-compiling)
+ --with-cross-bootstrap do not build programs using the mingw toolchain or
+ check for mingw libraries (useful for bootstrapping
+ a cross-compiler)
--with-windows-headers=DIR
specify where the windows includes are located
--with-windows-libs=DIR specify where the windows libraries are located
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-# Check whether --with-mingw-progs was given.
-if test "${with_mingw_progs+set}" = set; then :
- withval=$with_mingw_progs;
+# Check whether --with-cross-bootstrap was given.
+if test "${with_cross_bootstrap+set}" = set; then :
+ withval=$with_cross_bootstrap;
else
- with_mingw_progs=yes
+ with_cross_bootstrap=no
fi
fi
+if test "x$with_cross_bootstrap" != "xyes"; then
# Check whether --with-windows-libs was given.
+fi
ac_ext=cpp
ac_cpp='$CXXCPP $CPPFLAGS'
subdirs="$subdirs cygwin cygserver doc"
-if test "x$with_mingw_progs" != xno; then
+if test "x$with_cross_bootstrap" != "xyes"; then
subdirs="$subdirs utils lsaauth"
fi
AC_PROG_CXX
AC_PROG_CPP
AC_LANG(C)
-AC_ARG_WITH([mingw-progs],[AS_HELP_STRING([--without-mingw-progs],[do not build programs using the mingw toolchain (useful for cross-compiling)])],[],[with_mingw_progs=yes])
+AC_ARG_WITH([cross-bootstrap],[AS_HELP_STRING([--with-cross-bootstrap],[do not build programs using the mingw toolchain or check for mingw libraries (useful for bootstrapping a cross-compiler)])],[],[with_cross_bootstrap=no])
AC_WINDOWS_HEADERS
-AC_WINDOWS_LIBS
+if test "x$with_cross_bootstrap" != "xyes"; then
+ AC_WINDOWS_LIBS
+fi
AC_LANG(C++)
AC_CYGWIN_INCLUDES
AC_CONFIG_SUBDIRS(cygwin cygserver doc)
-if test "x$with_mingw_progs" != xno; then
+if test "x$with_cross_bootstrap" != "xyes"; then
AC_CONFIG_SUBDIRS([utils lsaauth])
fi
fi
+if test "x$with_cross_bootstrap" != "xyes"; then
# Check whether --with-windows-libs was given.
+fi
ac_ext=cpp
ac_cpp='$CXXCPP $CPPFLAGS'
dnl
dnl Process this file with autoconf to produce a configure script.
-AC_PREREQ(2.59)
+AC_PREREQ([2.59])
AC_INIT([Cygwin Cygserver],[0],[cygwin@cygwin.com],[cygwin],[https://cygwin.com])
AC_CONFIG_SRCDIR(cygserver.cc)
AC_CONFIG_AUX_DIR(..)
AC_LANG(C)
AC_WINDOWS_HEADERS
-AC_WINDOWS_LIBS
+if test "x$with_cross_bootstrap" != "xyes"; then
+ AC_WINDOWS_LIBS
+fi
AC_LANG(C++)
])
AC_CONFIGURE_ARGS
-AC_OUTPUT(Makefile)
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT
fi
+if test "x$with_cross_bootstrap" != "xyes"; then
# Check whether --with-windows-libs was given.
+fi
ac_ext=cpp
ac_cpp='$CXXCPP $CPPFLAGS'
dnl
dnl Process this file with autoconf to produce a configure script.
-AC_PREREQ(2.59)
+AC_PREREQ([2.59])
AC_INIT([Cygwin DLL],[0],[cygwin@cygwin.com],[cygwin],[https://cygwin.com])
AC_CONFIG_SRCDIR(Makefile.in)
AC_CONFIG_HEADER(config.h)
AC_LANG(C)
AC_WINDOWS_HEADERS
-AC_WINDOWS_LIBS
+if test "x$with_cross_bootstrap" != "xyes"; then
+ AC_WINDOWS_LIBS
+fi
AC_LANG(C++)
DIN_FILE="x86_64.din"
TLSOFFSETS_H="tlsoffsets64.h"
;;
- *) AC_MSG_ERROR(Invalid target processor \"$target_cpu\") ;;
+ *) AC_MSG_ERROR([Invalid target processor "$target_cpu"]) ;;
esac
AC_CONFIGURE_ARGS
AC_SUBST(DEF_DLL_ENTRY)
AC_SUBST(DIN_FILE)
AC_SUBST(TLSOFFSETS_H)
-AC_OUTPUT(Makefile)
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT