@echo off\r
rem ----------------------------------------------------------------------\r
-rem Configuration script for MS Windows 95/98 and NT/2000\r
-rem Copyright (C) 1999-2001 Free Software Foundation, Inc.\r
+rem Configuration script for MS Windows 95/98/Me and NT/2000/XP\r
+rem Copyright (C) 1999-2003 Free Software Foundation, Inc.\r
\r
rem This file is part of GNU Emacs.\r
\r
rem ----------------------------------------------------------------------\r
rem YOU'LL NEED THE FOLLOWING UTILITIES TO MAKE EMACS:\r
rem\r
-rem + MS Windows 95/98 or NT/2000\r
+rem + MS Windows 95/98/Me or NT/2000/XP\r
rem + either MSVC 2.x or later, or gcc-2.95 or later (with gmake 3.75\r
rem or later) and the Mingw32 and W32 API headers and libraries\r
rem\r
if "%1" == "--ldflags" goto userldflags\r
if "%1" == "--without-png" goto withoutpng\r
if "%1" == "--without-jpeg" goto withoutjpeg\r
+if "%1" == "--without-gif" goto withoutgif\r
if "%1" == "" goto checkutils\r
:usage\r
echo Usage: configure [options]\r
echo. --ldflags FLAG pass FLAG to compiler when linking\r
echo. --without-png do not use libpng even if it is installed\r
echo. --without-jpeg do not use jpeglib even if it is installed\r
+echo. --without-gif do not use giflib even if it is installed\r
goto end\r
rem ----------------------------------------------------------------------\r
:setprefix\r
shift\r
goto again\r
\r
+rem ----------------------------------------------------------------------\r
+\r
+:withoutgif\r
+set gifsupport=N\r
+set HAVE_GIF=\r
+shift\r
+goto again\r
+\r
rem ----------------------------------------------------------------------\r
rem Check that necessary utilities (cp and rm) are present.\r
:checkutils\r
\r
if (%jpegsupport%) == (N) goto jpegDone\r
\r
-echo Checking for jpeg ...\r
+echo Checking for jpeg...\r
echo #include "jconfig.h" >junk.c\r
echo main (){} >>junk.c\r
rem -o option is ignored with cl, but allows result to be consistent.\r
:jpegDone\r
rm -f junk.c junk.obj\r
\r
+if (%gifsupport%) == (N) goto gifDone\r
+\r
+echo Checking for gif...\r
+echo #include "gif_lib.h" >junk.c\r
+echo main (){} >>junk.c\r
+rem -o option is ignored with cl, but allows result to be consistent.\r
+%COMPILER% %usercflags% -c junk.c -o junk.obj\r
+if exist junk.obj goto haveGif\r
+\r
+echo ...building without GIF support.\r
+set HAVE_GIF=\r
+goto :gifDone\r
+\r
+:haveGif\r
+echo ...GIF header available, building with GIF support.\r
+set HAVE_GIF=1\r
+\r
+:gifDone\r
+rm -f junk.c junk.obj\r
+\r
rem ----------------------------------------------------------------------\r
:genmakefiles\r
echo Generating makefiles\r
if not "(%userldflags%)" == "()" echo #define USER_LDFLAGS " %userldflags%">>..\src\config.h\r
if not "(%HAVE_PNG%)" == "()" echo #define HAVE_PNG 1 >>..\src\config.h\r
if not "(%HAVE_JPEG%)" == "()" echo #define HAVE_JPEG 1 >>..\src\config.h\r
+if not "(%HAVE_GIF%)" == "()" echo #define HAVE_GIF 1 >>..\src\config.h\r
echo /* End of settings from configure.bat. */ >>..\src\config.h\r
\r
copy paths.h ..\src\epaths.h\r