开发者

Update FILEVERSION in resource file at build

开发者 https://www.devze.com 2023-03-16 19:32 出处:网络
I have an unmanaged program (Fortran) that I\'m adding a Version.rc resource file to include version information.Is there a way to update the last number of the version information at build time with

I have an unmanaged program (Fortran) that I'm adding a Version.rc resource file to include version information. Is there a way to update the last number of the version information at build time with a random number generated at each build? F开发者_高级运维or example.

FILEVERSION = <major>,<minor>,<rev>,<build_hash>

where is updated at each build and the others are input.

This question is similar to Programmatically updating FILEVERSION in a MFC app w/SVN revision number except its not with an SVN number.


As @Hans suggested above. The best approach was to add a pre-build event in Visual Studio that runs a script (Perl in this case) to reach into the *.rc file and change the to a random number.

0

精彩评论

暂无评论...
验证码 换一张
取 消