diff --git a/code/nel/tools/pipeline/plugin_library/tool_logger.h b/code/nel/include/nel/misc/tool_logger.h similarity index 100% rename from code/nel/tools/pipeline/plugin_library/tool_logger.h rename to code/nel/include/nel/misc/tool_logger.h diff --git a/code/nel/tools/pipeline/plugin_library/tool_logger.cpp b/code/nel/src/misc/tool_logger.cpp similarity index 94% rename from code/nel/tools/pipeline/plugin_library/tool_logger.cpp rename to code/nel/src/misc/tool_logger.cpp index 17c9b1b08..05432114a 100644 --- a/code/nel/tools/pipeline/plugin_library/tool_logger.cpp +++ b/code/nel/src/misc/tool_logger.cpp @@ -26,7 +26,7 @@ */ #include -#include "tool_logger.h" +#include "nel/misc/tool_logger.h" // STL includes diff --git a/code/nel/tools/3d/build_interface/main.cpp b/code/nel/tools/3d/build_interface/main.cpp index b00f652f2..4476b880c 100644 --- a/code/nel/tools/3d/build_interface/main.cpp +++ b/code/nel/tools/3d/build_interface/main.cpp @@ -26,7 +26,7 @@ #include #include -#include "../../pipeline/pipeline_library/tool_logger.h" +#include "nel/misc/tool_logger.h" // --------------------------------------------------------------------------- diff --git a/code/nel/tools/pipeline/plugin_library/CMakeLists.txt b/code/nel/tools/pipeline/plugin_library/CMakeLists.txt index 6ff16f270..f80215caf 100644 --- a/code/nel/tools/pipeline/plugin_library/CMakeLists.txt +++ b/code/nel/tools/pipeline/plugin_library/CMakeLists.txt @@ -2,12 +2,14 @@ FILE(GLOB SRC *.cpp *.h) SOURCE_GROUP("" FILES ${SRC}) -ADD_LIBRARY(pipeline_plugin_library STATIC ${SRC}) +NL_TARGET_LIB(pipeline_plugin_library ${SRC}) TARGET_LINK_LIBRARIES(pipeline_plugin_library nelmisc) - +SET_TARGET_PROPERTIES(pipeline_plugin_library PROPERTIES LINK_INTERFACE_LIBRARIES "") NL_DEFAULT_PROPS(pipeline_plugin_library "Pipeline Plugin Library") NL_ADD_LIB_SUFFIX(pipeline_plugin_library) NL_ADD_RUNTIME_FLAGS(pipeline_plugin_library) -INSTALL(TARGETS pipeline_plugin_library RUNTIME DESTINATION bin LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) + INSTALL(TARGETS pipeline_plugin_library LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/tools/pipeline/plugin_library/pipeline_process.cpp b/code/nel/tools/pipeline/plugin_library/pipeline_process.cpp index f6a9385a3..10a239819 100644 --- a/code/nel/tools/pipeline/plugin_library/pipeline_process.cpp +++ b/code/nel/tools/pipeline/plugin_library/pipeline_process.cpp @@ -29,6 +29,7 @@ #include "pipeline_process.h" // STL includes +#include // NeL includes #include diff --git a/code/nel/tools/pipeline/plugin_library/pipeline_process.h b/code/nel/tools/pipeline/plugin_library/pipeline_process.h index e744fb31f..b6c1b8b69 100644 --- a/code/nel/tools/pipeline/plugin_library/pipeline_process.h +++ b/code/nel/tools/pipeline/plugin_library/pipeline_process.h @@ -30,6 +30,8 @@ #include // STL includes +#include +#include // NeL includes diff --git a/code/nel/tools/pipeline/plugin_max/pipeline_plugin_max.cpp b/code/nel/tools/pipeline/plugin_max/pipeline_plugin_max.cpp index 7b20a795a..32ec98c38 100644 --- a/code/nel/tools/pipeline/plugin_max/pipeline_plugin_max.cpp +++ b/code/nel/tools/pipeline/plugin_max/pipeline_plugin_max.cpp @@ -59,12 +59,14 @@ class CPipelinePluginMaxNelLibrary : public NLMISC::INelLibrary }; NLMISC_DECL_PURE_LIB(CPipelinePluginMaxNelLibrary) +#ifdef NL_OS_WINDOWS HINSTANCE CPipelinePluginMaxDllHandle = NULL; BOOL WINAPI DllMain(HANDLE hModule, DWORD /* ul_reason_for_call */, LPVOID /* lpReserved */) { CPipelinePluginMaxDllHandle = (HINSTANCE)hModule; return TRUE; } +#endif // ****************************************************************** /* diff --git a/code/nel/tools/pipeline/plugin_nel/pipeline_plugin_nel.cpp b/code/nel/tools/pipeline/plugin_nel/pipeline_plugin_nel.cpp index 5bbf80ae2..7f0769b2f 100644 --- a/code/nel/tools/pipeline/plugin_nel/pipeline_plugin_nel.cpp +++ b/code/nel/tools/pipeline/plugin_nel/pipeline_plugin_nel.cpp @@ -61,12 +61,14 @@ class CPipelinePluginNeLNelLibrary : public NLMISC::INelLibrary }; NLMISC_DECL_PURE_LIB(CPipelinePluginNeLNelLibrary) +#ifdef NL_OS_WINDOWS HINSTANCE CPipelinePluginNeLDllHandle = NULL; BOOL WINAPI DllMain(HANDLE hModule, DWORD /* ul_reason_for_call */, LPVOID /* lpReserved */) { CPipelinePluginNeLDllHandle = (HINSTANCE)hModule; return TRUE; } +#endif // ****************************************************************** diff --git a/code/nel/tools/pipeline/service/CMakeLists.txt b/code/nel/tools/pipeline/service/CMakeLists.txt index 7c33b708e..a70cab0c6 100644 --- a/code/nel/tools/pipeline/service/CMakeLists.txt +++ b/code/nel/tools/pipeline/service/CMakeLists.txt @@ -2,10 +2,16 @@ FILE(GLOB SRC *.cpp *.h) SOURCE_GROUP("" FILES ${SRC}) +FIND_PACKAGE(Boost COMPONENTS thread REQUIRED) ADD_EXECUTABLE(pipeline_service WIN32 ${SRC}) -INCLUDE_DIRECTORIES(${BOOST_ROOT}) -TARGET_LINK_LIBRARIES(pipeline_service pipeline_plugin_library nelmisc nelnet nelgeorges) +IF(UNIX) + INCLUDE_DIRECTORIES(${Boost_INCLUDE_DIR}) + TARGET_LINK_LIBRARIES(pipeline_service pipeline_plugin_library nelmisc nelnet nelgeorges ${Boost_LIBRARIES}) +ELSE(UNIX) + INCLUDE_DIRECTORIES(${BOOST_ROOT}) + TARGET_LINK_LIBRARIES(pipeline_service pipeline_plugin_library nelmisc nelnet nelgeorges) +ENDIF(UNIX) NL_DEFAULT_PROPS(pipeline_service "Pipeline Service") NL_ADD_RUNTIME_FLAGS(pipeline_service) diff --git a/code/nel/tools/pipeline/service/build_task_queue.h b/code/nel/tools/pipeline/service/build_task_queue.h index f90628e83..c2649ddf1 100644 --- a/code/nel/tools/pipeline/service/build_task_queue.h +++ b/code/nel/tools/pipeline/service/build_task_queue.h @@ -31,6 +31,7 @@ // STL includes #include +#include // NeL includes diff --git a/code/nel/tools/pipeline/service/database_status.cpp b/code/nel/tools/pipeline/service/database_status.cpp index 0fbd87a79..016763e8b 100644 --- a/code/nel/tools/pipeline/service/database_status.cpp +++ b/code/nel/tools/pipeline/service/database_status.cpp @@ -153,7 +153,7 @@ std::string getStatusFilePath(const std::string &path) } /* anonymous namespace */ -void CFileError::serial(NLMISC::IStream &stream) +void CFileError::serial(NLMISC::IStream &stream) throw (NLMISC::EStream) { uint version = stream.serialVersion(1); stream.serial(Project); @@ -161,7 +161,7 @@ void CFileError::serial(NLMISC::IStream &stream) stream.serial(Message); } -void CFileStatus::serial(NLMISC::IStream &stream) +void CFileStatus::serial(NLMISC::IStream &stream) throw (NLMISC::EStream) { uint version = stream.serialVersion(2); stream.serial(FirstSeen); diff --git a/code/nel/tools/pipeline/service/example_cfg/gtk_run_master.sh b/code/nel/tools/pipeline/service/example_cfg/gtk_run_master.sh new file mode 100644 index 000000000..1b5d31b45 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/gtk_run_master.sh @@ -0,0 +1,5 @@ +#!/bin/sh + +cd /home/nevrax/build/devl/bin +./pipeline_service -C/home/nevrax/code/nel/tools/pipeline/service/example_cfg/master_gtk/ + diff --git a/code/nel/tools/pipeline/service/example_cfg/linux_run_master.sh b/code/nel/tools/pipeline/service/example_cfg/linux_run_master.sh new file mode 100644 index 000000000..df59e643a --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/linux_run_master.sh @@ -0,0 +1,5 @@ +#!/bin/sh + +cd /home/nevrax/build/devl/bin +./pipeline_service -C/home/nevrax/code/nel/tools/pipeline/service/example_cfg/master_linux/ + diff --git a/code/nel/tools/pipeline/service/example_cfg/linux_run_slave.sh b/code/nel/tools/pipeline/service/example_cfg/linux_run_slave.sh new file mode 100644 index 000000000..a60d1cd94 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/linux_run_slave.sh @@ -0,0 +1,5 @@ +#!/bin/sh + +cd /home/nevrax/build/devl/bin +./pipeline_service -C/home/nevrax/code/nel/tools/pipeline/service/example_cfg/master_slave/ + diff --git a/code/nel/tools/pipeline/service/example_cfg/master/pipeline_service.cfg b/code/nel/tools/pipeline/service/example_cfg/master/pipeline_service.cfg deleted file mode 100644 index eeb32bef4..000000000 --- a/code/nel/tools/pipeline/service/example_cfg/master/pipeline_service.cfg +++ /dev/null @@ -1,4 +0,0 @@ - -#include "../pipeline_service_default.cfg" -#include "../user/pipeline_service_user.cfg" -#include "../pipeline_service_master.cfg" diff --git a/code/nel/tools/pipeline/service/example_cfg/master_gtk/pipeline_service.cfg b/code/nel/tools/pipeline/service/example_cfg/master_gtk/pipeline_service.cfg new file mode 100644 index 000000000..4d52542e3 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/master_gtk/pipeline_service.cfg @@ -0,0 +1,9 @@ + +#include "../pipeline_service_linux.cfg" +#include "../pipeline_service_default.cfg" +#include "../pipeline_service_common.cfg" +#include "../user/pipeline_service_user.cfg" +#include "../user/pipeline_service_user_linux.cfg" +#include "../pipeline_service_master.cfg" +WindowStyle = "GTK"; + diff --git a/code/nel/tools/pipeline/service/example_cfg/master_linux/pipeline_service.cfg b/code/nel/tools/pipeline/service/example_cfg/master_linux/pipeline_service.cfg new file mode 100644 index 000000000..980b855c8 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/master_linux/pipeline_service.cfg @@ -0,0 +1,9 @@ + +#include "../pipeline_service_linux.cfg" +#include "../pipeline_service_default.cfg" +#include "../pipeline_service_common.cfg" +#include "../user/pipeline_service_user.cfg" +#include "../user/pipeline_service_user_linux.cfg" +#include "../pipeline_service_master.cfg" +WindowStyle = "NONE"; + diff --git a/code/nel/tools/pipeline/service/example_cfg/master_win/pipeline_service.cfg b/code/nel/tools/pipeline/service/example_cfg/master_win/pipeline_service.cfg new file mode 100644 index 000000000..6fe17cfd9 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/master_win/pipeline_service.cfg @@ -0,0 +1,9 @@ + +#include "../pipeline_service_win.cfg" +#include "../pipeline_service_default.cfg" +#include "../pipeline_service_common.cfg" +#include "../user/pipeline_service_user.cfg" +#include "../user/pipeline_service_user_win.cfg" +#include "../pipeline_service_master.cfg" +WindowStyle = "WIN"; + diff --git a/code/nel/tools/pipeline/service/example_cfg/pipeline_service_common.cfg b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_common.cfg new file mode 100644 index 000000000..6997fcfbf --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_common.cfg @@ -0,0 +1,13 @@ + +DontUseNS = 1; +NSHost = "localhost"; + +DisplayedVariables = +{ + "Status|pipelineServiceState", "FileQueue|asyncFileQueueCount", + "", "InfoFlags|infoFlags", + "", "@Reload Sheets|reloadSheets", "@Busy Test|busyTestState" , "@Plug Slave|slave.plug gw", "@Unplug Slave|slave.unplug gw", +}; + +DontUseAES = 1; + diff --git a/code/nel/tools/pipeline/service/example_cfg/pipeline_service_default.cfg b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_default.cfg index 4f77f1b77..01b494e5c 100644 --- a/code/nel/tools/pipeline/service/example_cfg/pipeline_service_default.cfg +++ b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_default.cfg @@ -1,10 +1,10 @@ // Intermediate working directory used by the pipeline. -WorkspaceDirectory = "W:/workspace"; +WorkspaceDirectory = SharedWork + "/workspace"; // Workspace location -WorkspaceDfnDirectory = "L:/leveldesign/dfn"; -WorkspaceSheetDirectory = "L:/leveldesign/pipeline"; +WorkspaceDfnDirectory = SharedLeveldesign + "/leveldesign/DFN"; +WorkspaceSheetDirectory = SharedLeveldesign + "/leveldesign/pipeline"; WorkspaceSheet = "ryzom_core.pipeline_workspace"; // Lists all directories that can be accessed by the pipeline processes @@ -29,13 +29,13 @@ GeorgesDirectories = "LeveldesignGameElementDirectory", }; -DatabaseDirectory = "W:/database"; -LeveldesignDfnDirectory = "L:/leveldesign/dfn"; -LeveldesignWorldDirectory = "L:/leveldesign/World"; -LeveldesignEcosystemsDirectory = "L:/leveldesign/Ecosystems"; -LeveldesignGameElemDirectory = "L:/leveldesign/Game_elem"; -LeveldesignGameElementDirectory = "L:/leveldesign/game_element"; -PrimitivesDirectory = "L:/primitives"; +DatabaseDirectory = SharedWork + "/database"; +LeveldesignDfnDirectory = SharedLeveldesign + "/leveldesign/DFN"; +LeveldesignWorldDirectory = SharedLeveldesign + "/leveldesign/World"; +LeveldesignEcosystemsDirectory = SharedLeveldesign + "/leveldesign/Ecosystems"; +LeveldesignGameElemDirectory = SharedLeveldesign + "/leveldesign/Game_elem"; +LeveldesignGameElementDirectory = SharedLeveldesign + "/leveldesign/game_element"; +PrimitivesDirectory = SharedLeveldesign + "/primitives"; // ToolDirectories = { "R:/build/dev/bin/Release", "D:/libraries/external/bin" }; // ToolSuffix = ".exe"; @@ -48,20 +48,8 @@ PrimitivesDirectory = "L:/primitives"; MasterAddress = "192.168.150.1"; MasterPort = 50123; -UsedPlugins = { "pipeline_plugin_max", "pipeline_plugin_nel" }; +UsedPlugins += { "pipeline_plugin_nel" }; // MaxPath = "C:/Program Files (x86)/Autodesk/3ds Max 2010"; // MaxExecutable = "3dsmax.exe"; -DontUseNS = 1; -NSHost = "localhost"; - -WindowStyle = "WIN"; -DisplayedVariables = -{ - "Status|pipelineServiceState", "FileQueue|asyncFileQueueCount", - "", "InfoFlags|infoFlags", - "", "@Reload Sheets|reloadSheets", "@Busy Test|busyTestState" , "@Plug Slave|slave.plug gw", "@Unplug Slave|slave.unplug gw", -}; - -DontUseAES = 1; diff --git a/code/nel/tools/pipeline/service/example_cfg/pipeline_service_linux.cfg b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_linux.cfg new file mode 100644 index 000000000..03eef4fa4 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_linux.cfg @@ -0,0 +1,6 @@ + +SharedWork = "/srv/work"; // W: on Win +SharedLeveldesign = "/srv/leveldesign"; // L: on Win + +UsedPlugins = { }; + diff --git a/code/nel/tools/pipeline/service/example_cfg/pipeline_service_win.cfg b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_win.cfg new file mode 100644 index 000000000..cf9ca015b --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/pipeline_service_win.cfg @@ -0,0 +1,6 @@ + +SharedWork = "W:"; +SharedLeveldesign = "L:"; + +UsedPlugins = { "pipeline_plugin_max" }; + diff --git a/code/nel/tools/pipeline/service/example_cfg/slave/pipeline_service.cfg b/code/nel/tools/pipeline/service/example_cfg/slave/pipeline_service.cfg deleted file mode 100644 index f82f3f7b7..000000000 --- a/code/nel/tools/pipeline/service/example_cfg/slave/pipeline_service.cfg +++ /dev/null @@ -1,4 +0,0 @@ - -#include "../pipeline_service_default.cfg" -#include "../user/pipeline_service_user.cfg" -#include "../pipeline_service_slave.cfg" diff --git a/code/nel/tools/pipeline/service/example_cfg/slave_linux/pipeline_service.cfg b/code/nel/tools/pipeline/service/example_cfg/slave_linux/pipeline_service.cfg new file mode 100644 index 000000000..4b874428b --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/slave_linux/pipeline_service.cfg @@ -0,0 +1,9 @@ + +#include "../pipeline_service_linux.cfg" +#include "../pipeline_service_default.cfg" +#include "../pipeline_service_common.cfg" +#include "../user/pipeline_service_user.cfg" +#include "../user/pipeline_service_user_linux.cfg" +#include "../pipeline_service_slave.cfg" +WindowStyle = "NONE"; + diff --git a/code/nel/tools/pipeline/service/example_cfg/slave_win/pipeline_service.cfg b/code/nel/tools/pipeline/service/example_cfg/slave_win/pipeline_service.cfg new file mode 100644 index 000000000..8c0a581b6 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/slave_win/pipeline_service.cfg @@ -0,0 +1,9 @@ + +#include "../pipeline_service_win.cfg" +#include "../pipeline_service_default.cfg" +#include "../pipeline_service_common.cfg" +#include "../user/pipeline_service_user.cfg" +#include "../user/pipeline_service_user_win.cfg" +#include "../pipeline_service_slave.cfg" +WindowStyle = "WIN"; + diff --git a/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user.cfg b/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user.cfg index 1b9d6d3d8..9aa0cc537 100644 --- a/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user.cfg +++ b/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user.cfg @@ -1,2 +1,3 @@ -RootConfigFilename = "../pipeline_service_default.cfg"; +// Place your custom shared override configuration values here + diff --git a/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user_linux.cfg b/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user_linux.cfg new file mode 100644 index 000000000..9aa0cc537 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user_linux.cfg @@ -0,0 +1,3 @@ + +// Place your custom shared override configuration values here + diff --git a/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user_win.cfg b/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user_win.cfg new file mode 100644 index 000000000..9aa0cc537 --- /dev/null +++ b/code/nel/tools/pipeline/service/example_cfg/user/pipeline_service_user_win.cfg @@ -0,0 +1,3 @@ + +// Place your custom shared override configuration values here + diff --git a/code/nel/tools/pipeline/service/example_cfg/example_run_master.bat b/code/nel/tools/pipeline/service/example_cfg/win_run_master.bat similarity index 100% rename from code/nel/tools/pipeline/service/example_cfg/example_run_master.bat rename to code/nel/tools/pipeline/service/example_cfg/win_run_master.bat diff --git a/code/nel/tools/pipeline/service/example_cfg/example_run_slave.bat b/code/nel/tools/pipeline/service/example_cfg/win_run_slave.bat similarity index 100% rename from code/nel/tools/pipeline/service/example_cfg/example_run_slave.bat rename to code/nel/tools/pipeline/service/example_cfg/win_run_slave.bat diff --git a/code/nel/tools/pipeline/service/module_pipeline_master_itf.cpp b/code/nel/tools/pipeline/service/module_pipeline_master_itf.cpp index 436860af4..2f2f165fb 100644 Binary files a/code/nel/tools/pipeline/service/module_pipeline_master_itf.cpp and b/code/nel/tools/pipeline/service/module_pipeline_master_itf.cpp differ diff --git a/code/nel/tools/pipeline/service/module_pipeline_master_itf.h b/code/nel/tools/pipeline/service/module_pipeline_master_itf.h index 951e7b0c6..8e45708d4 100644 Binary files a/code/nel/tools/pipeline/service/module_pipeline_master_itf.h and b/code/nel/tools/pipeline/service/module_pipeline_master_itf.h differ diff --git a/code/nel/tools/pipeline/service/module_pipeline_slave_itf.cpp b/code/nel/tools/pipeline/service/module_pipeline_slave_itf.cpp index e0a17d2d5..4d94f3b59 100644 Binary files a/code/nel/tools/pipeline/service/module_pipeline_slave_itf.cpp and b/code/nel/tools/pipeline/service/module_pipeline_slave_itf.cpp differ diff --git a/code/nel/tools/pipeline/service/module_pipeline_slave_itf.h b/code/nel/tools/pipeline/service/module_pipeline_slave_itf.h index ec6151eb2..cdae75877 100644 Binary files a/code/nel/tools/pipeline/service/module_pipeline_slave_itf.h and b/code/nel/tools/pipeline/service/module_pipeline_slave_itf.h differ