[lttng-dev] [lttng-tools PATCH (correction)] Add a git version line in LTTng versions compiled from git sources.

David Goulet dgoulet at efficios.com
Wed Mar 13 11:40:18 EDT 2013


We could simply have let say "version.h" that is used for that and put
into the right C files? (sessiond and lttng).

David

Christian Babeux:
> Hi Raphaël,
> 
> I wonder if we would like to also have the same information when
> running lttng-sessiond --version?
> 
>>         MSG("lttng version " VERSION " - " VERSION_NAME);
>> +#ifdef GIT_VERSION
>> +       MSG("Git version: " GIT_VERSION);
>> +#endif
>>         MSG("\n" VERSION_DESCRIPTION "\n");
>>         MSG("Web site: http://lttng.org");
>>         MSG("\nlttng is free software and under the GPL license and part LGPL");
> 
> Would it be possible to put such a define in a header file, perhaps
> config.h? I think the downside of this approach is that it would
> require a rebuild of all files that include config.h each time your
> git index is modified (commit, pull, etc.), though I'm not entirely
> sure of this.
> 
> Thanks,
> 
> Christian



More information about the lttng-dev mailing list