File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed
Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change 1717 +----------------------------------------------------------------------+
1818*/
1919
20- // $Id: confutils.js,v 1.20 2003-12-19 12:50:11 wez Exp $
20+ // $Id: confutils.js,v 1.21 2003-12-19 16:55:59 wez Exp $
2121
2222var STDOUT = WScript . StdOut ;
2323var STDERR = WScript . StdErr ;
@@ -779,11 +779,19 @@ function generate_internal_functions()
779779 indata = infile . ReadAll ( ) ;
780780 infile . Close ( ) ;
781781
782- outfile = FSO . CreateTextFile ( WshShell . CurrentDirectory + "/main/internal_functions.c" , true ) ;
783-
784782 indata = indata . replace ( "@EXT_INCLUDE_CODE@" , extension_include_code ) ;
785783 indata = indata . replace ( "@EXT_MODULE_PTRS@" , extension_module_ptrs ) ;
786784
785+ if ( FSO . FileExists ( "main/internal_functions.c" ) ) {
786+ var origdata = file_get_contents ( "main/internal_functions.c" ) ;
787+
788+ if ( origdata == indata ) {
789+ STDOUT . WriteLine ( "\t[content unchanged; skipping]" ) ;
790+ return ;
791+ }
792+ }
793+
794+ outfile = FSO . CreateTextFile ( WshShell . CurrentDirectory + "/main/internal_functions.c" , true ) ;
787795 outfile . Write ( indata ) ;
788796 outfile . Close ( ) ;
789797}
You can’t perform that action at this time.
0 commit comments