Re: CMake WIP

Felix Salfelder <[email protected]>
Newsgroups gmane.comp.gnu.gnucap.devel
Message-ID <[email protected]>
On Mon, Aug 05, 2013 at 08:14:00AM +0800, Kevin Zheng wrote:
> > what's more important: do you agree on the way i thing patchlev.h should
> > work? is this feasible with CMake? i think all build systems should
> > (approximately) do the same...
> 
> I already have patchlev.h working. After I rebased my work off of
> master, I just need to copy the autotools-WIP version of patchlev.h and
> put it in somewhere.

patchlev.h is automatically generated. and must be regenerated if you
change the branch. copying will not work. if you want to use CMake to
develop things, it should do likewise.

(this works, but i'm still wondering whether it's better to pass git
commit ids with -D and don't mess with autogenerated headers...)

> I was thinking; should version information be stored in a separate
> object file rather than a header? When the version information changes,
> it forces 'make' to rebuild most/all of the source files. This makes it
> impossible to benefit from 'make' dependency tracking or ccache. Tell me
> what you think.

patchlev.h is included in 4 .cc files. recompilation/linking takes about
10 seconds. thats much better than a wrong version string, if you want
to rely on it.

regards
felix
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.