From: John L. <jr...@us...> - 2008-01-29 01:39:30
|
Update of /cvsroot/wxlua/wxLua/bindings In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv28032/wxLua/bindings Modified Files: genwxbind.lua Log Message: Try to speed up the build process by having only one cpp file for the smaller bindings using output_single_cpp_binding_file in the rules file. Index: genwxbind.lua =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/genwxbind.lua,v retrieving revision 1.163 retrieving revision 1.164 diff -C2 -d -r1.163 -r1.164 *** genwxbind.lua 29 Jan 2008 00:49:10 -0000 1.163 --- genwxbind.lua 29 Jan 2008 01:38:55 -0000 1.164 *************** *** 505,514 **** -- returns true for a match or false if not -- --------------------------------------------------------------------------- ! function FileDataIsTableData(filename, fileData) local file_handle = io.open(filename) if not file_handle then return false end -- ok if it doesn't exist local f = file_handle:read("*a") ! local is_same = (f == table.concat(fileData)) io.close(file_handle) return is_same --- 505,514 ---- -- returns true for a match or false if not -- --------------------------------------------------------------------------- ! function FileDataIsStringData(filename, strData) local file_handle = io.open(filename) if not file_handle then return false end -- ok if it doesn't exist local f = file_handle:read("*a") ! local is_same = (f == strData) io.close(file_handle) return is_same *************** *** 517,521 **** -- --------------------------------------------------------------------------- -- Write the contents of the table fileData (indexes 1.. are line numbers) ! -- to the filename, but only write to the file if FileDataIsTableData returns -- false. If overwrite_always is true then always overwrite the file. -- returns true if the file was overwritten --- 517,521 ---- -- --------------------------------------------------------------------------- -- Write the contents of the table fileData (indexes 1.. are line numbers) ! -- to the filename, but only write to the file if FileDataIsStringData returns -- false. If overwrite_always is true then always overwrite the file. -- returns true if the file was overwritten *************** *** 524,528 **** assert(filename and fileData, "Invalid filename or fileData in WriteTableToFile") ! if (not overwrite_always) and FileDataIsTableData(filename, fileData) then print("No changes to file : '"..filename.."'") return false --- 524,530 ---- assert(filename and fileData, "Invalid filename or fileData in WriteTableToFile") ! local strData = table.concat(fileData) ! ! if (not overwrite_always) and FileDataIsStringData(filename, strData) then print("No changes to file : '"..filename.."'") return false *************** *** 537,541 **** end ! outfile:write(table.concat(fileData)) outfile:flush() --- 539,543 ---- end ! outfile:write(strData) outfile:flush() |