I'd like to solve the following problem, but have not found a way how to yet:

Our source is rebuilt every night, but only if some sources changed (e.g.
the build tree is not removed, only the source tree is updated from CVS).

What I want is to include the build date/time in a versionInfo.cxx sourcefile
(with __DATE__ and __TIME__ macros) if and only if the executable needs a 
rebuild.
That is, the executable has a commandline option "-version" which should print
the information "build time: xxxxx"

So what I need is something like a rule:
"if the exe needs a rebuild (any dependant source changed except the 
versionInfo.cxx file),
rebuild the versionInfo.o file and link it to the executable"

Any ideas ?

-- 
Best Regards/Schöne Grüße

Martin

-----------------------------------------------------------------
Ing. Martin Koller , mailto:[email protected] , http://www.etm.at
ETM professional control GmbH, A-7000 Eisenstadt Marktstr. 3
Phone:+43 2682/741-62603, Fax:+43 2682/741-52555
-----------------------------------------------------------------
A: Because it breaks the logical sequence of discussion
Q: Why is top posting bad?


--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to