X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/9e69cb054d5c124bdf913c82453518ac4d9d6d53..c38918db05bb8df4619bff27d04a0dc48202b647:/config.bat diff --git a/config.bat b/config.bat index aac4e108b0..e480a4b9bc 100644 --- a/config.bat +++ b/config.bat @@ -2,7 +2,8 @@ rem ---------------------------------------------------------------------- rem Configuration script for MSDOS rem Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2003 -rem 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +rem 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, +rem Inc. rem This file is part of GNU Emacs. @@ -38,6 +39,7 @@ set X11= set nodebug= set djgpp_ver= set sys_malloc= +set libxml= if "%1" == "" goto usage rem ---------------------------------------------------------------------- rem See if their environment is large enough. We need 28 bytes. @@ -154,9 +156,9 @@ rm -f epaths.tmp rem Create "config.h" rm -f config.h2 config.tmp -sed -e '' config.in > config.tmp +sed -e '' ../autogen/config.in > config.tmp if "%X11%" == "" goto src4 -sed -f ../msdos/sed2x.inp config.tmp +sed -f ../msdos/sed2x.inp < ..\autogen\config.in > config.tmp :src4 sed -f ../msdos/sed2v2.inp config.h2 Rem See if DECL_ALIGN can be supported with this GCC @@ -175,6 +177,24 @@ rem The following line disables DECL_ALIGN which in turn disables USE_LSB_TAG rem For details see lisp.h where it defines USE_LSB_TAG echo #define NO_DECL_ALIGN >>config.h2 :alignOk +Rem See if they have libxml2 later than v2.2.0 installed +Echo Checking whether libxml2 v2.2.1 or later is installed ... +rm -f junk.c junk.o junk junk.exe +rem Use djecho here because we need to quote brackets +djecho "#include " >junk.c +djecho "int main()" >>junk.c +djecho "{return (LIBXML_VERSION > 20200 ? 0 : 1);}" >>junk.c +redir -o Nul -eo gcc -I/dev/env/DJDIR/include/libxml2 -o junk junk.c +if not exist junk Goto xmlDone +if not exist junk.exe coff2exe junk +junk +If ErrorLevel 1 Goto xmlDone +Echo Configuring with libxml2 ... +sed -e "/#undef HAVE_LIBXML2/s/^.*$/#define HAVE_LIBXML2 1/" config.h3 +mv config.h3 config.h2 +set libxml=1 +:xmlDone +rm -f junk.c junk junk.exe Rem See if they requested a SYSTEM_MALLOC build if "%sys_malloc%" == "" Goto cfgDone rm -f config.tmp @@ -213,6 +233,12 @@ sed -e "/^CFLAGS *=/s/ *-gcoff//" makefile.tmp sed -e "/^LDFLAGS *=/s/=/=-s/" Makefile rm -f makefile.tmp :src6 + +if "%libxml%" == "" goto src7 +sed -e "/^LIBXML2_LIBS *=/s/=/= -lxml2 -lz -liconv/" makefile.tmp +sed -e "/^LIBXML2_CFLAGS *=/s|=|= -I/dev/env/DJDIR/include/libxml2|" Makefile +rm -f makefile.tmp +:src7 cd .. rem ---------------------------------------------------------------------- Echo Configuring the library source directory... @@ -248,8 +274,32 @@ Rem supports long file names but DJGPP does not for %%d in (emacs lispref lispintro lispintr misc) do sed -f ../msdos/sed6.inp < %%d\Makefile.in > %%d\Makefile cd .. rem ---------------------------------------------------------------------- +Echo Configuring the lib directory... +If Exist c++defs.h update c++defs.h cxxdefs.h +cd lib +Rem Rename files like djtar on plain DOS filesystem would. +If Exist c++defs.h update c++defs.h cxxdefs.h +If Exist getopt.in.h update getopt.in.h getopt.in-h +If Exist stdbool.in.h update stdbool.in.h stdbool.in-h +If Exist stddef.in.h update stddef.in.h stddef.in-h +If Exist stdint.in.h update stdint.in.h stdint.in-h +If Exist stdio.in.h update stdio.in.h stdio.in-h +If Exist stdlib.in.h update stdlib.in.h stdlib.in-h +If Exist sys_stat.in.h update sys_stat.in.h sys_stat.in-h +If Exist time.in.h update time.in.h time.in-h +If Exist unistd.in.h update unistd.in.h unistd.in-h +sed -f ../msdos/sedlibcf.inp < ..\autogen\Makefile.in > makefile.tmp +sed -f ../msdos/sedlibmk.inp < makefile.tmp > Makefile +rm -f makefile.tmp +Rem Create .Po files for new files in lib/ +If Not Exist deps\stamp mkdir deps +for %%f in (*.c) do @call ..\msdos\depfiles.bat %%f +echo deps-stamp > deps\stamp +cd .. +rem ---------------------------------------------------------------------- Echo Configuring the lisp directory... cd lisp +If Exist gnus\.dir-locals.el update gnus/.dir-locals.el gnus/_dir-locals.el sed -f ../msdos/sedlisp.inp < Makefile.in > Makefile cd .. rem ---------------------------------------------------------------------- @@ -288,7 +338,5 @@ set X11= set nodebug= set djgpp_ver= set sys_malloc= +set libxml= -goto skipArchTag - arch-tag: 2d2fed23-4dc6-4006-a2e4-49daf0031f33 -:skipArchTag