Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

version assignment / control for multiple EXEs/DLLs

Status
Not open for further replies.

Technokrat

Programmer
Jul 20, 2001
92
0
0
US
I work for a software firm with around 30 programmers. Our main product is comprised of 145 executables and 165 DLL's. To date, we have been using a common version.h file and including this in the .RC file to have all EXEs and DLLs have the same version for a given release. You can probably see the problem already. If one of the many programmers we have does something (like add a new dialog) the RC file gets regenerated, and if they don't remember to manually add the include to the common version reference back into the RC file, we now have a DLL or EXE with a version not in synch with the rest.

Anybody else had to deal with this issue, or have some thoughts/ideas?
 
> if they don't remember to manually add the include
> to the common version reference back into the RC file
Sounds like you need to investigate "custom build steps".

But if your 'edit' of the RC file is any more complicated than appending a line to a file, getting it done using standard console tools will be tough.

So if you don't have them already, UNIX tools like sed, awk and perl will be very useful in performing scripted modifications to files.


--
If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
 
Do you do builds as required or is a build done every night? If it is done every night, then, as part of the automated build process, you can just update the relevant .rc files with the build number.

It doesn't matter on individual builds because that is part of development. The automated build can be the official build.
 
Typically, our builds are performed every night. However, they may be done on a request basis.
I agree the individual builds don't matter because they are part of the individual programmer's development environment. This is the way we treat it.

The master builds occur on a centralized server, which is controlled/monitored by a single person.

I guess the real question may be, is there a tool, or macro other than the UNIX tools that she may use to automatically update the RC files with the correct version?

We could build a parser to read the RC files and ensure they have the correct version, but it just seems to me that we can't be the only site with this problem and there should be an existing solution readily availabe.
 
Does anybody know how the RC file is generated. I assume it is based on some template. Where is this template, and what is it called?
 
Use your current .rc file as a template, replacing the version string by %s, and use whole contents of the file as an argument in a printf().
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top