diff options
| author | Eli Zaretskii | 2005-06-11 14:50:00 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2005-06-11 14:50:00 +0000 |
| commit | c262c68c52be706a193f06a0c237c5d8e7e7a5e7 (patch) | |
| tree | 9fc83cf5e06f1da483ed5b6e02f1c8593aabfbfc | |
| parent | 68dafa7abc5df6965c2201a4aa558c42c7af8c4b (diff) | |
| download | emacs-c262c68c52be706a193f06a0c237c5d8e7e7a5e7.tar.gz emacs-c262c68c52be706a193f06a0c237c5d8e7e7a5e7.zip | |
If their fc.exe returns a meaningful exit status, don't overwrite
src/config.h and src/epaths.h with identical copies.
| -rwxr-xr-x | nt/configure.bat | 38 |
1 files changed, 26 insertions, 12 deletions
diff --git a/nt/configure.bat b/nt/configure.bat index 40a1e64eab3..8433cacc317 100755 --- a/nt/configure.bat +++ b/nt/configure.bat | |||
| @@ -465,20 +465,34 @@ if not "(%userldflags%)" == "()" echo USER_LDFLAGS=%userldflags%>>config.setting | |||
| 465 | echo # End of settings from configure.bat>>config.settings | 465 | echo # End of settings from configure.bat>>config.settings |
| 466 | echo. >>config.settings | 466 | echo. >>config.settings |
| 467 | 467 | ||
| 468 | copy config.nt ..\src\config.h | 468 | copy config.nt config.tmp |
| 469 | echo. >>..\src\config.h | 469 | echo. >>config.tmp |
| 470 | echo /* Start of settings from configure.bat. */ >>..\src\config.h | 470 | echo /* Start of settings from configure.bat. */ >>config.tmp |
| 471 | if not "(%usercflags%)" == "()" echo #define USER_CFLAGS " %usercflags%">>..\src\config.h | 471 | if not "(%usercflags%)" == "()" echo #define USER_CFLAGS " %usercflags%">>config.tmp |
| 472 | if not "(%userldflags%)" == "()" echo #define USER_LDFLAGS " %userldflags%">>..\src\config.h | 472 | if not "(%userldflags%)" == "()" echo #define USER_LDFLAGS " %userldflags%">>config.tmp |
| 473 | if not "(%HAVE_PNG%)" == "()" echo #define HAVE_PNG 1 >>..\src\config.h | 473 | if not "(%HAVE_PNG%)" == "()" echo #define HAVE_PNG 1 >>config.tmp |
| 474 | if not "(%HAVE_JPEG%)" == "()" echo #define HAVE_JPEG 1 >>..\src\config.h | 474 | if not "(%HAVE_JPEG%)" == "()" echo #define HAVE_JPEG 1 >>config.tmp |
| 475 | if not "(%HAVE_GIF%)" == "()" echo #define HAVE_GIF 1 >>..\src\config.h | 475 | if not "(%HAVE_GIF%)" == "()" echo #define HAVE_GIF 1 >>config.tmp |
| 476 | if not "(%HAVE_TIFF%)" == "()" echo #define HAVE_TIFF 1 >>..\src\config.h | 476 | if not "(%HAVE_TIFF%)" == "()" echo #define HAVE_TIFF 1 >>config.tmp |
| 477 | if not "(%HAVE_XPM%)" == "()" echo #define HAVE_XPM 1 >>..\src\config.h | 477 | if not "(%HAVE_XPM%)" == "()" echo #define HAVE_XPM 1 >>config.tmp |
| 478 | echo /* End of settings from configure.bat. */ >>..\src\config.h | 478 | echo /* End of settings from configure.bat. */ >>config.tmp |
| 479 | 479 | ||
| 480 | Rem See if fc.exe returns a meaningful exit status. If it does, we | ||
| 481 | Rem might as well avoid unnecessary overwriting of config.h and epaths.h, | ||
| 482 | Rem since this forces recompilation of every source file. | ||
| 483 | if exist foo.bar del foo.bar | ||
| 484 | fc /b foo.bar foo.bar >nul 2>&1 | ||
| 485 | if not errorlevel 2 goto doCopy | ||
| 486 | fc /b config.tmp ..\src\config.h >nul 2>&1 | ||
| 487 | if errorlevel 1 goto doCopy | ||
| 488 | fc /b paths.h ..\src\epaths.h >nul 2>&1 | ||
| 489 | if errorlevel 0 goto dontCopy | ||
| 490 | :doCopy | ||
| 491 | copy config.tmp ..\src\config.h | ||
| 480 | copy paths.h ..\src\epaths.h | 492 | copy paths.h ..\src\epaths.h |
| 481 | 493 | ||
| 494 | :dontCopy | ||
| 495 | if exist config.tmp del config.tmp | ||
| 482 | copy /b config.settings+%MAKECMD%.defs+..\nt\makefile.w32-in ..\nt\makefile | 496 | copy /b config.settings+%MAKECMD%.defs+..\nt\makefile.w32-in ..\nt\makefile |
| 483 | copy /b config.settings+%MAKECMD%.defs+..\lib-src\makefile.w32-in ..\lib-src\makefile | 497 | copy /b config.settings+%MAKECMD%.defs+..\lib-src\makefile.w32-in ..\lib-src\makefile |
| 484 | copy /b config.settings+%MAKECMD%.defs+..\src\makefile.w32-in ..\src\makefile | 498 | copy /b config.settings+%MAKECMD%.defs+..\src\makefile.w32-in ..\src\makefile |