View Full Version : Is it possible to

11-10-2004, 06:35 AM
I have 2 releases which are pretty much the same apart from the executable. One of which is our 30-day and the other our production. Each release has its own folder and branch on the start menu. We would like to build these using a single project file as they are essentially the same product but is it possible (whilst using best rules) to.

1) specify shortcuts for a component who's location is dependent upon a release

2) change INSTALLDIR based upon a release

thanks in advance for any help

Stephen Whipp

11-10-2004, 03:35 PM
Sure thing,

the neatest way is probably, using two separate features and release flags to build a full and an eval version.

such as:
1. Feature "FullEXE" with ReleaseFlag = FULL
2. Feature "EvalEXE" with ReleaseFlag = EVAL

Then add files, shortcuts, etc to new components and attach to relevant feature. You can even set INSTALLDIR from a set directory custom action using a feature condition.

Then just build two releases specifying FULL or EVAL as the release flags and you're done.

Hope it makes sense,

11-11-2004, 08:00 AM
The only problem is that to do it seems to require having components with repeated resources. I.e. for our Help system I need to create each component twice to attach the shortcuts to the correct location. This violates best practicies as I understand them (a resource should only be part of 1 component even between products).

I have tried to create a merge module for this, but I cannot specify the shortcuts dynamically. I guess I'll have to script the shortcuts in the product project based upon a preprocessor override or something.

11-11-2004, 11:20 AM
hmm, not necessarily.
There's no need for a merge module unless you share the data with other products.

Why not move the unique ressources into separate components and then attach the 'shared' components to each feature.

In other words, separate the data that is used in all product types from the product specific data and use release flags to control what ends up in a particular release.