mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-29 22:22:54 +02:00
Merge branch 'master' of https://github.com/highfidelity/hifi into domain-tunnel
This commit is contained in:
commit
9baf983d07
3 changed files with 36 additions and 15 deletions
|
@ -1298,7 +1298,7 @@ bool DomainServer::handleHTTPRequest(HTTPConnection* connection, const QUrl& url
|
||||||
|
|
||||||
// create a file with the GUID of the assignment in the script host location
|
// create a file with the GUID of the assignment in the script host location
|
||||||
QFile scriptFile(newPath);
|
QFile scriptFile(newPath);
|
||||||
scriptFile.open(QIODevice::WriteOnly);
|
if (scriptFile.open(QIODevice::WriteOnly)) {
|
||||||
scriptFile.write(formData[0].second);
|
scriptFile.write(formData[0].second);
|
||||||
|
|
||||||
qDebug() << qPrintable(QString("Saved a script for assignment at %1%2")
|
qDebug() << qPrintable(QString("Saved a script for assignment at %1%2")
|
||||||
|
@ -1308,6 +1308,11 @@ bool DomainServer::handleHTTPRequest(HTTPConnection* connection, const QUrl& url
|
||||||
SharedAssignmentPointer sharedScriptedAssignment(scriptAssignment);
|
SharedAssignmentPointer sharedScriptedAssignment(scriptAssignment);
|
||||||
_unfulfilledAssignments.enqueue(sharedScriptedAssignment);
|
_unfulfilledAssignments.enqueue(sharedScriptedAssignment);
|
||||||
_allAssignments.insert(sharedScriptedAssignment->getUUID(), sharedScriptedAssignment);
|
_allAssignments.insert(sharedScriptedAssignment->getUUID(), sharedScriptedAssignment);
|
||||||
|
} else {
|
||||||
|
// unable to save script for assignment - we shouldn't be here but debug it out
|
||||||
|
qDebug() << "Unable to save a script for assignment at" << newPath;
|
||||||
|
qDebug() << "Script will not be added to queue";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// respond with a 200 code for successful upload
|
// respond with a 200 code for successful upload
|
||||||
|
|
|
@ -139,6 +139,8 @@ foreach(EXTERNAL ${OPTIONAL_EXTERNALS})
|
||||||
|
|
||||||
if (NOT APPLE OR NOT ${${EXTERNAL}_UPPERCASE} MATCHES "SIXENSE")
|
if (NOT APPLE OR NOT ${${EXTERNAL}_UPPERCASE} MATCHES "SIXENSE")
|
||||||
target_link_libraries(${TARGET_NAME} ${${${EXTERNAL}_UPPERCASE}_LIBRARIES})
|
target_link_libraries(${TARGET_NAME} ${${${EXTERNAL}_UPPERCASE}_LIBRARIES})
|
||||||
|
elseif (APPLE)
|
||||||
|
add_definitions(-DSIXENSE_LIB_FILENAME=\"${${${EXTERNAL}_UPPERCASE}_LIBRARY_RELEASE}\")
|
||||||
endif ()
|
endif ()
|
||||||
endif ()
|
endif ()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
|
@ -96,15 +96,29 @@ void SixenseManager::initialize() {
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
|
|
||||||
if (!_sixenseLibrary) {
|
if (!_sixenseLibrary) {
|
||||||
const QString SIXENSE_LIBRARY_NAME = "libsixense_x64.dylib";
|
|
||||||
_sixenseLibrary = new QLibrary(SIXENSE_LIBRARY_NAME);
|
|
||||||
|
#ifdef SIXENSE_LIB_FILENAME
|
||||||
|
_sixenseLibrary = new QLibrary(SIXENSE_LIB_FILENAME);
|
||||||
|
#else
|
||||||
|
const QString SIXENSE_LIBRARY_NAME = "libsixense_x64";
|
||||||
|
QFileInfo frameworkSixenseLibrary = QCoreApplication::applicationDirPath() + "../Frameworks/"
|
||||||
|
+ SIXENSE_LIBRARY_NAME;
|
||||||
|
|
||||||
|
_sixenseLibrary = new QLibrary(frameworkSixenseLibrary.fileName());
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
if (_sixenseLibrary->load()){
|
||||||
|
qDebug() << "Loaded sixense library for hydra support -" << _sixenseLibrary->fileName();
|
||||||
|
} else {
|
||||||
|
qDebug() << "Sixense library at" << _sixenseLibrary->fileName() << "failed to load."
|
||||||
|
<< "Continuing without hydra support.";
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
qDebug() << "Initializing sixense library for hydra support - libsixense_x64.dylib load state is"
|
|
||||||
<< _sixenseLibrary->isLoaded();
|
|
||||||
SixenseBaseFunction sixenseInit = (SixenseBaseFunction) _sixenseLibrary->resolve("sixenseInit");
|
SixenseBaseFunction sixenseInit = (SixenseBaseFunction) _sixenseLibrary->resolve("sixenseInit");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
sixenseInit();
|
sixenseInit();
|
||||||
|
|
||||||
_isInitialized = true;
|
_isInitialized = true;
|
||||||
|
|
Loading…
Reference in a new issue