FS#70 - make the makefile keep .o files for both release and debug builds

Attached to Project: OpenTTD
Opened by Bjarni (Bjarni) - Sunday, 12 March 2006, 11:50 GMT
Last edited by Bjarni (Bjarni) - Sunday, 12 March 2006, 11:51 GMT
Type Feature Request
Category Core
Status Closed
Assigned To No-one
Operating System All
Severity Low
Priority Normal
Reported Version trunk
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No


right now when you change Makefile.config, it redo all the dependancies files and all the object files

to prevent needless recompilations, we should store the flags used to compile so we only remake the dependancies files if we changed the source file or we changed the arguments to compile it (we might have changed a flag for linking only)

to make it faster to switch between release and debug builds, the dependancy files and object files should be stored with a prefix of release and debug so we don't overwrite all release object files for making one debug build and then switch back while only changing one source file.

something like .deps/release/(all .o and .d files) would do, but .deps should be renamed if it contains object files as well. It also makes it easier to make clean since you only have to remove one dir

this would also help a lot for building universal binaries if they are stored in .deps/ppc/release and .deps/x86/release. Right now a make clean is needed between each build, so fixing universal binary issues takes a while to compile. This is not needed to be in the first commit of such a feature, it it should be possible to add without redesigning.
This task depends upon

Closed by  Remko Bijker (Rubidium)
Sunday, 07 January 2007, 16:37 GMT
Reason for closing:  Implemented
Additional comments about closing:  In r7759.