Can anybody help me with this? I am building from the command line using a batch file. Every time the batch file is run, all C files are rebuilt even if there were no changes. Building from the uVision2 IDE works as you would expect with incremental builds. I have search this site and found two memos about this. One concerns the TZ setting in the Autoexec.bat - I don't have that. The other memo states a "A=0x0" in the Defines section can cause this as well. I removed all defines and still have the problem. Any ideas? Thanks Barry
What exactly is in "the batch file?"
This is UV_Make.bat that starts the process: @echo off call set_build_paths.bat echo. echo Deleting the old build results file. del "UV Build.txt" echo. call mk_englsh.bat echo. echo Building the project using Keil uVision2 %UV_DIR%\UV2 -b"%BUILD_DIR%\5100 uVision.UV2" -t"Target 1" -o"%BUILD_DIR%\UV Build.txt" rem End of UV_Make.bat This is set_build_paths.bat which gets called from the the first batch file: @echo off echo Setting the paths. set BUILD_DIR=d:\source\predat~1\5100\build set UV_DIR=c:\tools\keil\uv2 echo %BUILD_DIR% echo %UV_DIR% rem End of set_build_paths.bat This is mk_english.bat which gets called from the the first batch file: @echo off echo Building String Resources using ResComp.exe... if not exist ..\ObjFlash\* mkdir..\ObjFlash ..\Resource\ResComp.exe -P:..\Resource\Predator.prj -O:..\Source\DDATable -H:..\Source\DDAText.h ..\Source\english.c if errorlevel 0 goto end echo Resource Build Error pause :end rem End of mk_english.bat I'm not sure if it is an issue but I am using Windows NT 4.0. Thanks and I hope this helps. Barry
I have found what is causing this problem although I don't fully understand it. The call to "mk_englsh.bat" is creating two updated header files (dda_test.h and ddatable.h) as a byproduct of what it does which apparently causes uVision to believe that all of the files are out of date. The dependencies in my source files don't seem to bear this out but I will have to check further. Thanks for your help. Barry
Time to learn how to use make (E.g. Gnu make, Borland make, MS nmake). - Mark
It is because I am using NMAKE that I had to take this approach. Nobody could tell me how to simulate the V3 AMAKE actions using a batch file and V4 of the build tools. So now I am using uVision to replace NMAKE and gain uVision's automatic register optimization feature.
"uVision's automatic register optimization feature." I think that's a feature of the compiler & Linker; uVision just provides an "easy" interface to access those features. So it should be possible to do it from the command line - you can take the options generated by uVision as your starting point.
View all questions in Keil forum