*Update to Trinity 878.

--HG--
branch : trunk
This commit is contained in:
megamage
2009-01-17 13:42:41 -06:00
56 changed files with 3195 additions and 126 deletions
+53
View File
@@ -0,0 +1,53 @@
########### next target ###############
SET(trinity-core_SRCS
CliRunnable.cpp
CliRunnable.h
Main.cpp
Master.cpp
Master.h
RASocket.cpp
RASocket.h
WorldRunnable.cpp
WorldRunnable.h
)
add_executable(trinity-core ${trinity-core_SRCS})
add_definitions(
-D_TRINITY_CORE_CONFIG='"${CONF_DIR}/trinitycore.conf"'
)
IF (DO_MYSQL)
SET_TARGET_PROPERTIES(trinity-core PROPERTIES LINK_FLAGS "-pthread")
ENDIF(DO_MYSQL)
target_link_libraries(
trinity-core
game
shared
zlib
trinityframework
trinitysockets
trinitydatabase
trinityauth
trinityconfig
vmaps
ZThread
g3dlite
${SCRIPT_LIB}
${MYSQL_LIBRARIES}
${POSTGRE_LIBS}
${SSLLIB}
${ACE_LIBRARY}
${ZLIB}
)
install(TARGETS trinity-core DESTINATION bin)
########### install files ###############
install(FILES trinitycore.conf.dist DESTINATION etc)
+11 -2
View File
@@ -1,4 +1,4 @@
/*
/*
* Copyright (C) 2005-2008 MaNGOS <http://www.mangosproject.org/>
*
* Copyright (C) 2008 Trinity <http://www.trinitycore.org/>
@@ -21,6 +21,8 @@
/// \addtogroup Trinityd Trinity Daemon
/// @{
/// \file
#include "SystemConfig.h"
#include "revision.h"
#include "Common.h"
#include "Database/DatabaseEnv.h"
@@ -62,6 +64,7 @@ uint32 realmID; ///< Id of the realm
void usage(const char *prog)
{
sLog.outString("Usage: \n %s [<options>]\n"
" --version print version and exist\n\r"
" -c config_file use config_file as configuration file\n\r"
#ifdef WIN32
" Running as service functions:\n\r"
@@ -92,6 +95,12 @@ extern int main(int argc, char **argv)
cfg_file = argv[c];
}
if( strcmp(argv[c],"--version") == 0)
{
printf("%s\n", _FULLVERSION);
return 0;
}
#ifdef WIN32
////////////
//Services//
@@ -138,7 +147,7 @@ extern int main(int argc, char **argv)
return 1;
}
sLog.outString("Using configuration file %s.", cfg_file);
uint32 confVersion = sConfig.GetIntDefault("ConfVersion", 0);
if (confVersion < _TRINITY_CORE_CONFVER)
{