aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuanma Barranquero2003-01-31 11:03:11 +0000
committerJuanma Barranquero2003-01-31 11:03:11 +0000
commit47c01e802a27c4d7937b2b1ce5b913952f02b95f (patch)
tree0a47654d4368a5cfc0d1f8b3615d07acb93aa1e6
parent12b918b2e33eb1c113ed8962fac5a78d591dccbf (diff)
downloademacs-47c01e802a27c4d7937b2b1ce5b913952f02b95f.tar.gz
emacs-47c01e802a27c4d7937b2b1ce5b913952f02b95f.zip
Automatically detect tifflib.
-rwxr-xr-xnt/configure.bat31
1 files changed, 31 insertions, 0 deletions
diff --git a/nt/configure.bat b/nt/configure.bat
index 384c37641ac..8f25217d989 100755
--- a/nt/configure.bat
+++ b/nt/configure.bat
@@ -88,6 +88,7 @@ if "%1" == "--ldflags" goto userldflags
88if "%1" == "--without-png" goto withoutpng 88if "%1" == "--without-png" goto withoutpng
89if "%1" == "--without-jpeg" goto withoutjpeg 89if "%1" == "--without-jpeg" goto withoutjpeg
90if "%1" == "--without-gif" goto withoutgif 90if "%1" == "--without-gif" goto withoutgif
91if "%1" == "--without-tiff" goto withouttiff
91if "%1" == "" goto checkutils 92if "%1" == "" goto checkutils
92:usage 93:usage
93echo Usage: configure [options] 94echo Usage: configure [options]
@@ -103,6 +104,7 @@ echo. --ldflags FLAG pass FLAG to compiler when linking
103echo. --without-png do not use libpng even if it is installed 104echo. --without-png do not use libpng even if it is installed
104echo. --without-jpeg do not use jpeglib even if it is installed 105echo. --without-jpeg do not use jpeglib even if it is installed
105echo. --without-gif do not use giflib even if it is installed 106echo. --without-gif do not use giflib even if it is installed
107echo. --without-tiff do not use tifflib even if it is installed
106goto end 108goto end
107rem ---------------------------------------------------------------------- 109rem ----------------------------------------------------------------------
108:setprefix 110:setprefix
@@ -174,6 +176,14 @@ shift
174goto again 176goto again
175 177
176rem ---------------------------------------------------------------------- 178rem ----------------------------------------------------------------------
179
180:withouttiff
181set tiffsupport=N
182set HAVE_TIFF=
183shift
184goto again
185
186rem ----------------------------------------------------------------------
177rem Check that necessary utilities (cp and rm) are present. 187rem Check that necessary utilities (cp and rm) are present.
178:checkutils 188:checkutils
179echo Checking for 'cp'... 189echo Checking for 'cp'...
@@ -334,6 +344,26 @@ set HAVE_GIF=1
334:gifDone 344:gifDone
335rm -f junk.c junk.obj 345rm -f junk.c junk.obj
336 346
347if (%tiffsupport%) == (N) goto tiffDone
348
349echo Checking for tiff...
350echo #include "tiffio.h" >junk.c
351echo main (){} >>junk.c
352rem -o option is ignored with cl, but allows result to be consistent.
353%COMPILER% %usercflags% -c junk.c -o junk.obj
354if exist junk.obj goto haveTiff
355
356echo ...building without TIFF support.
357set HAVE_TIFF=
358goto :tiffDone
359
360:haveTiff
361echo ...TIFF header available, building with TIFF support.
362set HAVE_TIFF=1
363
364:tiffDone
365rm -f junk.c junk.obj
366
337rem ---------------------------------------------------------------------- 367rem ----------------------------------------------------------------------
338:genmakefiles 368:genmakefiles
339echo Generating makefiles 369echo Generating makefiles
@@ -363,6 +393,7 @@ if not "(%userldflags%)" == "()" echo #define USER_LDFLAGS " %userldflags%">>..\
363if not "(%HAVE_PNG%)" == "()" echo #define HAVE_PNG 1 >>..\src\config.h 393if not "(%HAVE_PNG%)" == "()" echo #define HAVE_PNG 1 >>..\src\config.h
364if not "(%HAVE_JPEG%)" == "()" echo #define HAVE_JPEG 1 >>..\src\config.h 394if not "(%HAVE_JPEG%)" == "()" echo #define HAVE_JPEG 1 >>..\src\config.h
365if not "(%HAVE_GIF%)" == "()" echo #define HAVE_GIF 1 >>..\src\config.h 395if not "(%HAVE_GIF%)" == "()" echo #define HAVE_GIF 1 >>..\src\config.h
396if not "(%HAVE_TIFF%)" == "()" echo #define HAVE_TIFF 1 >>..\src\config.h
366echo /* End of settings from configure.bat. */ >>..\src\config.h 397echo /* End of settings from configure.bat. */ >>..\src\config.h
367 398
368copy paths.h ..\src\epaths.h 399copy paths.h ..\src\epaths.h