From c6d628aae2f24793606842969046834192435ed7 Mon Sep 17 00:00:00 2001
From: lintao <lintao51@gmail.com>
Date: Tue, 22 Dec 2020 22:58:13 +0800
Subject: [PATCH] WIP: migrate DetInterface.

---
 CMakeLists.txt                                           | 1 +
 Detector/CMakeLists.txt                                  | 8 ++++++++
 Detector/DetInterface/CMakeLists.txt                     | 9 ++++++---
 .../DetInterface/{ => include}/DetInterface/IGeomSvc.h   | 0
 4 files changed, 15 insertions(+), 3 deletions(-)
 create mode 100644 Detector/CMakeLists.txt
 rename Detector/DetInterface/{ => include}/DetInterface/IGeomSvc.h (100%)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 384dc76e..860eaf85 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -15,3 +15,4 @@ if(NOT CMAKE_CXX_STANDARD MATCHES "14|17")
 endif()
 
 add_subdirectory(Analysis)
+add_subdirectory(Detector)
diff --git a/Detector/CMakeLists.txt b/Detector/CMakeLists.txt
new file mode 100644
index 00000000..54c2d545
--- /dev/null
+++ b/Detector/CMakeLists.txt
@@ -0,0 +1,8 @@
+
+# add_subdirectory(DetCEPCv4)
+# add_subdirectory(DetCRD)
+# add_subdirectory(DetDriftChamber)
+# add_subdirectory(DetEcalMatrix)
+add_subdirectory(DetInterface)
+# add_subdirectory(DetSegmentation)
+# add_subdirectory(GeomSvc)
diff --git a/Detector/DetInterface/CMakeLists.txt b/Detector/DetInterface/CMakeLists.txt
index 04673155..d0365a9a 100644
--- a/Detector/DetInterface/CMakeLists.txt
+++ b/Detector/DetInterface/CMakeLists.txt
@@ -1,8 +1,11 @@
 ################################################################################
 # Package: DetInterface
 ################################################################################
-gaudi_subdir(DetInterface v1r0)
 
-gaudi_depends_on_subdirs(GaudiKernel)
+gaudi_add_header_only_library(DetInterface)
 
-gaudi_install_headers(DetInterface)
+install(TARGETS DetInterface
+  EXPORT CEPCSWTargets
+  RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" COMPONENT bin
+  LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" COMPONENT shlib
+  COMPONENT dev)
diff --git a/Detector/DetInterface/DetInterface/IGeomSvc.h b/Detector/DetInterface/include/DetInterface/IGeomSvc.h
similarity index 100%
rename from Detector/DetInterface/DetInterface/IGeomSvc.h
rename to Detector/DetInterface/include/DetInterface/IGeomSvc.h
-- 
GitLab