Jump to content


A trivial question


  • You cannot reply to this topic
2 replies to this topic

#1 Nautilus

    Senior Member

  • Members
  • PipPipPipPip
  • 326 posts

Posted 28 September 2007 - 10:26 PM

Greetings,
is there a way to have the VS2005 compiler auto-increment the Build number in a VS_VERSION_FILE block every time I compile?
1.0.0.1 --> 1.0.0.2 --//--> 1.0.0.59 ...

I know it's a trivial question :lol: but I've seen the old VB6 IDE doing it, and I find it strange that the feature is absent in VS2005.

Thanks,
Ciao ciao : )
-Nautilus

(readin' this? perhaps you should get out more -- give it a thought)


#2 Nautilus

    Senior Member

  • Members
  • PipPipPipPip
  • 326 posts

Posted 01 October 2007 - 04:23 PM

Hey hey, not all together, please!

45 views, 0 replies.
I should say Thanks anyway.....

#3 Nils Pipenbrinck

    Senior Member

  • Members
  • PipPipPipPip
  • 597 posts

Posted 01 October 2007 - 07:38 PM

Nautilus:

Code yourself a 10 liner that will write a c-code that defines the current version/build number as a char array. Apply that tool as a custom building step on a source file defining the current build-id. It can be anything, a text-file, or a 4 byte binary thing. Whatever you like.

Make sure you change the input file time-stamp way back in the past (1.1. 1970 comes to mind). This is the key that DevEnv or make will trigger your tool during each build and generate a new id.

It is a dirty hack, but unfortunately no compiler I know of offers a cleaner way to generate such "everyone should have em"-build timestamps.
My music: http://myspace.com/planetarchh <-- my music

My stuff: torus.untergrund.net <-- some diy electronic stuff and more.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users