linking a resource (*.RES) file in VS-2008

linking a resource (*.RES) file in VS-2008

Hi:

How do I ge the linker to include my resource file *.RES file in the list of object files that it writes to the response file *.RSP when it is building an application inside VS2008?

I've gone through every possible variation in the Build Configuration Properties Tab, but nothing I do works

Thanks in advance

3 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Never mind - after 3 days of agony, I just figured it out (of course just after posting the question).

In case anyone else has this problem:

You must use "Solution explorer" and add your *.RC file to the list of files included under the "resource" header.

Then, you choose the *.RC file with a right-click in Solution Explorer, choose properties, and add the RC command to the "Command" line in the "Custom build step". Choose your output file to be the "*.RES" file, and it will be included in the linker list of files to be linked.

But don't forget what you did, because this will NOT SHOW UP in the "Custom Build Step" of the Configuration properties for the whole project.

Mirabile dictu.

Steve Lionel (Intel)'s picture

If it is simply a case of the .RES file, you can add it as an "Additional dependency" in the Linker properties. A .rc file should be compiled automatically without a custom command line. I have seen some cases where file associations prevented this from working.

Steve

Login to leave a comment.