I\'m looking for a way to get a number which will almost surely change when running the code on different machines and almost surely stay the same between two runs on the sa
One quite portable solution would be to use modification time of a current executable. stat function is available on unix and windows, although API is different so you would need to use some IFDEFs.
A binary is unlikely to be deployed at the exactly same time to different machines, so the ids should be unique. The drawback is that the binary update will change the ids.