http://redmine.emweb.be/
http://redmine.emweb.be/favicon.ico?1693408525
2013-09-18T08:28:29Z
Redmine
Wt - Feature #1096: add wt version check to the FindWt.cmake module.
http://redmine.emweb.be/issues/1096?journal_id=6730
2013-09-18T08:28:29Z
Koen Deforche
koen@emweb.be
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>InProgress</i></li><li><strong>Assignee</strong> set to <i>Wim Dumon</i></li><li><strong>Priority</strong> changed from <i>Normal</i> to <i>Low</i></li></ul>
Wt - Feature #1096: add wt version check to the FindWt.cmake module.
http://redmine.emweb.be/issues/1096?journal_id=6731
2013-09-18T09:13:38Z
Koen Deforche
koen@emweb.be
<ul></ul><p>This probably will be needed:</p>
<pre><code>GET_PROPERTY(dirs DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY INCLUDE_DIRECTORIES)
TRY_RUN(VERSION_RUN_RESULT VERSION_COMPILE_RESULT
${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/wt_version.cpp
CMAKE_FLAGS "-DINCLUDE_DIRECTORIES:STRING=${dirs}"
RUN_OUTPUT_VARIABLE WT_VERSION)
MESSAGE("WT VERSION: ${WT_VERSION}")
</code></pre>
<p>with wt_verison.cpp something like:</p>
<pre><code>#include <Wt/WGlobal>
#include <iostream>
int main() {
std::cout << "Version: " << WT_VERSION_STR << std::endl;
return 0;
}
</code></pre>