if "%1" == "--without-png" goto withoutpng\r
if "%1" == "--without-jpeg" goto withoutjpeg\r
if "%1" == "--without-gif" goto withoutgif\r
+if "%1" == "--without-tiff" goto withouttiff\r
if "%1" == "" goto checkutils\r
:usage\r
echo Usage: configure [options]\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
+echo. --without-tiff do not use tifflib even if it is installed\r
goto end\r
rem ----------------------------------------------------------------------\r
:setprefix\r
shift\r
goto again\r
\r
+rem ----------------------------------------------------------------------\r
+\r
+:withouttiff\r
+set tiffsupport=N\r
+set HAVE_TIFF=\r
+shift\r
+goto again\r
+\r
rem ----------------------------------------------------------------------\r
rem Check that necessary utilities (cp and rm) are present.\r
:checkutils\r
:gifDone\r
rm -f junk.c junk.obj\r
\r
+if (%tiffsupport%) == (N) goto tiffDone\r
+\r
+echo Checking for tiff...\r
+echo #include "tiffio.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 haveTiff\r
+\r
+echo ...building without TIFF support.\r
+set HAVE_TIFF=\r
+goto :tiffDone\r
+\r
+:haveTiff\r
+echo ...TIFF header available, building with TIFF support.\r
+set HAVE_TIFF=1\r
+\r
+:tiffDone\r
+rm -f junk.c junk.obj\r
+\r
rem ----------------------------------------------------------------------\r
:genmakefiles\r
echo Generating makefiles\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
+if not "(%HAVE_TIFF%)" == "()" echo #define HAVE_TIFF 1 >>..\src\config.h\r
echo /* End of settings from configure.bat. */ >>..\src\config.h\r
\r
copy paths.h ..\src\epaths.h\r