Skip to content
Snippets Groups Projects
Commit 37b5bb03 authored by Jorge Camarero Vera's avatar Jorge Camarero Vera
Browse files

Remove unused-function gcc suppresions

parent 7a2679ce
No related branches found
No related tags found
No related merge requests found
......@@ -52,9 +52,6 @@ install (TARGETS ctascheduler DESTINATION usr/${CMAKE_INSTALL_LIBDIR})
target_link_libraries (ctascheduler ctacommon ctaobjectstore ${PROTOBUF3_LIBRARIES} ctadisk)
#add_library (ctaschedulerutils SHARED
# _old_prototype_DummyScheduler.cpp)
add_library (ctaschedulerunittests SHARED
SchedulerDatabaseFactory.cpp
SchedulerDatabaseTest.cpp
......@@ -63,10 +60,6 @@ add_library (ctaschedulerunittests SHARED
set_property(TARGET ctaschedulerunittests PROPERTY SOVERSION "${CTA_SOVERSION}")
set_property(TARGET ctaschedulerunittests PROPERTY VERSION "${CTA_LIBVERSION}")
set_property(SOURCE OStoreDB/OStoreDBTest.cpp APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-unused-function")
set_property(SOURCE SchedulerDatabaseTest.cpp APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-unused-function")
set_property(SOURCE SchedulerTest.cpp APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-unused-function")
target_link_libraries (ctaschedulerunittests
ctascheduler)
......
......@@ -311,42 +311,6 @@ m_OStoreDB(*m_backend, *m_catalogue, *m_logger),
m_OStoreDB.setAgentReference(m_agentReferencePtr.get());
}
template <>
OStoreDBWrapper<cta::objectstore::BackendRados>::OStoreDBWrapper(
const std::string &context,std::unique_ptr<cta::catalogue::Catalogue> & catalogue, const std::string &URL) :
m_logger(new cta::log::DummyLogger("", "")), m_backend(cta::objectstore::BackendFactory::createBackend(URL, *m_logger).release()),
m_catalogue(catalogue),
m_OStoreDB(*m_backend, *m_catalogue, *m_logger),
m_agentReferencePtr(new objectstore::AgentReference("OStoreDBFactory", *m_logger))
{
// We need to first clean up possible left overs in the pool
auto l = m_backend->list();
for (auto o=l.begin(); o!=l.end(); o++) {
try {
m_backend->remove(*o);
} catch (std::exception &) {}
}
// We need to populate the root entry before using.
objectstore::RootEntry re(*m_backend);
re.initialize();
re.insert();
objectstore::ScopedExclusiveLock rel(re);
re.fetch();
objectstore::Agent agent(m_agentReferencePtr->getAgentAddress(), *m_backend);
agent.initialize();
objectstore::EntryLogSerDeser cl("user0", "systemhost", time(NULL));
log::LogContext lc(*m_logger);
re.addOrGetAgentRegisterPointerAndCommit(*m_agentReferencePtr, cl, lc);
rel.release();
agent.insertAndRegisterSelf(lc);
rel.lock(re);
re.fetch();
re.addOrGetDriveRegisterPointerAndCommit(*m_agentReferencePtr, cl);
re.addOrGetSchedulerGlobalLockAndCommit(*m_agentReferencePtr, cl);
rel.release();
m_OStoreDB.setAgentReference(m_agentReferencePtr.get());
}
}
/**
......
......@@ -48,9 +48,6 @@ set(CTATAPESERVERDAEMON_LIBRARY_SRCS
TapeWriteSingleThread.cpp
TapeWriteTask.cpp)
# Add -Wno-unused-function compiler flag
set_property(SOURCE DataTransferSessionTest.cpp APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-unused-function")
add_library(ctaTapeServerDaemon
${CTATAPESERVERDAEMON_LIBRARY_SRCS})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment