From 3c34c1168e200d9924cdc35c2d06321192838a8b Mon Sep 17 00:00:00 2001 From: Boris Ranto Date: Fri, 8 Dec 2017 00:21:38 +0100 Subject: [PATCH 2/2] librbd: Conditionally import TrimRequest.cc We include TrimRequest.cc in librbd tests at two places: - operation/test_mock_TrimRequest.cc - operation/test_mock_ResizeRequest.cc That causes linking errors when doing the builds because some of the structures are defined twice. Signed-off-by: Boris Ranto --- src/librbd/operation/TrimRequest.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/librbd/operation/TrimRequest.cc b/src/librbd/operation/TrimRequest.cc index 28f2deb1af..929ca51459 100644 --- a/src/librbd/operation/TrimRequest.cc +++ b/src/librbd/operation/TrimRequest.cc @@ -362,4 +362,6 @@ void TrimRequest::send_finish(int r) { } // namespace operation } // namespace librbd +#ifndef TEST_F template class librbd::operation::TrimRequest; +#endif -- 2.15.1