Correctly handle the case when building without OpenSim and without Havok support

master
Ansariel 2019-05-11 14:22:24 +02:00
parent 7a95f818b8
commit 603b840a0f
5 changed files with 14 additions and 7 deletions

View File

@ -36,6 +36,11 @@ else (OPENSIM)
endif()
message("compiling without OpenSim support")
endif (OPENSIM)
if (HAVOK_TPV)
add_definitions(-DHAVOK_TPV=1)
message("compiling with Havok libraries")
endif (HAVOK_TPV)
#</FS:AW optional opensim support>
#<FS:Ansariel> Support for test builds

View File

@ -221,7 +221,7 @@ set(USE_PRECOMPILED_HEADERS ON CACHE BOOL "Enable use of precompiled header dire
# <FS:ND> When using Havok, we have to turn OpenSim support off
if( HAVOK_TPV )
if( OPENSIM )
message( "Compiling with Havok libraries, disabling OpenSim support" )
message( "compiling with Havok libraries, disabling OpenSim support" )
endif( OPENSIM )
set( OPENSIM OFF )

View File

@ -2055,7 +2055,7 @@ bool LLAppViewer::cleanup()
// <FS:ND> FIRE-8385 Crash on exit in Havok. It is hard to say why it happens, as we only have the binary Havok blob. This is a hack around it.
// Due to the fact the process is going to die anyway, the OS will clean up any reources left by not calling quitSystem.
// The OpenSim version does not use Havok, it is okay to call shutdown then.
#ifdef OPENSIM
#ifndef HAVOK_TPV
// shut down Havok
LLPhysicsExtensions::quitSystem();
#endif // </FS:ND>
@ -3694,10 +3694,12 @@ LLSD LLAppViewer::getViewerInfo() const
//}
// <FS:CR> FIRE-8273: Add Open-sim indicator to About floater
#ifdef OPENSIM
#if defined OPENSIM
info["BUILD_TYPE"] = LLTrans::getString("FSWithOpensim");
#else
#elif defined HAVOK_TPV
info["BUILD_TYPE"] = LLTrans::getString("FSWithHavok");
#else
info["BUILD_TYPE"] = std::string();
#endif // OPENSIM
// </FS:CR>
info["SKIN"] = gSavedSettings.getString("FSInternalSkinCurrent");

View File

@ -410,7 +410,7 @@ BOOL LLFloaterModelPreview::postBuild()
{
validate_url = llformat("http://secondlife.%s.lindenlab.com/my/account/mesh.php", current_grid.c_str());
}
#ifdef OPENSIM // <FS:AW optional opensim support>
#ifndef HAVOK_TPV // <FS:AW optional opensim support>
else
{
// TODO: Opensim: Set it to something reasonable

View File

@ -58,7 +58,7 @@
#include "pipeline.h"
// <FS:CR> For NoHavok alert
#ifdef OPENSIM
#ifndef HAVOK_TPV
#include "llnotificationsutil.h"
#endif // OPENSIM
// </FS:CR>
@ -251,7 +251,7 @@ void LLFloaterPathfindingConsole::onOpen(const LLSD& pKey)
switchIntoTestPathMode();
}
// <FS:CR> Show an alert dialog if using the Opensim viewer as functionality will be limited without Havok
#ifdef OPENSIM
#ifndef HAVOK_TPV
LLSD args;
args["FEATURE"] = getString("no_havok");
LLNotificationsUtil::add("NoHavok", args);