summaryrefslogtreecommitdiffhomepage
path: root/facetracknoir
diff options
context:
space:
mode:
Diffstat (limited to 'facetracknoir')
-rw-r--r--facetracknoir/facetracknoir.cpp5
-rw-r--r--facetracknoir/facetracknoir.h2
-rw-r--r--facetracknoir/version.c5
3 files changed, 8 insertions, 4 deletions
diff --git a/facetracknoir/facetracknoir.cpp b/facetracknoir/facetracknoir.cpp
index dfa13577..43c96f13 100644
--- a/facetracknoir/facetracknoir.cpp
+++ b/facetracknoir/facetracknoir.cpp
@@ -25,7 +25,6 @@
#include "shortcuts.h"
#include "tracker.h"
#include "curve-config.h"
-#include "opentrack-version.h"
#include <QFileDialog>
#if defined(_WIN32)
@@ -581,6 +580,8 @@ void FaceTrackNoIR::exit() {
QCoreApplication::exit(0);
}
+extern "C" volatile const char* opentrack_version;
+
void FaceTrackNoIR::fill_profile_cbx()
{
if (looping)
@@ -590,7 +591,7 @@ void FaceTrackNoIR::fill_profile_cbx()
QString currentFile = settings.value ( "SettingsFile", QCoreApplication::applicationDirPath() + "/settings/default.ini" ).toString();
qDebug() << "Config file now" << currentFile;
QFileInfo pathInfo ( currentFile );
- setWindowTitle(QString( OPENTRACK_VERSION " :: ") + pathInfo.fileName());
+ setWindowTitle(QString( const_cast<const char*>(opentrack_version) + QStringLiteral(" :: ")) + pathInfo.fileName());
QDir settingsDir( pathInfo.dir() );
QStringList filters;
filters << "*.ini";
diff --git a/facetracknoir/facetracknoir.h b/facetracknoir/facetracknoir.h
index f6f4afdf..713a51f0 100644
--- a/facetracknoir/facetracknoir.h
+++ b/facetracknoir/facetracknoir.h
@@ -55,8 +55,6 @@ using namespace options;
#include "ftnoir_tracker_base/ftnoir_tracker_base.h"
#include "ftnoir_filter_base/ftnoir_filter_base.h"
-#include "opentrack-version.h"
-
class Tracker; // pre-define class to avoid circular includes
class FaceTrackNoIR;
diff --git a/facetracknoir/version.c b/facetracknoir/version.c
new file mode 100644
index 00000000..0ef4ec14
--- /dev/null
+++ b/facetracknoir/version.c
@@ -0,0 +1,5 @@
+#ifdef IN_VERSION_UNIT
+# define IN_CRAPOLA_COMPILE_UNIT
+volatile const char* opentrack_version = OPENTRACK_VERSION;
+#else
+#endif