Build numbers
How would I go about implementing a system that would automatically update a build number for my projects when I compile them?
Specifically I want to be able to check that my executable is using the latest version of my library, so that if I forget to recompile it after making a change to my library I don't waste time wondering why things aren't working properly.
[edited by - SpaceRogue on June 4, 2003 9:04:49 PM]
Rather than creating build numbers that you have to manage, why not just set up your build environment so that you have an automatic dependency structure. In most IDEs, you can do that quite easily by clicking a few checkboxes and in Makefiles, you setup your targets to be dependent on certain other targets (such as libs) and source files, so that when you make a change to one file, you will automatically build everything that is affected by that one change.
Much better, I think, then trying to keep track of which build number of some library belongs to which build number of some executable which belongs to which build number of some dll, etc., etc., etc...
Much better, I think, then trying to keep track of which build number of some library belongs to which build number of some executable which belongs to which build number of some dll, etc., etc., etc...
Personally, I would just set the dependency of the projects. But I can also see how adding a build number that increased each time you compiled could be easily added via a VBScript in the MSVC IDE. Though really, using the __TIMESTAMP__ macro should be enough to keep track of builds.
Thanks.
I didn''t realize you could automate dependencies like that in the IDE.
I''ll look into it.
I didn''t realize you could automate dependencies like that in the IDE.
I''ll look into it.
If you are using Visual Studio, try these articles at www.codeproject.com:
Auto-Increment of the Build Count
RCStamp - add build counts and more to your .rc files
Auto-Incrementing Build Numbers
Increment Private Build Number
An Automatic Build Incrementer for VC6
Add-in for automatically incrementing build numbers in Visual Studio.NET
Auto-Increment of the Build Count
RCStamp - add build counts and more to your .rc files
Auto-Incrementing Build Numbers
Increment Private Build Number
An Automatic Build Incrementer for VC6
Add-in for automatically incrementing build numbers in Visual Studio.NET
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement