@echo off\r
rem ----------------------------------------------------------------------\r
rem Configuration script for MSDOS\r
-rem Copyright (C) 1994-1999, 2001-2015 Free Software Foundation, Inc.\r
+rem Copyright (C) 1994-1999, 2001-2016 Free Software Foundation, Inc.\r
\r
rem This file is part of GNU Emacs.\r
\r
If ErrorLevel 1 Goto xmlDone\r
Echo Configuring with libxml2 ...\r
sed -e "/#undef HAVE_LIBXML2/s/^.*$/#define HAVE_LIBXML2 1/" <config.h2 >config.h3\r
-mv config.h3 config.h2\r
+sed -e "/#define EMACS_CONFIG_FEATURES/s/^.*$/#define EMACS_CONFIG_FEATURES \"LIBXML2\"/" <config.h3 >config.h2\r
set libxml=1\r
:xmlDone\r
rm -f junk.c junk junk.exe\r
\r
rem Create "makefile" from "makefile.in".\r
rm -f Makefile makefile.tmp\r
-copy Makefile.in+lisp.mk+deps.mk makefile.tmp\r
+copy Makefile.in+deps.mk makefile.tmp\r
sed -f ../msdos/sed1v2.inp <makefile.tmp >Makefile\r
rm -f makefile.tmp\r
\r
Echo Configuring the library source directory...\r
cd lib-src\r
sed -f ../msdos/sed3v2.inp <Makefile.in >Makefile\r
+mv Makefile makefile.tmp\r
+sed -n -e "/^AC_INIT/s/[^,]*, \([^,]*\).*/@set emver=\1/p" ../configure.ac > emver.bat\r
+call emver.bat\r
+sed -e "s/@version@/%emver%/g" <makefile.tmp >Makefile\r
if "%X11%" == "" goto libsrc2a\r
mv Makefile makefile.tmp\r
sed -f ../msdos/sed3x.inp <makefile.tmp >Makefile\r
rem ----------------------------------------------------------------------\r
Echo Configuring the doc directory, expect one "File not found" message...\r
cd doc\r
+Rem Rename files like djtar on plain DOS filesystem would.\r
+If Exist emacs\emacsver.texi.in update emacs/emacsver.texi.in emacs/emacsver.in\r
+If Exist man\emacs.1.in update man/emacs.1.in man/emacs.in\r
+If Exist ..\etc\refcards\emacsver.tex.in update ../etc/refcards/emacsver.tex.in ../etc/refcards/emacsver.in\r
Rem The two variants for lispintro below is for when the shell\r
Rem supports long file names but DJGPP does not\r
-for %%d in (emacs lispref lispintro lispintr misc) do sed -f ../msdos/sed6.inp < %%d\Makefile.in > %%d\Makefile\r
+for %%d in (emacs lispref lispintro lispintr misc) do sed -e "s/@version@/%emver%/g" -f ../msdos/sed6.inp < %%d\Makefile.in > %%d\Makefile\r
+Rem produce emacs.1 from emacs.in\r
+If Exist man\emacs.1 goto manOk\r
+sed -e "s/@version@/%emver%/g" -e "s/@PACKAGE_BUGREPORT@/bug-gnu-emacs@gnu.org/g" < man\emacs.in > man\emacs.1\r
+:manOk\r
cd ..\r
rem ----------------------------------------------------------------------\r
Echo Configuring the lib directory...\r
If Exist build-aux\snippet\c++defs.h update build-aux/snippet/c++defs.h build-aux/snippet/cxxdefs.h\r
cd lib\r
Rem Rename files like djtar on plain DOS filesystem would.\r
-If Exist build-aux\snippet\c++defs.h update build-aux/snippet/c++defs.h build-aux/snippet/cxxdefs.h\r
If Exist alloca.in.h update alloca.in.h alloca.in-h\r
If Exist byteswap.in.h update byteswap.in.h byteswap.in-h\r
If Exist dirent.in.h update dirent.in.h dirent.in-h\r
If Exist sys_time.in.h update sys_time.in.h sys_time.in-h\r
If Exist time.in.h update time.in.h time.in-h\r
If Exist unistd.in.h update unistd.in.h unistd.in-h\r
+Rem Only repository has the msdos/autogen directory\r
If Exist Makefile.in sed -f ../msdos/sedlibcf.inp < Makefile.in > makefile.tmp\r
If Exist ..\msdos\autogen\Makefile.in sed -f ../msdos/sedlibcf.inp < ..\msdos\autogen\Makefile.in > makefile.tmp\r
sed -f ../msdos/sedlibmk.inp < makefile.tmp > Makefile\r
Echo Configuring the admin/unidata directory...\r
cd admin\unidata\r
sed -f ../../msdos/sedadmin.inp < Makefile.in > Makefile\r
+Echo Configuring the admin/charsets directory...\r
+cd ..\charsets\r
+sed -f ../../msdos/sedadmin.inp < Makefile.in > Makefile\r
+Echo Configuring the admin/grammars directory...\r
+cd ..\grammars\r
+sed -f ../../msdos/sedadmin.inp < Makefile.in > Makefile\r
cd ..\..\r
:noadmin\r
rem ----------------------------------------------------------------------\r
set djgpp_ver=\r
set sys_malloc=\r
set libxml=\r
+set emver=\r