diff --git a/CMakeLists.txt b/CMakeLists.txt index 90e896b9e..67f02007c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -105,12 +105,6 @@ IF(UNIX) ENDIF(CMAKE_SYSTEM_NAME MATCHES "Darwin") ENDIF(UNIX) -#use stdint.h types if they exist for this platform (we have to guess otherwise) -CHECK_INCLUDE_FILES(stdint.h HAVE_STDINT_H) -IF(HAVE_STDINT_H) - ADD_DEFINITIONS(-DEQEMU_USE_STDINT) -ENDIF(HAVE_STDINT_H) - #debug level, 5 is default. Most people wont ever change this but it's there if you want to SET(EQEMU_DEBUG_LEVEL 5 CACHE STRING "EQEmu debug level: 0 - Quiet mode Errors to file Status and Normal ignored @@ -231,7 +225,7 @@ OPTION(EQEMU_BUILD_SERVER "Build the game server." ON) OPTION(EQEMU_BUILD_LOGIN "Build the login server." OFF) OPTION(EQEMU_BUILD_TESTS "Build utility tests." OFF) OPTION(EQEMU_BUILD_PERL "Build Perl parser." ON) -OPTION(EQEMU_BUILD_LUA "Build Lua parser." OFF) +OPTION(EQEMU_BUILD_LUA "Build Lua parser." ON) OPTION(EQEMU_BUILD_CLIENT_FILES "Build Client Inport/Export Data Programs." ON) #C++11 stuff @@ -289,7 +283,7 @@ IF(EQEMU_BUILD_LUA) SET(BOOST_ROOT "${CMAKE_CURRENT_SOURCE_DIR}/dependencies/boost") FIND_PACKAGE(Boost REQUIRED) - INCLUDE_DIRECTORIES("${LUA_INCLUDE_DIR}" "${Boost_INCLUDE_DIRS}" "luabind") + INCLUDE_DIRECTORIES("${LUA_INCLUDE_DIR}" "${Boost_INCLUDE_DIRS}" "dependencies/luabind") OPTION(EQEMU_SANITIZE_LUA_LIBS "Sanitize Lua Libraries (Remove OS and IO standard libraries from being able to run)." ON) IF(EQEMU_SANITIZE_LUA_LIBS) @@ -299,10 +293,6 @@ ENDIF(EQEMU_BUILD_LUA) INCLUDE_DIRECTORIES("${ZLIB_INCLUDE_DIRS}" "${MySQL_INCLUDE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}/common/glm/glm") -IF(EQEMU_BUILD_LUA) - ADD_SUBDIRECTORY(luabind) -ENDIF(EQEMU_BUILD_LUA) - IF(EQEMU_BUILD_SERVER OR EQEMU_BUILD_LOGIN OR EQEMU_BUILD_TESTS) ADD_SUBDIRECTORY(common) ENDIF(EQEMU_BUILD_SERVER OR EQEMU_BUILD_LOGIN OR EQEMU_BUILD_TESTS) @@ -312,8 +302,9 @@ IF(EQEMU_BUILD_SERVER) ADD_SUBDIRECTORY(zone) ADD_SUBDIRECTORY(ucs) ADD_SUBDIRECTORY(queryserv) - ADD_SUBDIRECTORY(web_interface) ADD_SUBDIRECTORY(eqlaunch) + ADD_SUBDIRECTORY(dependencies) + ADD_SUBDIRECTORY(web_interface) ENDIF(EQEMU_BUILD_SERVER) IF(EQEMU_BUILD_LOGIN) ADD_SUBDIRECTORY(loginserver) diff --git a/client_files/export/CMakeLists.txt b/client_files/export/CMakeLists.txt index 851aa05fb..6d0807e01 100644 --- a/client_files/export/CMakeLists.txt +++ b/client_files/export/CMakeLists.txt @@ -11,7 +11,7 @@ ADD_EXECUTABLE(export_client_files ${export_sources} ${export_headers}) INSTALL(TARGETS export_client_files RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) -TARGET_LINK_LIBRARIES(export_client_files Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(export_client_files common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(export_client_files PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -33,4 +33,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/client_files/import/CMakeLists.txt b/client_files/import/CMakeLists.txt index 0b6c45b57..59e1a0ac4 100644 --- a/client_files/import/CMakeLists.txt +++ b/client_files/import/CMakeLists.txt @@ -11,7 +11,7 @@ ADD_EXECUTABLE(import_client_files ${import_sources} ${import_headers}) INSTALL(TARGETS import_client_files RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) -TARGET_LINK_LIBRARIES(import_client_files Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(import_client_files common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(import_client_files PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -33,4 +33,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/common/CMakeLists.txt b/common/CMakeLists.txt index 35cb7eb7f..bcd054098 100644 --- a/common/CMakeLists.txt +++ b/common/CMakeLists.txt @@ -315,11 +315,11 @@ SOURCE_GROUP(TinyXML FILES INCLUDE_DIRECTORIES(Patches SocketLib StackWalker TinyXML) -ADD_LIBRARY(Common ${common_sources} ${common_headers}) +ADD_LIBRARY(common ${common_sources} ${common_headers}) IF(UNIX) ADD_DEFINITIONS(-fPIC) SET_SOURCE_FILES_PROPERTIES("patches/SoD.cpp" "patches/SoF.cpp" "patches/RoF.cpp" "patches/Underfoot.cpp" PROPERTIES COMPILE_FLAGS -O0) ENDIF(UNIX) -SET(LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/common/EQEmuConfig.cpp b/common/EQEmuConfig.cpp index d60d8df82..b3859faba 100644 --- a/common/EQEmuConfig.cpp +++ b/common/EQEmuConfig.cpp @@ -26,7 +26,7 @@ EQEmuConfig *EQEmuConfig::_config = nullptr; void EQEmuConfig::do_world(TiXmlElement *ele) { const char *text; - TiXmlElement * sub_ele;; + TiXmlElement * sub_ele; text= ParseTextBlock(ele,"shortname"); if (text) @@ -217,6 +217,27 @@ void EQEmuConfig::do_qsdatabase(TiXmlElement *ele) { QSDatabaseDB=text; } +void EQEmuConfig::do_web_interface(TiXmlElement *ele) { + const char *text; + + text = ParseTextBlock(ele, "port", true); + if (text) + WebInterfacePort = atoi(text); + + text = ParseTextBlock(ele, "cert", true); + if (text) + WebInterfaceCert = text; + + text = ParseTextBlock(ele, "priv_key", true); + if (text) + WebInterfacePrivKey = text; + + TiXmlElement *sub_ele = ele->FirstChildElement("ssl"); + if (sub_ele != nullptr) { + WebInterfaceUseSSL = true; + } +} + void EQEmuConfig::do_zones(TiXmlElement *ele) { const char *text; TiXmlElement *sub_ele; @@ -372,6 +393,14 @@ std::string EQEmuConfig::GetByName(const std::string &var_name) const { return(QSDatabaseDB); if(var_name == "QSDatabasePort") return(itoa(QSDatabasePort)); + if (var_name == "WebInterfacePort") + return(itoa(WebInterfacePort)); + if (var_name == "WebInterfaceUseSSL") + return(itoa(WebInterfaceUseSSL)); + if (var_name == "WebInterfaceCert") + return(WebInterfaceCert); + if (var_name == "WebInterfacePrivKey") + return(WebInterfacePrivKey); if(var_name == "SpellsFile") return(SpellsFile); if(var_name == "OpCodesFile") @@ -433,6 +462,10 @@ void EQEmuConfig::Dump() const std::cout << "QSDatabasePassword = " << QSDatabasePassword << std::endl; std::cout << "QSDatabaseDB = " << QSDatabaseDB << std::endl; std::cout << "QSDatabasePort = " << QSDatabasePort << std::endl; + std::cout << "WebInterfacePort = " << WebInterfacePort << std::endl; + std::cout << "WebInterfaceUseSSL = " << WebInterfaceUseSSL << std::endl; + std::cout << "WebInterfaceCert = " << WebInterfaceCert << std::endl; + std::cout << "WebInterfacePrivKey = " << WebInterfacePrivKey << std::endl; std::cout << "SpellsFile = " << SpellsFile << std::endl; std::cout << "OpCodesFile = " << OpCodesFile << std::endl; std::cout << "EQTimeFile = " << EQTimeFile << std::endl; @@ -443,6 +476,5 @@ void EQEmuConfig::Dump() const std::cout << "ZonePortLow = " << ZonePortLow << std::endl; std::cout << "ZonePortHigh = " << ZonePortHigh << std::endl; std::cout << "DefaultStatus = " << (int)DefaultStatus << std::endl; -// std::cout << "DynamicCount = " << DynamicCount << std::endl; } diff --git a/common/EQEmuConfig.h b/common/EQEmuConfig.h index a3ab021a4..2871117c3 100644 --- a/common/EQEmuConfig.h +++ b/common/EQEmuConfig.h @@ -75,6 +75,12 @@ public: std::string QSDatabaseDB; uint16 QSDatabasePort; + // from + uint16 WebInterfacePort; + bool WebInterfaceUseSSL; + std::string WebInterfaceCert; + std::string WebInterfacePrivKey; + // From std::string SpellsFile; std::string OpCodesFile; @@ -158,6 +164,12 @@ protected: QSDatabasePassword="eq"; QSDatabaseDB="eq"; + // web_interface + WebInterfacePort = 9081; + WebInterfaceUseSSL = false; + WebInterfaceCert = ""; + WebInterfacePrivKey = ""; + // Files SpellsFile="spells_us.txt"; OpCodesFile="opcodes.conf"; diff --git a/common/EQEmuConfig_elements.h b/common/EQEmuConfig_elements.h index 9dae490ae..2a8900fce 100644 --- a/common/EQEmuConfig_elements.h +++ b/common/EQEmuConfig_elements.h @@ -4,6 +4,7 @@ ELEMENT(mailserver) ELEMENT(zones) ELEMENT(database) ELEMENT(qsdatabase) +ELEMENT(web_interface) ELEMENT(files) ELEMENT(directories) ELEMENT(launcher) diff --git a/common/types.h b/common/types.h index a26a65956..9064b67e0 100644 --- a/common/types.h +++ b/common/types.h @@ -18,7 +18,6 @@ #ifndef TYPES_H #define TYPES_H -#ifdef EQEMU_USE_STDINT #include typedef uint8_t byte; typedef uint8_t uint8; @@ -29,29 +28,6 @@ typedef int8_t int8; typedef int16_t int16; typedef int32_t int32; typedef int64_t int64; -#else -typedef unsigned char byte; -typedef unsigned char uint8; -typedef signed char int8; -typedef unsigned short uint16; -typedef signed short int16; -typedef unsigned int uint32; -typedef signed int int32; - -#ifdef _WINDOWS - #if defined(_INTEGRAL_MAX_BITS) && _INTEGRAL_MAX_BITS >= 64 - typedef unsigned __int64 uint64; - typedef unsigned __int64 uint64; - typedef signed __int64 int64; - #else - #error __int64 not supported - #endif -#else -typedef unsigned long long uint64; -typedef unsigned long long uint64; -typedef signed long long int64; -#endif -#endif #ifdef _WINDOWS #pragma warning( disable : 4200 ) diff --git a/dependencies/.gitignore b/dependencies/.gitignore index a0653e77d..44fe390e2 100644 --- a/dependencies/.gitignore +++ b/dependencies/.gitignore @@ -1,2 +1,8 @@ -*.* -* \ No newline at end of file +boost/ +luaj_x86/ +luaj_x64/ +mysql_x86/ +mysql_x64/ +zlib_x86/ +zlib_x64/ +cyassl/ \ No newline at end of file diff --git a/dependencies/CMakeLists.txt b/dependencies/CMakeLists.txt new file mode 100644 index 000000000..f2f685b95 --- /dev/null +++ b/dependencies/CMakeLists.txt @@ -0,0 +1,6 @@ +CMAKE_MINIMUM_REQUIRED(VERSION 2.8) + +IF(EQEMU_BUILD_LUA) + ADD_SUBDIRECTORY(luabind) +ENDIF(EQEMU_BUILD_LUA) + diff --git a/luabind/CMakeLists.txt b/dependencies/luabind/CMakeLists.txt similarity index 93% rename from luabind/CMakeLists.txt rename to dependencies/luabind/CMakeLists.txt index 19d694203..5ca1a930a 100644 --- a/luabind/CMakeLists.txt +++ b/dependencies/luabind/CMakeLists.txt @@ -31,4 +31,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(LIBRARY_OUTPUT_PATH ../Bin) +SET(LIBRARY_OUTPUT_PATH ../../bin) diff --git a/luabind/luabind/adopt_policy.hpp b/dependencies/luabind/luabind/adopt_policy.hpp similarity index 100% rename from luabind/luabind/adopt_policy.hpp rename to dependencies/luabind/luabind/adopt_policy.hpp diff --git a/luabind/luabind/back_reference.hpp b/dependencies/luabind/luabind/back_reference.hpp similarity index 100% rename from luabind/luabind/back_reference.hpp rename to dependencies/luabind/luabind/back_reference.hpp diff --git a/luabind/luabind/back_reference_fwd.hpp b/dependencies/luabind/luabind/back_reference_fwd.hpp similarity index 100% rename from luabind/luabind/back_reference_fwd.hpp rename to dependencies/luabind/luabind/back_reference_fwd.hpp diff --git a/luabind/luabind/class.hpp b/dependencies/luabind/luabind/class.hpp similarity index 100% rename from luabind/luabind/class.hpp rename to dependencies/luabind/luabind/class.hpp diff --git a/luabind/luabind/class_info.hpp b/dependencies/luabind/luabind/class_info.hpp similarity index 100% rename from luabind/luabind/class_info.hpp rename to dependencies/luabind/luabind/class_info.hpp diff --git a/luabind/luabind/config.hpp b/dependencies/luabind/luabind/config.hpp similarity index 100% rename from luabind/luabind/config.hpp rename to dependencies/luabind/luabind/config.hpp diff --git a/luabind/luabind/container_policy.hpp b/dependencies/luabind/luabind/container_policy.hpp similarity index 100% rename from luabind/luabind/container_policy.hpp rename to dependencies/luabind/luabind/container_policy.hpp diff --git a/luabind/luabind/copy_policy.hpp b/dependencies/luabind/luabind/copy_policy.hpp similarity index 100% rename from luabind/luabind/copy_policy.hpp rename to dependencies/luabind/luabind/copy_policy.hpp diff --git a/luabind/luabind/dependency_policy.hpp b/dependencies/luabind/luabind/dependency_policy.hpp similarity index 100% rename from luabind/luabind/dependency_policy.hpp rename to dependencies/luabind/luabind/dependency_policy.hpp diff --git a/luabind/luabind/detail/calc_arity.hpp b/dependencies/luabind/luabind/detail/calc_arity.hpp similarity index 100% rename from luabind/luabind/detail/calc_arity.hpp rename to dependencies/luabind/luabind/detail/calc_arity.hpp diff --git a/luabind/luabind/detail/call.hpp b/dependencies/luabind/luabind/detail/call.hpp similarity index 100% rename from luabind/luabind/detail/call.hpp rename to dependencies/luabind/luabind/detail/call.hpp diff --git a/luabind/luabind/detail/call_function.hpp b/dependencies/luabind/luabind/detail/call_function.hpp similarity index 100% rename from luabind/luabind/detail/call_function.hpp rename to dependencies/luabind/luabind/detail/call_function.hpp diff --git a/luabind/luabind/detail/call_member.hpp b/dependencies/luabind/luabind/detail/call_member.hpp similarity index 100% rename from luabind/luabind/detail/call_member.hpp rename to dependencies/luabind/luabind/detail/call_member.hpp diff --git a/luabind/luabind/detail/call_operator_iterate.hpp b/dependencies/luabind/luabind/detail/call_operator_iterate.hpp similarity index 100% rename from luabind/luabind/detail/call_operator_iterate.hpp rename to dependencies/luabind/luabind/detail/call_operator_iterate.hpp diff --git a/luabind/luabind/detail/class_cache.hpp b/dependencies/luabind/luabind/detail/class_cache.hpp similarity index 100% rename from luabind/luabind/detail/class_cache.hpp rename to dependencies/luabind/luabind/detail/class_cache.hpp diff --git a/luabind/luabind/detail/class_registry.hpp b/dependencies/luabind/luabind/detail/class_registry.hpp similarity index 100% rename from luabind/luabind/detail/class_registry.hpp rename to dependencies/luabind/luabind/detail/class_registry.hpp diff --git a/luabind/luabind/detail/class_rep.hpp b/dependencies/luabind/luabind/detail/class_rep.hpp similarity index 100% rename from luabind/luabind/detail/class_rep.hpp rename to dependencies/luabind/luabind/detail/class_rep.hpp diff --git a/luabind/luabind/detail/compute_score.hpp b/dependencies/luabind/luabind/detail/compute_score.hpp similarity index 100% rename from luabind/luabind/detail/compute_score.hpp rename to dependencies/luabind/luabind/detail/compute_score.hpp diff --git a/luabind/luabind/detail/constructor.hpp b/dependencies/luabind/luabind/detail/constructor.hpp similarity index 100% rename from luabind/luabind/detail/constructor.hpp rename to dependencies/luabind/luabind/detail/constructor.hpp diff --git a/luabind/luabind/detail/conversion_storage.hpp b/dependencies/luabind/luabind/detail/conversion_storage.hpp similarity index 100% rename from luabind/luabind/detail/conversion_storage.hpp rename to dependencies/luabind/luabind/detail/conversion_storage.hpp diff --git a/luabind/luabind/detail/convert_to_lua.hpp b/dependencies/luabind/luabind/detail/convert_to_lua.hpp similarity index 100% rename from luabind/luabind/detail/convert_to_lua.hpp rename to dependencies/luabind/luabind/detail/convert_to_lua.hpp diff --git a/luabind/luabind/detail/debug.hpp b/dependencies/luabind/luabind/detail/debug.hpp similarity index 100% rename from luabind/luabind/detail/debug.hpp rename to dependencies/luabind/luabind/detail/debug.hpp diff --git a/luabind/luabind/detail/decorate_type.hpp b/dependencies/luabind/luabind/detail/decorate_type.hpp similarity index 100% rename from luabind/luabind/detail/decorate_type.hpp rename to dependencies/luabind/luabind/detail/decorate_type.hpp diff --git a/luabind/luabind/detail/deduce_signature.hpp b/dependencies/luabind/luabind/detail/deduce_signature.hpp similarity index 100% rename from luabind/luabind/detail/deduce_signature.hpp rename to dependencies/luabind/luabind/detail/deduce_signature.hpp diff --git a/luabind/luabind/detail/enum_maker.hpp b/dependencies/luabind/luabind/detail/enum_maker.hpp similarity index 100% rename from luabind/luabind/detail/enum_maker.hpp rename to dependencies/luabind/luabind/detail/enum_maker.hpp diff --git a/luabind/luabind/detail/format_signature.hpp b/dependencies/luabind/luabind/detail/format_signature.hpp similarity index 100% rename from luabind/luabind/detail/format_signature.hpp rename to dependencies/luabind/luabind/detail/format_signature.hpp diff --git a/luabind/luabind/detail/garbage_collector.hpp b/dependencies/luabind/luabind/detail/garbage_collector.hpp similarity index 100% rename from luabind/luabind/detail/garbage_collector.hpp rename to dependencies/luabind/luabind/detail/garbage_collector.hpp diff --git a/luabind/luabind/detail/has_get_pointer.hpp b/dependencies/luabind/luabind/detail/has_get_pointer.hpp similarity index 100% rename from luabind/luabind/detail/has_get_pointer.hpp rename to dependencies/luabind/luabind/detail/has_get_pointer.hpp diff --git a/luabind/luabind/detail/inheritance.hpp b/dependencies/luabind/luabind/detail/inheritance.hpp similarity index 100% rename from luabind/luabind/detail/inheritance.hpp rename to dependencies/luabind/luabind/detail/inheritance.hpp diff --git a/luabind/luabind/detail/instance_holder.hpp b/dependencies/luabind/luabind/detail/instance_holder.hpp similarity index 100% rename from luabind/luabind/detail/instance_holder.hpp rename to dependencies/luabind/luabind/detail/instance_holder.hpp diff --git a/luabind/luabind/detail/is_indirect_const.hpp b/dependencies/luabind/luabind/detail/is_indirect_const.hpp similarity index 100% rename from luabind/luabind/detail/is_indirect_const.hpp rename to dependencies/luabind/luabind/detail/is_indirect_const.hpp diff --git a/luabind/luabind/detail/link_compatibility.hpp b/dependencies/luabind/luabind/detail/link_compatibility.hpp similarity index 100% rename from luabind/luabind/detail/link_compatibility.hpp rename to dependencies/luabind/luabind/detail/link_compatibility.hpp diff --git a/luabind/luabind/detail/make_instance.hpp b/dependencies/luabind/luabind/detail/make_instance.hpp similarity index 100% rename from luabind/luabind/detail/make_instance.hpp rename to dependencies/luabind/luabind/detail/make_instance.hpp diff --git a/luabind/luabind/detail/most_derived.hpp b/dependencies/luabind/luabind/detail/most_derived.hpp similarity index 100% rename from luabind/luabind/detail/most_derived.hpp rename to dependencies/luabind/luabind/detail/most_derived.hpp diff --git a/luabind/luabind/detail/object_call.hpp b/dependencies/luabind/luabind/detail/object_call.hpp similarity index 100% rename from luabind/luabind/detail/object_call.hpp rename to dependencies/luabind/luabind/detail/object_call.hpp diff --git a/luabind/luabind/detail/object_funs.hpp b/dependencies/luabind/luabind/detail/object_funs.hpp similarity index 100% rename from luabind/luabind/detail/object_funs.hpp rename to dependencies/luabind/luabind/detail/object_funs.hpp diff --git a/luabind/luabind/detail/object_rep.hpp b/dependencies/luabind/luabind/detail/object_rep.hpp similarity index 100% rename from luabind/luabind/detail/object_rep.hpp rename to dependencies/luabind/luabind/detail/object_rep.hpp diff --git a/luabind/luabind/detail/open.hpp b/dependencies/luabind/luabind/detail/open.hpp similarity index 100% rename from luabind/luabind/detail/open.hpp rename to dependencies/luabind/luabind/detail/open.hpp diff --git a/luabind/luabind/detail/operator_id.hpp b/dependencies/luabind/luabind/detail/operator_id.hpp similarity index 100% rename from luabind/luabind/detail/operator_id.hpp rename to dependencies/luabind/luabind/detail/operator_id.hpp diff --git a/luabind/luabind/detail/other.hpp b/dependencies/luabind/luabind/detail/other.hpp similarity index 100% rename from luabind/luabind/detail/other.hpp rename to dependencies/luabind/luabind/detail/other.hpp diff --git a/luabind/luabind/detail/pcall.hpp b/dependencies/luabind/luabind/detail/pcall.hpp similarity index 100% rename from luabind/luabind/detail/pcall.hpp rename to dependencies/luabind/luabind/detail/pcall.hpp diff --git a/luabind/luabind/detail/pointee_sizeof.hpp b/dependencies/luabind/luabind/detail/pointee_sizeof.hpp similarity index 100% rename from luabind/luabind/detail/pointee_sizeof.hpp rename to dependencies/luabind/luabind/detail/pointee_sizeof.hpp diff --git a/luabind/luabind/detail/pointee_typeid.hpp b/dependencies/luabind/luabind/detail/pointee_typeid.hpp similarity index 100% rename from luabind/luabind/detail/pointee_typeid.hpp rename to dependencies/luabind/luabind/detail/pointee_typeid.hpp diff --git a/luabind/luabind/detail/policy.hpp b/dependencies/luabind/luabind/detail/policy.hpp similarity index 100% rename from luabind/luabind/detail/policy.hpp rename to dependencies/luabind/luabind/detail/policy.hpp diff --git a/luabind/luabind/detail/primitives.hpp b/dependencies/luabind/luabind/detail/primitives.hpp similarity index 100% rename from luabind/luabind/detail/primitives.hpp rename to dependencies/luabind/luabind/detail/primitives.hpp diff --git a/luabind/luabind/detail/property.hpp b/dependencies/luabind/luabind/detail/property.hpp similarity index 100% rename from luabind/luabind/detail/property.hpp rename to dependencies/luabind/luabind/detail/property.hpp diff --git a/luabind/luabind/detail/ref.hpp b/dependencies/luabind/luabind/detail/ref.hpp similarity index 100% rename from luabind/luabind/detail/ref.hpp rename to dependencies/luabind/luabind/detail/ref.hpp diff --git a/luabind/luabind/detail/signature_match.hpp b/dependencies/luabind/luabind/detail/signature_match.hpp similarity index 100% rename from luabind/luabind/detail/signature_match.hpp rename to dependencies/luabind/luabind/detail/signature_match.hpp diff --git a/luabind/luabind/detail/stack_utils.hpp b/dependencies/luabind/luabind/detail/stack_utils.hpp similarity index 100% rename from luabind/luabind/detail/stack_utils.hpp rename to dependencies/luabind/luabind/detail/stack_utils.hpp diff --git a/luabind/luabind/detail/typetraits.hpp b/dependencies/luabind/luabind/detail/typetraits.hpp similarity index 100% rename from luabind/luabind/detail/typetraits.hpp rename to dependencies/luabind/luabind/detail/typetraits.hpp diff --git a/luabind/luabind/detail/yes_no.hpp b/dependencies/luabind/luabind/detail/yes_no.hpp similarity index 100% rename from luabind/luabind/detail/yes_no.hpp rename to dependencies/luabind/luabind/detail/yes_no.hpp diff --git a/luabind/luabind/discard_result_policy.hpp b/dependencies/luabind/luabind/discard_result_policy.hpp similarity index 100% rename from luabind/luabind/discard_result_policy.hpp rename to dependencies/luabind/luabind/discard_result_policy.hpp diff --git a/luabind/luabind/error.hpp b/dependencies/luabind/luabind/error.hpp similarity index 100% rename from luabind/luabind/error.hpp rename to dependencies/luabind/luabind/error.hpp diff --git a/luabind/luabind/exception_handler.hpp b/dependencies/luabind/luabind/exception_handler.hpp similarity index 100% rename from luabind/luabind/exception_handler.hpp rename to dependencies/luabind/luabind/exception_handler.hpp diff --git a/luabind/luabind/from_stack.hpp b/dependencies/luabind/luabind/from_stack.hpp similarity index 100% rename from luabind/luabind/from_stack.hpp rename to dependencies/luabind/luabind/from_stack.hpp diff --git a/luabind/luabind/function.hpp b/dependencies/luabind/luabind/function.hpp similarity index 100% rename from luabind/luabind/function.hpp rename to dependencies/luabind/luabind/function.hpp diff --git a/luabind/luabind/get_main_thread.hpp b/dependencies/luabind/luabind/get_main_thread.hpp similarity index 100% rename from luabind/luabind/get_main_thread.hpp rename to dependencies/luabind/luabind/get_main_thread.hpp diff --git a/luabind/luabind/get_pointer.hpp b/dependencies/luabind/luabind/get_pointer.hpp similarity index 100% rename from luabind/luabind/get_pointer.hpp rename to dependencies/luabind/luabind/get_pointer.hpp diff --git a/luabind/luabind/handle.hpp b/dependencies/luabind/luabind/handle.hpp similarity index 100% rename from luabind/luabind/handle.hpp rename to dependencies/luabind/luabind/handle.hpp diff --git a/luabind/luabind/iterator_policy.hpp b/dependencies/luabind/luabind/iterator_policy.hpp similarity index 100% rename from luabind/luabind/iterator_policy.hpp rename to dependencies/luabind/luabind/iterator_policy.hpp diff --git a/luabind/luabind/lua502.hpp b/dependencies/luabind/luabind/lua502.hpp similarity index 100% rename from luabind/luabind/lua502.hpp rename to dependencies/luabind/luabind/lua502.hpp diff --git a/luabind/luabind/lua_include.hpp b/dependencies/luabind/luabind/lua_include.hpp similarity index 100% rename from luabind/luabind/lua_include.hpp rename to dependencies/luabind/luabind/lua_include.hpp diff --git a/luabind/luabind/luabind.hpp b/dependencies/luabind/luabind/luabind.hpp similarity index 100% rename from luabind/luabind/luabind.hpp rename to dependencies/luabind/luabind/luabind.hpp diff --git a/luabind/luabind/make_function.hpp b/dependencies/luabind/luabind/make_function.hpp similarity index 100% rename from luabind/luabind/make_function.hpp rename to dependencies/luabind/luabind/make_function.hpp diff --git a/luabind/luabind/nil.hpp b/dependencies/luabind/luabind/nil.hpp similarity index 100% rename from luabind/luabind/nil.hpp rename to dependencies/luabind/luabind/nil.hpp diff --git a/luabind/luabind/object.hpp b/dependencies/luabind/luabind/object.hpp similarity index 100% rename from luabind/luabind/object.hpp rename to dependencies/luabind/luabind/object.hpp diff --git a/luabind/luabind/open.hpp b/dependencies/luabind/luabind/open.hpp similarity index 100% rename from luabind/luabind/open.hpp rename to dependencies/luabind/luabind/open.hpp diff --git a/luabind/luabind/operator.hpp b/dependencies/luabind/luabind/operator.hpp similarity index 100% rename from luabind/luabind/operator.hpp rename to dependencies/luabind/luabind/operator.hpp diff --git a/luabind/luabind/out_value_policy.hpp b/dependencies/luabind/luabind/out_value_policy.hpp similarity index 100% rename from luabind/luabind/out_value_policy.hpp rename to dependencies/luabind/luabind/out_value_policy.hpp diff --git a/luabind/luabind/prefix.hpp b/dependencies/luabind/luabind/prefix.hpp similarity index 100% rename from luabind/luabind/prefix.hpp rename to dependencies/luabind/luabind/prefix.hpp diff --git a/luabind/luabind/raw_policy.hpp b/dependencies/luabind/luabind/raw_policy.hpp similarity index 100% rename from luabind/luabind/raw_policy.hpp rename to dependencies/luabind/luabind/raw_policy.hpp diff --git a/luabind/luabind/return_reference_to_policy.hpp b/dependencies/luabind/luabind/return_reference_to_policy.hpp similarity index 100% rename from luabind/luabind/return_reference_to_policy.hpp rename to dependencies/luabind/luabind/return_reference_to_policy.hpp diff --git a/luabind/luabind/scope.hpp b/dependencies/luabind/luabind/scope.hpp similarity index 100% rename from luabind/luabind/scope.hpp rename to dependencies/luabind/luabind/scope.hpp diff --git a/luabind/luabind/shared_ptr_converter.hpp b/dependencies/luabind/luabind/shared_ptr_converter.hpp similarity index 100% rename from luabind/luabind/shared_ptr_converter.hpp rename to dependencies/luabind/luabind/shared_ptr_converter.hpp diff --git a/luabind/luabind/tag_function.hpp b/dependencies/luabind/luabind/tag_function.hpp similarity index 100% rename from luabind/luabind/tag_function.hpp rename to dependencies/luabind/luabind/tag_function.hpp diff --git a/luabind/luabind/typeid.hpp b/dependencies/luabind/luabind/typeid.hpp similarity index 100% rename from luabind/luabind/typeid.hpp rename to dependencies/luabind/luabind/typeid.hpp diff --git a/luabind/luabind/value_wrapper.hpp b/dependencies/luabind/luabind/value_wrapper.hpp similarity index 100% rename from luabind/luabind/value_wrapper.hpp rename to dependencies/luabind/luabind/value_wrapper.hpp diff --git a/luabind/luabind/version.hpp b/dependencies/luabind/luabind/version.hpp similarity index 100% rename from luabind/luabind/version.hpp rename to dependencies/luabind/luabind/version.hpp diff --git a/luabind/luabind/weak_ref.hpp b/dependencies/luabind/luabind/weak_ref.hpp similarity index 100% rename from luabind/luabind/weak_ref.hpp rename to dependencies/luabind/luabind/weak_ref.hpp diff --git a/luabind/luabind/wrapper_base.hpp b/dependencies/luabind/luabind/wrapper_base.hpp similarity index 100% rename from luabind/luabind/wrapper_base.hpp rename to dependencies/luabind/luabind/wrapper_base.hpp diff --git a/luabind/luabind/yield_policy.hpp b/dependencies/luabind/luabind/yield_policy.hpp similarity index 100% rename from luabind/luabind/yield_policy.hpp rename to dependencies/luabind/luabind/yield_policy.hpp diff --git a/luabind/src/class.cpp b/dependencies/luabind/src/class.cpp similarity index 100% rename from luabind/src/class.cpp rename to dependencies/luabind/src/class.cpp diff --git a/luabind/src/class_info.cpp b/dependencies/luabind/src/class_info.cpp similarity index 100% rename from luabind/src/class_info.cpp rename to dependencies/luabind/src/class_info.cpp diff --git a/luabind/src/class_registry.cpp b/dependencies/luabind/src/class_registry.cpp similarity index 100% rename from luabind/src/class_registry.cpp rename to dependencies/luabind/src/class_registry.cpp diff --git a/luabind/src/class_rep.cpp b/dependencies/luabind/src/class_rep.cpp similarity index 100% rename from luabind/src/class_rep.cpp rename to dependencies/luabind/src/class_rep.cpp diff --git a/luabind/src/create_class.cpp b/dependencies/luabind/src/create_class.cpp similarity index 100% rename from luabind/src/create_class.cpp rename to dependencies/luabind/src/create_class.cpp diff --git a/luabind/src/error.cpp b/dependencies/luabind/src/error.cpp similarity index 100% rename from luabind/src/error.cpp rename to dependencies/luabind/src/error.cpp diff --git a/luabind/src/exception_handler.cpp b/dependencies/luabind/src/exception_handler.cpp similarity index 100% rename from luabind/src/exception_handler.cpp rename to dependencies/luabind/src/exception_handler.cpp diff --git a/luabind/src/function.cpp b/dependencies/luabind/src/function.cpp similarity index 100% rename from luabind/src/function.cpp rename to dependencies/luabind/src/function.cpp diff --git a/luabind/src/inheritance.cpp b/dependencies/luabind/src/inheritance.cpp similarity index 100% rename from luabind/src/inheritance.cpp rename to dependencies/luabind/src/inheritance.cpp diff --git a/luabind/src/link_compatibility.cpp b/dependencies/luabind/src/link_compatibility.cpp similarity index 100% rename from luabind/src/link_compatibility.cpp rename to dependencies/luabind/src/link_compatibility.cpp diff --git a/luabind/src/object_rep.cpp b/dependencies/luabind/src/object_rep.cpp similarity index 100% rename from luabind/src/object_rep.cpp rename to dependencies/luabind/src/object_rep.cpp diff --git a/luabind/src/open.cpp b/dependencies/luabind/src/open.cpp similarity index 100% rename from luabind/src/open.cpp rename to dependencies/luabind/src/open.cpp diff --git a/luabind/src/pcall.cpp b/dependencies/luabind/src/pcall.cpp similarity index 100% rename from luabind/src/pcall.cpp rename to dependencies/luabind/src/pcall.cpp diff --git a/luabind/src/scope.cpp b/dependencies/luabind/src/scope.cpp similarity index 100% rename from luabind/src/scope.cpp rename to dependencies/luabind/src/scope.cpp diff --git a/luabind/src/stack_content_by_name.cpp b/dependencies/luabind/src/stack_content_by_name.cpp similarity index 100% rename from luabind/src/stack_content_by_name.cpp rename to dependencies/luabind/src/stack_content_by_name.cpp diff --git a/luabind/src/weak_ref.cpp b/dependencies/luabind/src/weak_ref.cpp similarity index 100% rename from luabind/src/weak_ref.cpp rename to dependencies/luabind/src/weak_ref.cpp diff --git a/luabind/src/wrapper_base.cpp b/dependencies/luabind/src/wrapper_base.cpp similarity index 100% rename from luabind/src/wrapper_base.cpp rename to dependencies/luabind/src/wrapper_base.cpp diff --git a/eqlaunch/CMakeLists.txt b/eqlaunch/CMakeLists.txt index b636a18cf..922522d86 100644 --- a/eqlaunch/CMakeLists.txt +++ b/eqlaunch/CMakeLists.txt @@ -15,7 +15,7 @@ ADD_EXECUTABLE(eqlaunch ${eqlaunch_sources} ${eqlaunch_headers}) INSTALL(TARGETS eqlaunch RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) -TARGET_LINK_LIBRARIES(eqlaunch Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(eqlaunch common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(eqlaunch PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -37,4 +37,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/loginserver/CMakeLists.txt b/loginserver/CMakeLists.txt index 9ded859e5..f09d3043a 100644 --- a/loginserver/CMakeLists.txt +++ b/loginserver/CMakeLists.txt @@ -43,7 +43,7 @@ ADD_EXECUTABLE(loginserver ${eqlogin_sources} ${eqlogin_headers}) INSTALL(TARGETS loginserver RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) -TARGET_LINK_LIBRARIES(loginserver Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE}) +TARGET_LINK_LIBRARIES(loginserver common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE}) IF(MSVC) SET_TARGET_PROPERTIES(loginserver PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -67,4 +67,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/queryserv/CMakeLists.txt b/queryserv/CMakeLists.txt index 33be865e0..3a561da56 100644 --- a/queryserv/CMakeLists.txt +++ b/queryserv/CMakeLists.txt @@ -21,7 +21,7 @@ INSTALL(TARGETS queryserv RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) ADD_DEFINITIONS(-DQSERV) -TARGET_LINK_LIBRARIES(queryserv Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(queryserv common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(queryserv PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -43,4 +43,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/shared_memory/CMakeLists.txt b/shared_memory/CMakeLists.txt index 3d23a1b01..0124af855 100644 --- a/shared_memory/CMakeLists.txt +++ b/shared_memory/CMakeLists.txt @@ -23,7 +23,7 @@ ADD_EXECUTABLE(shared_memory ${shared_memory_sources} ${shared_memory_headers}) INSTALL(TARGETS shared_memory RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) -TARGET_LINK_LIBRARIES(shared_memory Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(shared_memory common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(shared_memory PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -45,4 +45,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index aba365486..5c1e692b5 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -17,7 +17,7 @@ SET(tests_headers ADD_EXECUTABLE(tests ${tests_sources} ${tests_headers}) -TARGET_LINK_LIBRARIES(tests Common cppunit) +TARGET_LINK_LIBRARIES(tests common cppunit) IF(MSVC) SET_TARGET_PROPERTIES(tests PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -39,4 +39,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ../Bin) +SET(EXECUTABLE_OUTPUT_PATH ../bin) diff --git a/tests/cppunit/CMakeLists.txt b/tests/cppunit/CMakeLists.txt index e60e2134f..c93a49fda 100644 --- a/tests/cppunit/CMakeLists.txt +++ b/tests/cppunit/CMakeLists.txt @@ -35,4 +35,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(LIBRARY_OUTPUT_PATH ../../Bin) +SET(LIBRARY_OUTPUT_PATH ../../bin) diff --git a/ucs/CMakeLists.txt b/ucs/CMakeLists.txt index 44681831c..6a26413df 100644 --- a/ucs/CMakeLists.txt +++ b/ucs/CMakeLists.txt @@ -23,7 +23,7 @@ INSTALL(TARGETS ucs RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) ADD_DEFINITIONS(-DUCS) -TARGET_LINK_LIBRARIES(ucs Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(ucs common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(ucs PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -45,4 +45,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/web_interface/CMakeLists.txt b/web_interface/CMakeLists.txt index 632d6d5a8..f13dd3ac9 100644 --- a/web_interface/CMakeLists.txt +++ b/web_interface/CMakeLists.txt @@ -13,9 +13,9 @@ ADD_EXECUTABLE(web_interface ${web_interface_sources} ${web_interface_headers}) INSTALL(TARGETS web_interface RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) -ADD_DEFINITIONS(-DQSERV) +ADD_DEFINITIONS(-DWEB_INTERFACE) -TARGET_LINK_LIBRARIES(web_interface Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(web_interface common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(web_interface PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -37,4 +37,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/web_interface/web_connection.cpp b/web_interface/web_connection.cpp new file mode 100644 index 000000000..f8ed4aec0 --- /dev/null +++ b/web_interface/web_connection.cpp @@ -0,0 +1,44 @@ +/* EQEMu: Everquest Server Emulator + Copyright (C) 2001-2014 EQEMu Development Team (http://eqemulator.net) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 of the License. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY except by those people which sell it, which + are required to give you total support for your newly bought product; + without even the implied warranty of MERCHANTABILITY or FITNESS FOR + A PARTICULAR PURPOSE. See the GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +#include "web_connection.h" + +WebConnection::WebConnection(uint32 ID, WebServer *server, SOCKET in_socket, uint32 irIP, uint16 irPort) +: TCPConnection(ID, in_socket, irIP, irPort) +{ + w_server = server; +} + +WebConnection::~WebConnection() { +} + +bool WebConnection::ProcessReceivedData(char* errbuf) { + //recvbuf_used + //recvbuf + return true; +} + +WebServer::WebServer(uint16 port) +: TCPServer(iPort) +{ +} + +void WebServer::CreateNewConnection(uint32 ID, SOCKET in_socket, uint32 irIP, uint16 irPort) { + WebConnection *conn = new WebConnection(ID, this, in_socket, irIP, irPort, pOldFormat); + AddConnection(conn); +} diff --git a/web_interface/web_connection.h b/web_interface/web_connection.h new file mode 100644 index 000000000..f2f0352a4 --- /dev/null +++ b/web_interface/web_connection.h @@ -0,0 +1,44 @@ +/* EQEMu: Everquest Server Emulator + Copyright (C) 2001-2014 EQEMu Development Team (http://eqemulator.net) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; version 2 of the License. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY except by those people which sell it, which + are required to give you total support for your newly bought product; + without even the implied warranty of MERCHANTABILITY or FITNESS FOR + A PARTICULAR PURPOSE. See the GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ +#ifndef WI_WEB_CONNECTION_H +#define WI_WEB_CONNECTION_H + +#include "../common/TCPConnection.h" + +class WebServer; +class WebConnection : public TCPConnection +{ +public: + WebConnection(uint32 ID, WebServer *server, SOCKET in_socket, uint32 irIP, uint16 irPort); + virtual ~WebConnection(); + +protected: + virtual bool ProcessReceivedData(char* errbuf = 0); + WebServer *w_server; +}; + +class WebServer : protected TCPServer { +public: + WebServer(uint16 port); + +protected: + virtual void CreateNewConnection(uint32 ID, SOCKET in_socket, uint32 irIP, uint16 irPort); +}; + +#endif + diff --git a/web_interface/web_interface.cpp b/web_interface/web_interface.cpp index 9f609839a..a0efb4a4e 100644 --- a/web_interface/web_interface.cpp +++ b/web_interface/web_interface.cpp @@ -41,15 +41,17 @@ int main() { worldserver = new WorldServer(config->SharedKey); worldserver->Connect(); - while(run) { + while(run) { Timer::SetCurrentTime(); if (InterserverTimer.Check()) { if (worldserver->TryReconnect() && (!worldserver->Connected())) worldserver->AsyncConnect(); } worldserver->Process(); - timeout_manager.CheckTimeouts(); - Sleep(10); + timeout_manager.CheckTimeouts(); + Sleep(1); } + + return 0; } diff --git a/world/CMakeLists.txt b/world/CMakeLists.txt index c2b4eb1a1..620afdc77 100644 --- a/world/CMakeLists.txt +++ b/world/CMakeLists.txt @@ -71,7 +71,7 @@ INSTALL(TARGETS world RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) ADD_DEFINITIONS(-DWORLD) -TARGET_LINK_LIBRARIES(world Common ${PERL_LIBRARY} debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(world common ${PERL_LIBRARY} debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(MSVC) SET_TARGET_PROPERTIES(world PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF") @@ -93,4 +93,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin) diff --git a/zone/CMakeLists.txt b/zone/CMakeLists.txt index d35f46050..9f7250d4e 100644 --- a/zone/CMakeLists.txt +++ b/zone/CMakeLists.txt @@ -218,7 +218,7 @@ INSTALL(TARGETS zone RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}) ADD_DEFINITIONS(-DZONE) -TARGET_LINK_LIBRARIES(zone Common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) +TARGET_LINK_LIBRARIES(zone common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY}) IF(EQEMU_BUILD_PERL) TARGET_LINK_LIBRARIES(zone ${PERL_LIBRARY}) @@ -249,4 +249,4 @@ IF(UNIX) ADD_DEFINITIONS(-fPIC) ENDIF(UNIX) -SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/Bin) +SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin)