## Intel 386 machines where we don't care about the manufacturer.
i[3456]86-*-* )
case "${canonical}" in
- *-cygwin ) opsys=cygwin ;;
*-darwin* ) opsys=darwin ;;
+ *-mingw32 )
+ opsys=mingw32
+ # MinGW overrides and adds some system headers in nt/inc.
+ GCC_TEST_OPTIONS="-I $srcdir/nt/inc"
+ ;;
*-sysv4.2uw* ) opsys=unixware ;;
*-sysv5uw* ) opsys=unixware ;;
*-sysv5OpenUNIX* ) opsys=unixware ;;
[AC_MSG_ERROR([No resource compiler found.])])
W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
- W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
- W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
- W32_RES="emacs.res"
- # Tell the linker that emacs.res is an object (which we compile from
- # the rc file), not a linker script.
- W32_RES_LINK="-Wl,emacs.res"
+ EMACSRES="emacs.res"
+ case "$canonical" in
+ x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;;
+ *) EMACS_MANIFEST="emacs-x86.manifest" ;;
+ esac
+ if test "${opsys}" = "cygwin"; then
+ W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
+ W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
+ # Tell the linker that emacs.res is an object (which we compile from
+ # the rc file), not a linker script.
- W32_RES_LINK="-Wl,-bpe-i386 -Wl,emacs.res"
++ W32_RES_LINK="-Wl,emacs.res"
+ else
+ W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o"
+ W32_OBJ="$W32_OBJ w32notify.o"
+ W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
+ W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10"
+ W32_RES_LINK="\$(EMACSRES)"
+ CLIENTRES="emacsclient.res"
+ CLIENTW="emacsclientw\$(EXEEXT)"
+ FIRSTFILE_OBJ=firstfile.o
+ NTDIR=nt
+ CM_OBJ=
+ LIBS_ECLIENT="-lcomctl32"
+ LIB_WSOCK32="-lwsock32"
+ NTLIB="ntlib.$ac_objext"
+ XARGS_LIMIT="-s 10000"
+ fi
fi
AC_SUBST(W32_OBJ)
AC_SUBST(W32_LIBS)
*) LD_SWITCH_SYSTEM_TEMACS= ;;
esac
+ if test x$ac_enable_profiling != x ; then
+ case $opsys in
+ *freebsd | gnu-linux) ;;
+ *) LD_SWITCH_SYSTEM_TEMACS="$LD_SWITCH_SYSTEM_TEMACS -pg" ;;
+ esac
+ fi
+
AC_SUBST(LD_SWITCH_SYSTEM_TEMACS)
+## MinGW-specific post-link processing of temacs.
+TEMACS_POST_LINK=":"
+ADDSECTION=
+EMACS_HEAPSIZE=
+if test "${opsys}" = "mingw32"; then
+ TEMACS_POST_LINK="\$(MINGW_TEMACS_POST_LINK)"
+ ADDSECTION="../nt/addsection\$(EXEEXT)"
+ ## Preload heap size of temacs.exe in MB.
+ case "$canonical" in
+ x86_64-*-*) EMACS_HEAPSIZE=42 ;;
+ *) EMACS_HEAPSIZE=27 ;;
+ esac
+fi
+
+AC_SUBST(ADDSECTION)
+AC_SUBST(TEMACS_POST_LINK)
+AC_SUBST(EMACS_HEAPSIZE)
+
## Common for all window systems
if test "$window_system" != "none"; then
AC_DEFINE(HAVE_WINDOW_SYSTEM, 1, [Define if you have a window system.])
W32_LIBS=@W32_LIBS@
## emacs.res if HAVE_W32
-W32_RES=@W32_RES@
+EMACSRES = @EMACSRES@
+## emacs-*.manifest if HAVE_W32
+EMACS_MANIFEST = @EMACS_MANIFEST@
## If HAVE_W32, compiler arguments for including
## the resource file in the binary.
- ## Cygwin: -Wl,-b -Wl,pe-i386 -Wl,emacs.res
-## XXX -Wl,-b -Wl,pe-i386 -Wl,emacs.res
++## Cygwin: -Wl,emacs.res
+## MinGW: emacs.res
W32_RES_LINK=@W32_RES_LINK@
## Empty if !HAVE_X_WINDOWS