With Delphi-6 there are two options: Build and Compile.
I know when I run a program it compiles only the files which have changed and uses the DCUs for those which haven't. When I click build apparently it rebuilds the DCUs.
What I have been wondering is, when I make a program for release (changing build settings, conditional variables, etc.) can I just compile, or do I have to do a full build?
What happens if I don't do a full build, is there any consiquence?
When build, when compile?
The compiler only automatically recompiles units when the datetime stamp of the .pas source files changes (1,2).
On other state changes in the project (directives, debug or other compiler settings etc), the compiler won't automatically recompile. That's when you need to force a build.
You also need to force a rebuild when .inc or other included ($I) files change(3), since their datetime-stamp is not checked.
So in summary, when anything but the unit .pas files changes, you need to do a build.
There are some strange cases in building. Most result in a "can't find unit xxx" error while it appears to be there
(1) and if Delphi is like FPC, .dcu's contain a CRC of the interface section of all dcu's it depends on. This can be used to check if there is an additional need for recompiles too. E.g. due to filesystem manipulation (moving dcu's about)
(2) for the experts, have a look at {$implicitbuild xx} too
(3) contrary to Delphi, FPC does rebuild on .inc changes. The FPC project heavily uses .inc files internally, this change already dates from before there was Delphi support. As a result, packages that copy the "defines" inc file into any directory won't compile with FPC because they have usually slightly different size and CRC. Indy (10) is a good example of this.