diff --git a/eos/CMakeLists.txt b/eos/CMakeLists.txt index 1e1f31958a9ae9cdb976b4ec0dae3f75f1ad3001..b450db85d6a064a546a27157581b0984dd348709 100644 --- a/eos/CMakeLists.txt +++ b/eos/CMakeLists.txt @@ -16,6 +16,8 @@ cmake_minimum_required (VERSION 2.6) +add_subdirectory(messages) + find_package (xrootdclient REQUIRED) include_directories (${XROOTD_INCLUDE_DIR} ${CMAKE_SOURCE_DIR}) diff --git a/xroot_plugins/messages/CMakeLists.txt b/eos/messages/CMakeLists.txt similarity index 77% rename from xroot_plugins/messages/CMakeLists.txt rename to eos/messages/CMakeLists.txt index 35bba162ae567c52f5fc0ccf89fe6d0c36c3b1a5..cd53336640a360c440ef4b54f1bb89abd8e54ee2 100644 --- a/xroot_plugins/messages/CMakeLists.txt +++ b/eos/messages/CMakeLists.txt @@ -20,13 +20,11 @@ find_package(Protobuf REQUIRED) file(GLOB ProtoFiles "${CMAKE_CURRENT_SOURCE_DIR}/*.proto") PROTOBUF_GENERATE_CPP(ProtoSources ProtoHeaders ${ProtoFiles}) -set (CTA_FRONT_END_MESSAGES_SRC_FILES - ${ProtoSources}) +set (CTA_FRONT_END_MESSAGES_SRC_FILES ${ProtoSources}) -add_library (ctafrontendmessages SHARED - ${CTA_FRONT_END_MESSAGES_SRC_FILES}) +add_library (ctaeosmessages ${CTA_FRONT_END_MESSAGES_SRC_FILES}) -target_link_libraries (ctafrontendmessages +target_link_libraries (ctaeosmessages protobuf) -install (TARGETS ctafrontendmessages DESTINATION usr/${CMAKE_INSTALL_LIBDIR}) +install (TARGETS ctaeosmessages DESTINATION usr/${CMAKE_INSTALL_LIBDIR}) diff --git a/xroot_plugins/messages/notification.proto b/eos/messages/notification.proto similarity index 100% rename from xroot_plugins/messages/notification.proto rename to eos/messages/notification.proto diff --git a/xroot_plugins/CMakeLists.txt b/xroot_plugins/CMakeLists.txt index 199fff9dc259911d72a72ee8e39c1727a8364809..2532fcb735cffe6dcc31a453776fe196709d006a 100644 --- a/xroot_plugins/CMakeLists.txt +++ b/xroot_plugins/CMakeLists.txt @@ -15,8 +15,6 @@ # along with this program. If not, see <http://www.gnu.org/licenses/>. cmake_minimum_required (VERSION 2.6) -add_subdirectory(messages) - list (APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) find_package (xrootd REQUIRED) include_directories(${CMAKE_SOURCE_DIR}) @@ -25,7 +23,7 @@ include_directories(${CMAKE_BINARY_DIR}) include_directories(${CMAKE_SOURCE_DIR}/tapeserver) add_library (XrdCtaOfs MODULE XrdCtaFilesystem.cpp XrdCtaFile.cpp XrdCtaDir.cpp) -target_link_libraries (XrdCtaOfs ctacatalogue ctafrontendmessages ctascheduler ctacommon protobuf ctaobjectstore cryptopp) +target_link_libraries (XrdCtaOfs ctacatalogue ctaeosmessages ctascheduler ctacommon protobuf ctaobjectstore cryptopp) INSTALL (TARGETS XrdCtaOfs DESTINATION usr/${CMAKE_INSTALL_LIBDIR}) INSTALL (FILES xrootd-cta.cfg DESTINATION /etc/xrootd/) @@ -49,4 +47,4 @@ set (WRITE_NOTIFICATION_MSG_CMD_SRC_FILES add_executable (cta-xrootd_plugins-write-notification-msg ${WRITE_NOTIFICATION_MSG_CMD_SRC_FILES}) add_dependencies (cta-xrootd_plugins-write-notification-msg generate_notification.pb.h) -target_link_libraries (cta-xrootd_plugins-write-notification-msg ctacommon ctafrontendmessages) +target_link_libraries (cta-xrootd_plugins-write-notification-msg ctacommon ctaeosmessages) diff --git a/xroot_plugins/OpaqueQueryCmd.cpp b/xroot_plugins/OpaqueQueryCmd.cpp index c30da768baa61a6e74b7ef5d306f3030febafd73..c18a73487cec5ada4a6147c89dc59b6c4b4736bd 100644 --- a/xroot_plugins/OpaqueQueryCmd.cpp +++ b/xroot_plugins/OpaqueQueryCmd.cpp @@ -17,9 +17,9 @@ */ #include "common/make_unique.hpp" +#include "eos/messages/notification.pb.h" #include "xroot_plugins/OpaqueQueryCmd.hpp" #include "xroot_plugins/OpaqueQueryCmdLineArgs.hpp" -#include "xroot_plugins/messages/notification.pb.h" #include <fstream> #include <iostream> diff --git a/xroot_plugins/WriteNotificationMsgCmd.cpp b/xroot_plugins/WriteNotificationMsgCmd.cpp index 123653e3ac9276dafbebdec3d897b7d1833cf515..8c2c6a09cd7396f3f2694b13784c592a1c83d40f 100644 --- a/xroot_plugins/WriteNotificationMsgCmd.cpp +++ b/xroot_plugins/WriteNotificationMsgCmd.cpp @@ -17,9 +17,9 @@ */ #include "common/make_unique.hpp" +#include "eos/messages/notification.pb.h" #include "xroot_plugins/WriteNotificationMsgCmd.hpp" #include "xroot_plugins/WriteNotificationMsgCmdLineArgs.hpp" -#include "xroot_plugins/messages/notification.pb.h" #include <fstream> #include <iostream> diff --git a/xroot_plugins/XrdCtaFilesystem.cpp b/xroot_plugins/XrdCtaFilesystem.cpp index f470d3cf877086144d5ad2847148f94e6f279d15..c5eb5b4292632f037de3dbf379e6a4f46fe358c8 100644 --- a/xroot_plugins/XrdCtaFilesystem.cpp +++ b/xroot_plugins/XrdCtaFilesystem.cpp @@ -28,6 +28,7 @@ #include "common/exception/Exception.hpp" #include "common/make_unique.hpp" #include "common/TapePool.hpp" +#include "eos/messages/notification.pb.h" #include "objectstore/RootEntry.hpp" #include "objectstore/BackendFactory.hpp" #include "scheduler/LogicalLibrary.hpp" @@ -37,7 +38,6 @@ #include "XrdOuc/XrdOucString.hh" #include "XrdSec/XrdSecEntity.hh" #include "XrdVersion.hh" -#include "xroot_plugins/messages/notification.pb.h" #include "xroot_plugins/XrdCtaFilesystem.hpp" #include "xroot_plugins/XrdCtaFile.hpp" #include "XrdCtaDir.hpp"