diff options
Diffstat (limited to 'dynamic-layers/openembedded-layer/recipes-support/opencv/openvino-inference-engine_2023.0.0.bb')
-rw-r--r-- | dynamic-layers/openembedded-layer/recipes-support/opencv/openvino-inference-engine_2023.0.0.bb | 119 |
1 files changed, 119 insertions, 0 deletions
diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/openvino-inference-engine_2023.0.0.bb b/dynamic-layers/openembedded-layer/recipes-support/opencv/openvino-inference-engine_2023.0.0.bb new file mode 100644 index 00000000..193e33a1 --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/openvino-inference-engine_2023.0.0.bb | |||
@@ -0,0 +1,119 @@ | |||
1 | SUMMARY = "OpenVINO(TM) Toolkit - Deep Learning Deployment Toolkit" | ||
2 | HOMEPAGE = "https://github.com/opencv/dldt" | ||
3 | DESCRIPTION = "This toolkit allows developers to deploy pre-trained \ | ||
4 | deep learning models through a high-level C++ Inference Engine API \ | ||
5 | integrated with application logic." | ||
6 | |||
7 | SRC_URI = "git://github.com/openvinotoolkit/openvino.git;protocol=https;branch=releases/2023/0;lfs=0 \ | ||
8 | git://github.com/openvinotoolkit/oneDNN.git;protocol=https;destsuffix=git/src/plugins/intel_cpu/thirdparty/onednn;name=mkl;nobranch=1 \ | ||
9 | git://github.com/oneapi-src/oneDNN.git;protocol=https;destsuffix=git/src/plugins/intel_gpu/thirdparty/onednn_gpu;name=onednn;nobranch=1 \ | ||
10 | git://github.com/herumi/xbyak.git;protocol=https;destsuffix=git/thirdparty/xbyak;name=xbyak;branch=master \ | ||
11 | git://github.com/nlohmann/json.git;protocol=https;destsuffix=git/thirdparty/json/nlohmann_json;name=json;branch=develop \ | ||
12 | git://github.com/opencv/ade.git;protocol=https;destsuffix=git/thirdparty/ade;name=ade;nobranch=1 \ | ||
13 | file://fix-build.patch \ | ||
14 | file://cython-cmake.patch \ | ||
15 | file://7cecc9138b89e1946e3e515727bb69b2ab119806.patch;patchdir=thirdparty/ade \ | ||
16 | file://fix-build-with-gcc13.patch \ | ||
17 | file://onednn-fix-build-with-gcc13.patch;patchdir=src/plugins/intel_gpu/thirdparty/onednn_gpu \ | ||
18 | " | ||
19 | |||
20 | SRCREV = "b4452d5630442e91cf84db5acd3d991f3d1f34c2" | ||
21 | SRCREV_mkl = "1c7bfabf1b26e6fb95fea1613e1d3d2bef1f6b54" | ||
22 | SRCREV_onednn = "f27dedbfc093f51032a4580198bb80579440dc15" | ||
23 | SRCREV_xbyak = "740dff2e866f3ae1a70dd42d6e8836847ed95cc2" | ||
24 | SRCREV_json = "bc889afb4c5bf1c0d8ee29ef35eaaf4c8bef8a5d" | ||
25 | SRCREV_ade = "58b2595a1a95cc807be8bf6222f266a9a1f393a9" | ||
26 | |||
27 | LICENSE = "Apache-2.0 & MIT & BSD-3-Clause" | ||
28 | LIC_FILES_CHKSUM = "file://LICENSE;md5=86d3f3a95c324c9479bd8986968f4327 \ | ||
29 | file://thirdparty/xbyak/COPYRIGHT;md5=3c98edfaa50a86eeaef4c6109e803f16 \ | ||
30 | file://thirdparty/cnpy/LICENSE;md5=689f10b06d1ca2d4b1057e67b16cd580 \ | ||
31 | file://thirdparty/json/nlohmann_json/LICENSE.MIT;md5=f969127d7b7ed0a8a63c2bbeae002588 \ | ||
32 | file://thirdparty/ade/LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57 \ | ||
33 | file://src/plugins/intel_cpu/thirdparty/onednn/LICENSE;md5=b48e3de3bfd47c27882a0d85b20823f5 \ | ||
34 | file://src/plugins/intel_gpu/thirdparty/onednn_gpu/LICENSE;md5=b48e3de3bfd47c27882a0d85b20823f5 \ | ||
35 | " | ||
36 | |||
37 | inherit cmake python3native pkgconfig | ||
38 | |||
39 | S = "${WORKDIR}/git" | ||
40 | EXTRA_OECMAKE += " \ | ||
41 | -DENABLE_OPENCV=OFF \ | ||
42 | -DENABLE_INTEL_GNA=OFF \ | ||
43 | -DENABLE_SYSTEM_TBB=ON \ | ||
44 | -DPYTHON_EXECUTABLE=${PYTHON} \ | ||
45 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ | ||
46 | -DTHREADING=TBB -DTBB_DIR="${STAGING_LIBDIR}/cmake/TBB" \ | ||
47 | -DTREAT_WARNING_AS_ERROR=FALSE \ | ||
48 | -DENABLE_DATA=FALSE \ | ||
49 | -DENABLE_SYSTEM_PUGIXML=TRUE \ | ||
50 | -DENABLE_SYSTEM_PROTOBUF=TRUE \ | ||
51 | -DENABLE_OV_ONNX_FRONTEND=FALSE \ | ||
52 | -DUSE_BUILD_TYPE_SUBFOLDER=OFF \ | ||
53 | -DENABLE_FUZZING=OFF \ | ||
54 | -DENABLE_TBBBIND_2_5=OFF \ | ||
55 | -DCPACK_GENERATOR=RPM \ | ||
56 | -DENABLE_SYSTEM_FLATBUFFERS=ON \ | ||
57 | -DENABLE_SYSTEM_SNAPPY=ON \ | ||
58 | " | ||
59 | |||
60 | |||
61 | DEPENDS += "\ | ||
62 | flatbuffers-native \ | ||
63 | gflags \ | ||
64 | protobuf \ | ||
65 | protobuf-native \ | ||
66 | protobuf-c \ | ||
67 | pugixml \ | ||
68 | python3-pybind11 \ | ||
69 | snappy \ | ||
70 | tbb \ | ||
71 | zlib \ | ||
72 | " | ||
73 | |||
74 | COMPATIBLE_HOST = '(x86_64).*-linux' | ||
75 | COMPATIBLE_HOST:libc-musl = "null" | ||
76 | |||
77 | PACKAGECONFIG ?= "opencl samples" | ||
78 | PACKAGECONFIG[opencl] = "-DENABLE_INTEL_GPU=TRUE, -DENABLE_INTEL_GPU=FALSE, virtual/opencl-icd opencl-headers opencl-clhpp," | ||
79 | PACKAGECONFIG[python3] = "-DENABLE_PYTHON=ON -DPYTHON_LIBRARY=${PYTHON_LIBRARY} -DPYTHON_INCLUDE_DIR=${PYTHON_INCLUDE_DIR}, -DENABLE_PYTHON=OFF, python3-cython-native patchelf-native, python3 python3-numpy python3-progress python3-cython" | ||
80 | PACKAGECONFIG[samples] = "-DENABLE_SAMPLES=ON -DENABLE_COMPILE_TOOL=ON, -DENABLE_SAMPLES=OFF -DENABLE_COMPILE_TOOL=OFF, opencv" | ||
81 | PACKAGECONFIG[verbose] = "-DVERBOSE_BUILD=1,-DVERBOSE_BUILD=0" | ||
82 | |||
83 | do_configure:prepend() { | ||
84 | # Dont set PROJECT_ROOT_DIR | ||
85 | sed -i -e 's:\${OpenVINO_SOURCE_DIR}::;' ${S}/src/CMakeLists.txt | ||
86 | } | ||
87 | |||
88 | do_install:append() { | ||
89 | rm -rf ${D}${prefix}/install_dependencies | ||
90 | rm -rf ${D}${prefix}/setupvars.sh | ||
91 | |||
92 | sed -i -e 's:^#include.*imp.hpp"$:#include "/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}/git/src/plugins/intel_cpu/src/nodes/proposal_imp.hpp":g;' ${B}/src/plugins/intel_cpu/cross-compiled/proposal_imp_disp.cpp | ||
93 | } | ||
94 | |||
95 | # Otherwise e.g. ros-openvino-toolkit-dynamic-vino-sample when using dldt-inference-engine uses dldt-inference-engine WORKDIR | ||
96 | # instead of RSS | ||
97 | SSTATE_SCAN_FILES:append = " *.cmake" | ||
98 | |||
99 | FILES:${PN} += "\ | ||
100 | ${libdir}/openvino-${PV}/lib*${SOLIBSDEV} \ | ||
101 | ${libdir}/openvino-${PV}/plugins.xml \ | ||
102 | ${libdir}/openvino-${PV}/cache.json \ | ||
103 | " | ||
104 | |||
105 | # Move inference engine samples into a separate package | ||
106 | PACKAGES =+ "${PN}-samples" | ||
107 | |||
108 | FILES:${PN}-samples = "${datadir}/openvino \ | ||
109 | ${bindir} \ | ||
110 | ${libdir}/libformat_reader.a \ | ||
111 | ${libdir}/libopencv_c_wrapper.a \ | ||
112 | " | ||
113 | |||
114 | # Package for inference engine python API | ||
115 | PACKAGES =+ "${PN}-${PYTHON_PN}" | ||
116 | |||
117 | FILES:${PN}-${PYTHON_PN} = "${PYTHON_SITEPACKAGES_DIR}" | ||
118 | |||
119 | UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(\d+\.\d+\.\d+))$" | ||