summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-07-18 10:15:29 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-07-18 10:15:29 +0200
commit181770b1e169b9c7c75eacdc969102cce18a8be7 (patch)
tree9f7a990c37dd48f803c9005da13cd86d3f8534cd
parentc3a1174b922040da29b9c979343aa9fba24b46ba (diff)
some: adjust install paths and invocations
-rw-r--r--csv/csv.cpp4
-rw-r--r--gui/ui.cpp4
-rw-r--r--proto-ft/CMakeLists.txt2
-rw-r--r--proto-ft/ftnoir_protocol_ft.cpp7
-rw-r--r--proto-vjoy/CMakeLists.txt2
-rw-r--r--tracker-hydra/CMakeLists.txt2
-rw-r--r--tracker-rs/CMakeLists.txt5
-rw-r--r--tracker-rs/ftnoir_tracker_rs.cpp5
8 files changed, 18 insertions, 13 deletions
diff --git a/csv/csv.cpp b/csv/csv.cpp
index 1c4a3bb1..c3805ae7 100644
--- a/csv/csv.cpp
+++ b/csv/csv.cpp
@@ -98,8 +98,8 @@ bool CSV::getGameData(int id, unsigned char* table, QString& gamename)
QString id_str(QString::number(id));
- static const QString csv_path(QCoreApplication::applicationDirPath() +
- QString(OPENTRACK_LIBRARY_PATH) +
+ static const QString csv_path(OPENTRACK_BASE_PATH +
+ OPENTRACK_DOC_PATH +
QString("settings/facetracknoir supported games.csv"));
QFile file(csv_path);
diff --git a/gui/ui.cpp b/gui/ui.cpp
index 35c7dd26..97eee716 100644
--- a/gui/ui.cpp
+++ b/gui/ui.cpp
@@ -22,7 +22,7 @@
#endif
MainWindow::MainWindow() :
- State(QCoreApplication::applicationDirPath() + OPENTRACK_LIBRARY_PATH),
+ State(OPENTRACK_BASE_PATH + OPENTRACK_LIBRARY_PATH),
pose_update_timer(this),
kbd_quit(QKeySequence("Ctrl+Q"), this),
is_refreshing_profiles(false)
@@ -177,7 +177,7 @@ MainWindow::~MainWindow()
void MainWindow::set_working_directory()
{
- QDir::setCurrent(QCoreApplication::applicationDirPath());
+ QDir::setCurrent(OPENTRACK_BASE_PATH);
}
void MainWindow::save_modules()
diff --git a/proto-ft/CMakeLists.txt b/proto-ft/CMakeLists.txt
index f8a2fe1e..fb22ede4 100644
--- a/proto-ft/CMakeLists.txt
+++ b/proto-ft/CMakeLists.txt
@@ -1,4 +1,4 @@
if(WIN32)
opentrack_boilerplate(opentrack-proto-freetrack)
- target_link_libraries(opentrack-proto-freetrack opentrack-compat opentrack-csv)
+ target_link_libraries(opentrack-proto-freetrack opentrack-csv)
endif()
diff --git a/proto-ft/ftnoir_protocol_ft.cpp b/proto-ft/ftnoir_protocol_ft.cpp
index ccec3db0..111af156 100644
--- a/proto-ft/ftnoir_protocol_ft.cpp
+++ b/proto-ft/ftnoir_protocol_ft.cpp
@@ -8,6 +8,7 @@
#include "ftnoir_protocol_ft.h"
#include "csv/csv.h"
+#include "opentrack-library-path.h"
check_for_first_run FTNoIR_Protocol::runonce_check = check_for_first_run();
@@ -93,7 +94,7 @@ void FTNoIR_Protocol::pose(const double* headpose) {
}
void FTNoIR_Protocol::start_tirviews() {
- QString aFileName = QCoreApplication::applicationDirPath() + "/TIRViews.dll";
+ QString aFileName = OPENTRACK_BASE_PATH + OPENTRACK_LIBRARY_PATH "TIRViews.dll";
if ( QFile::exists( aFileName )) {
FTIRViewsLib.setFileName(aFileName);
FTIRViewsLib.load();
@@ -118,14 +119,14 @@ void FTNoIR_Protocol::start_tirviews() {
}
void FTNoIR_Protocol::start_dummy() {
- QString program = QCoreApplication::applicationDirPath() + "/TrackIR.exe";
+ QString program = OPENTRACK_BASE_PATH + OPENTRACK_LIBRARY_PATH "TrackIR.exe";
dummyTrackIR.setProgram("\"" + program + "\"");
dummyTrackIR.start();
}
void FTNoIR_Protocol::set_protocols(bool ft, bool npclient)
{
- const QString program_dir = QCoreApplication::applicationDirPath() + "/";
+ const QString program_dir = OPENTRACK_BASE_PATH + OPENTRACK_LIBRARY_PATH;
// Registry settings (in HK_USER)
QSettings settings_ft("Freetrack", "FreetrackClient");
diff --git a/proto-vjoy/CMakeLists.txt b/proto-vjoy/CMakeLists.txt
index 1c4f7fb9..50b23e47 100644
--- a/proto-vjoy/CMakeLists.txt
+++ b/proto-vjoy/CMakeLists.txt
@@ -18,6 +18,6 @@ if(WIN32)
opentrack_boilerplate(opentrack-proto-vjoy LINK "${link}")
target_link_libraries(opentrack-proto-vjoy "${implib}")
target_include_directories(opentrack-proto-vjoy SYSTEM PUBLIC ${SDK_VJOY})
- install(FILES "${lib}" DESTINATION . RENAME "VJoy.dll")
+ install(FILES "${lib}" DESTINATION ${opentrack-hier-pfx} RENAME "VJoy.dll")
endif()
endif()
diff --git a/tracker-hydra/CMakeLists.txt b/tracker-hydra/CMakeLists.txt
index 13613625..2042c944 100644
--- a/tracker-hydra/CMakeLists.txt
+++ b/tracker-hydra/CMakeLists.txt
@@ -18,7 +18,7 @@ if(SDK_HYDRA)
set(under_dll _dll)
set(soext dll)
target_link_libraries(opentrack-tracker-hydra "${SDK_HYDRA}/${dir}/win32/release_dll/sixense.${ext}")
- install(FILES "${SDK_HYDRA}/bin/win32/release_dll/sixense.dll" DESTINATION . ${opentrack-perms})
+ install(FILES "${SDK_HYDRA}/bin/win32/release_dll/sixense.dll" DESTINATION ${opentrack-hier-pfx} ${opentrack-perms})
else()
if(APPLE)
set(dest .)
diff --git a/tracker-rs/CMakeLists.txt b/tracker-rs/CMakeLists.txt
index adde1dde..eb64feb1 100644
--- a/tracker-rs/CMakeLists.txt
+++ b/tracker-rs/CMakeLists.txt
@@ -9,6 +9,7 @@ if(WIN32)
add_custom_target(opentrack-tracker-rs-impl DEPENDS ${libpath})
add_dependencies(opentrack-tracker-rs opentrack-tracker-rs-impl)
target_link_libraries(opentrack-tracker-rs "${libpath}" advapi32)
- install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/intel_rs_sdk_runtime_websetup_10.0.26.0396.exe" DESTINATION ./contrib/ ${opentrack-perms})
- install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/RS_EULA.rtf" DESTINATION ./contrib/ ${opentrack-perms})
+
+ install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/intel_rs_sdk_runtime_websetup_10.0.26.0396.exe" DESTINATION ${opentrack-contrib-pfx} ${opentrack-perms})
+ install(FILES "${CMAKE_SOURCE_DIR}/tracker-rs/redist/RS_EULA.rtf" DESTINATION ${opentrack-contrib-pfx} ${opentrack-perms})
endif()
diff --git a/tracker-rs/ftnoir_tracker_rs.cpp b/tracker-rs/ftnoir_tracker_rs.cpp
index d543c49c..4a59d74a 100644
--- a/tracker-rs/ftnoir_tracker_rs.cpp
+++ b/tracker-rs/ftnoir_tracker_rs.cpp
@@ -9,6 +9,7 @@
#include "ftnoir_tracker_rs_controls.h"
#include "imagewidget.h"
#include "opentrack/plugin-api.hpp"
+#include "opentrack-library-path.h"
#include <QMessageBox>
#include <QProcess>
#include <QStackedLayout>
@@ -82,7 +83,9 @@ void RSTracker::handleTrackingEnded(int exitCode){
bool RSTracker::startSdkInstallationProcess()
{
- bool pStarted = QProcess::startDetached("contrib\\intel_rs_sdk_runtime_websetup_10.0.26.0396.exe --finstall=core,face3d --fnone=all");
+ static const QString contrib_path(OPENTRACK_BASE_PATH + QString(OPENTRACK_CONTRIB_PATH));
+
+ bool pStarted = QProcess::startDetached(contrib_path + "intel_rs_sdk_runtime_websetup_10.0.26.0396.exe --finstall=core,face3d --fnone=all");
if(!pStarted){
QMessageBox::warning(0, "IntelĀ® RealSenseā„¢ Runtime Installation", "Installation process failed to start.", QMessageBox::Ok);
}