Commit f6a04a81 authored by Jonas Stienen's avatar Jonas Stienen

Merge branch 'develop' of https://git.rwth-aachen.de/ita/VAServer into develop

parents 24b91ad8 9ec3484a
HTML
*.bat
*.mat
*.pdf
*.dll
*.exe
*.so*
Thumbs.db
.DS_Store
*.asv
*.wav
*.xlsx
*.docx
*.dll
*.csv
*.h5
*.ita
*.fig
*.png
*.jpeg
*.sofa
*.spk
*.unv
*.stl
svnaccess
*.lib
*.exp
......@@ -8,6 +8,13 @@ vista_use_package( VABase REQUIRED FIND_DEPENDENCIES )
vista_use_package( VACore REQUIRED FIND_DEPENDENCIES )
vista_use_package( VANet REQUIRED FIND_DEPENDENCIES )
if( NOT ITA_VASERVER_INSTALL_WITH_DLLS )
set( ITA_VASERVER_INSTALL_WITH_DLLS ON CACHE BOOL "Install VAServer with depending DLLs (use this switch with care)" )
endif( )
if( NOT ITA_VASERVER_DEPLOY_WITH_COMMON_SCRIPTS )
set( ITA_VASERVER_DEPLOY_WITH_COMMON_SCRIPTS ON CACHE BOOL "Install VAServer starting scripts" )
endif( )
# compiler
if( ITA_CORE_LIBS_BUILD_STATIC )
......@@ -25,6 +32,15 @@ if( ITA_VISTA_BUILD_STATIC )
endif( )
endif( )
# preprocessor
if( NOT WIN32 )
add_definitions( -std=gnu++11 )
list( APPEND VISTA_USE_PACKAGE_LIBRARIES ncurses )
message( ${VISTA_USE_PACKAGE_LIBRARIES} )
endif( )
# linker
add_executable( VAServer VAServer.cpp )
target_link_libraries( VAServer ${VISTA_USE_PACKAGE_LIBRARIES} ${VISTAINTERPROCCOMM_ADDITIONAL_DEPENDENCIES} )
......@@ -44,6 +60,20 @@ vista_create_default_info_file( VAServer )
set_property( TARGET VAServer PROPERTY FOLDER "VA/Apps" )
# deploy
if( ITA_VASERVER_DEPLOY_WITH_COMMON_SCRIPTS )
if( WIN32 )
install( FILES "run_VAServer.bat" DESTINATION "." )
else( )
install( FILES "run_VAServer.sh" DESTINATION "." )
endif( )
endif( )
if( ITA_VA_INSTALL_WITH_DLLS OR ITA_VASERVER_INSTALL_WITH_DLLS )
vista_install_all_dlls( bin )
endif( )
# dev
if( MSVC )
......
......@@ -12,7 +12,12 @@
*/
// STL includes
#ifdef WIN32
#include <conio.h>
#else
#include <ncurses.h>
#endif
#include <iostream>
// ITA includes
......@@ -195,14 +200,14 @@ int main( int argc, char* argv[] )
{
CVAStruct oArgs, oReturn, oNewArgs;
oArgs[ "command" ] = "get";
oArgs[ "debug" ] = CVAStruct();
oArgs[ "debug" ][ "loglevel" ] = true;
oArgs[ std::string("debug") ] = CVAStruct();
oArgs[ std::string("debug") ][ std::string("loglevel") ] = true;
pServer->GetCoreInstance()->CallModule( "VACore", oArgs, oReturn );
int iCurrentLogLevel = oReturn[ "debug" ][ "loglevel" ];
int iCurrentLogLevel = oReturn[ std::string("debug") ][ std::string("loglevel") ];
int iNewLogLevel = int( iCurrentLogLevel + 1 ) % 6;
oNewArgs[ "command" ] = "set";
oNewArgs[ "debug" ] = CVAStruct();
oNewArgs[ "debug" ][ "loglevel" ] = iNewLogLevel;
oNewArgs[ std::string("debug") ][ std::string("loglevel") ] = iNewLogLevel;
pServer->GetCoreInstance()->CallModule( "VACore", oNewArgs, oReturn );
cout << "Switched to log level: " << IVACore::GetLogLevelStr( iNewLogLevel ) << endl;
......
@rem Example how to start the VA server (with configuration file)
bin\VAServer.exe localhost:12340 conf\VACore.ini
\ No newline at end of file
# Example how to start the VA server (with configuration file)
./bin/VAServer localhost:12340 ./conf/VACore.ini
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment