If you have a turtle SVN, you can use SubWCRev.exe
Create a file with the name:
RevisionInfo.tmpl
int SvnRevision = $WCREV$;
Then run the following command:
SubWCRev.exe . RevisionInfo.tmpl RevisionInfo.cpp
It will create a ReivisonInfo.cpp file with your revision number as follows:
int SvnRevision = 5000;
From other files, just do something like:
extern int SvnRevision; to access the global variable from within this file.
You can also use SvnRev