From 6b75817572732f54913c368b801767bb5c2c623b Mon Sep 17 00:00:00 2001 From: Ilya Orlov Date: Wed, 17 Oct 2018 14:10:26 +0300 Subject: [PATCH] xrEngine: enable some checking on linux --- src/xrEngine/CMakeLists.txt | 2 +- src/xrEngine/main.cpp | 9 ++------- src/xrNetServer/CMakeLists.txt | 2 +- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/src/xrEngine/CMakeLists.txt b/src/xrEngine/CMakeLists.txt index fc032965c16..27ff4a08781 100644 --- a/src/xrEngine/CMakeLists.txt +++ b/src/xrEngine/CMakeLists.txt @@ -35,6 +35,6 @@ set_target_properties(${PROJECT_NAME} PROPERTIES COTIRE_CXX_PREFIX_HEADER_INIT " cotire(${PROJECT_NAME}) set_target_properties(${PROJECT_NAME} PROPERTIES PREFIX "") -target_link_libraries(${PROJECT_NAME} xrCore xrMiscMath luabind xrAPI xrSound xrScriptEngine ${LUA_LIBRARIES} ${THEORA_LIBRARY} ${OGG_LIBRARIES} xrCDB xrPhysics ${FREEIMAGE_LIBRARY} openal ${LOCKFILE_LIBRARIES} ${SDL_LIBRARIES}) +target_link_libraries(${PROJECT_NAME} xrCore xrMiscMath luabind xrAPI xrSound xrScriptEngine xrNetServer ${LUA_LIBRARIES} ${THEORA_LIBRARY} ${OGG_LIBRARIES} xrCDB xrPhysics ${FREEIMAGE_LIBRARY} openal ${LOCKFILE_LIBRARIES} ${SDL_LIBRARIES}) xr_install(${PROJECT_NAME}) diff --git a/src/xrEngine/main.cpp b/src/xrEngine/main.cpp index cd38033fd74..050da05b6d1 100644 --- a/src/xrEngine/main.cpp +++ b/src/xrEngine/main.cpp @@ -66,11 +66,8 @@ struct PathIncludePred { if (!ignored) return true; -#if !defined(LINUX) - return allow_to_include_path(*ignored, path); //TODO port xrNetServer to Linux -#else - return false; // Noidea what happenning -#endif + + return allow_to_include_path(*ignored, path); } }; } @@ -85,14 +82,12 @@ ENGINE_API void InitSettings() pSettings = new CInifile(fname, TRUE); CHECK_OR_EXIT(pSettings->section_count(), make_string("Cannot find file %s.\nReinstalling application may fix this problem.", fname)); -#if !defined(LINUX) xr_auth_strings_t ignoredPaths, checkedPaths; fill_auth_check_params(ignoredPaths, checkedPaths); //TODO port xrNetServer to Linux PathIncludePred includePred(&ignoredPaths); CInifile::allow_include_func_t includeFilter; includeFilter.bind(&includePred, &PathIncludePred::IsIncluded); pSettingsAuth = new CInifile(fname, TRUE, TRUE, FALSE, 0, includeFilter); -#endif FS.update_path(fname, "$game_config$", "game.ltx"); pGameIni = new CInifile(fname, TRUE); CHECK_OR_EXIT(pGameIni->section_count(), diff --git a/src/xrNetServer/CMakeLists.txt b/src/xrNetServer/CMakeLists.txt index 63a2b1fa37a..219f4a413ae 100644 --- a/src/xrNetServer/CMakeLists.txt +++ b/src/xrNetServer/CMakeLists.txt @@ -18,7 +18,7 @@ list(REMOVE_ITEM ${PROJECT_NAME}__SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/./NET_Ser list(REMOVE_ITEM ${PROJECT_NAME}__INCLUDES "${CMAKE_CURRENT_SOURCE_DIR}/./NET_Client.h") list(REMOVE_ITEM ${PROJECT_NAME}__INCLUDES "${CMAKE_CURRENT_SOURCE_DIR}/./NET_Server.h") -add_definitions(-DXRGAME_EXPORTS -D_USRDLL) +add_definitions(-DXR_NETSERVER_EXPORTS -D_USRDLL) add_library(${PROJECT_NAME} SHARED ${${PROJECT_NAME}__SOURCES} ${${PROJECT_NAME}__INCLUDES}) set_target_properties(${PROJECT_NAME} PROPERTIES COTIRE_CXX_PREFIX_HEADER_INIT "stdafx.h")