File: Use-system-provided-pybind11.patch

package info (click to toggle)
aoflagger 3.4.0-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 8,960 kB
  • sloc: cpp: 83,076; python: 10,187; sh: 260; makefile: 178
file content (36 lines) | stat: -rw-r--r-- 1,115 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
From: Ole Streicher <olebole@debian.org>
Date: Mon, 30 Aug 2021 11:05:37 +0200
Subject: Use system provided pybind11

---
 CMakeLists.txt | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 608829b..808fa12 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -71,11 +71,6 @@ foreach(ExternalSubmodule IN LISTS ExternalSubmoduleDirectories)
   endif()
 endforeach()
 
-# Include aocommon/pybind11 headers
-include_directories("${CMAKE_SOURCE_DIR}/external/aocommon/include")
-add_subdirectory("${CMAKE_SOURCE_DIR}/external/pybind11")
-include_directories(SYSTEM ${pybind11_INCLUDE_DIR})
-
 find_package(
   HDF5
   COMPONENTS C CXX
@@ -106,6 +101,11 @@ find_package(Threads REQUIRED)
 
 find_package(PNG REQUIRED)
 
+# Include pybind11 headers
+find_package(pybind11 REQUIRED)
+include_directories("${CMAKE_SOURCE_DIR}/external/aocommon/include")
+include_directories(${pybind11_INCLUDE_DIR})
+
 # boost::alignment requires Boost 1.56
 find_package(Boost 1.56.0 REQUIRED COMPONENTS date_time system)
 include_directories(SYSTEM ${Boost_INCLUDE_DIRS})