3 %global debug_package %{nil}
4 %global __debug_install_post %{nil}
6 %if "%{?_lib}" == "lib64"
7 %define _cmake_lib_suffix_flag %{?_cmake_lib_suffix64}
9 %define _cmake_lib_suffix_flag %{nil}
13 %define _cmake_sse_support_flag -DENABLE_SSE42=1
15 %define _cmake_sse_support_flag -DENABLE_SSE42=0
18 %define _extra_cmake_flags %{_cmake_lib_suffix_flag} %{_cmake_sse_support_flag} -DLINUX_OS_NAME="Tizen %{tizen_full_version}"
20 %ifarch x86_64 i686 armv7l aarch64
23 %define install_arch intel64
27 %define install_arch i686
31 %define install_arch armv7l
35 %define install_arch aarch64
39 %define install_arch %{_arch}
44 %define external_ade_archive ade-cbe2db61a659c2cc304c3837406f95c39dfa938e
45 %define external_ngraph_archive ngraph-0.22.0-rc.2
48 Summary: OpenVINO™ Toolkit - Deep Learning Deployment Toolkit
51 Group: Development/Libraries
52 Packager: Wook Song <wook16.song@samsung.com>
54 Source0: %{name}-%{version}.tar.gz
55 Source1: %{name}.manifest
56 Source1001: %{external_ade_archive}.tar.gz
57 Source1002: %{external_ngraph_archive}.tar.gz
58 Source1003: openvino.pc.in
59 Patch0: 0001-CMake-Do-not-call-get_linux_name-when-LINUX_OS_NAME-.patch
60 Patch1: 0002-CMake-Add-a-variable-to-resolve-dependency-on-TBB-us.patch
61 Patch2: 0003-VPU-CMake-Add-a-cmake-option-to-skip-downloading-MVN.patch
63 BuildRequires: pkgconfig(libtbb)
64 BuildRequires: pkgconfig(libusb-1.0)
65 BuildRequires: pkg-config
66 Requires: intel-mvnc-firmware
67 ## Please note that when you include openvino in a Tizen image (via mic/tic),
68 ## you need to specify firmware type instead of intel-mvnc-firmware or
69 ## relying on dependency resolution.
70 ## E.g., add "mvnc-2x8x-firmware" to image explicitly.
71 ## If you want to support NCS 1 and 2 simultaneously, install both firmware
75 OpenVINO™ toolkit, short for Open Visual Inference and Neural network Optimization toolkit,
76 provides developers with improved neural network performance on a variety of Intel® processors
77 and helps them further unlock cost-effective, real-time vision applications.
78 The toolkit enables deep learning inference and easy heterogeneous execution across multiple
79 Intel® platforms (CPU, Intel® Processor Graphics)—providing implementations across cloud
80 architectures to edge devices. This open source distribution provides flexibility and
81 availability to the developer community to innovate deep learning and AI solutions.
84 Summary: Development package for OpenVINO™ Toolkit
85 Requires: %{name} = %{version}-%{release}
86 Recommends: mvnc-2x8x-firmware
89 Development package for Open Visual Inference and Neural network Optimization toolkit.
90 This contains corresponding header files and static archives.
98 cp %{SOURCE1001} ./inference-engine/thirdparty
99 cp %{SOURCE1002} ./inference-engine/thirdparty
101 pushd inference-engine
103 tar zxf %{external_ade_archive}.tar.gz
104 mv %{external_ade_archive}/* ade/
105 tar zxf %{external_ngraph_archive}.tar.gz
106 mv %{external_ngraph_archive}/* ngraph/
107 rm -rf *.tar.gz %{external_ade_archive} %{external_ngraph_archive}
109 rm -rf build && mkdir -p build
111 CFLAGS="${CFLAGS:-%optflags}"; export CFLAGS=${CFLAGS/-Wall/};
112 CXXFLAGS="${CXXFLAGS:-%optflags}"; export CXXFLAGS=${CXXFLAGS/-Wall/};
113 FFLAGS="${FFLAGS:-%optflags}"; export FFLAGS=${FFLAGS/-Wall/};
115 -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \
116 -DCMAKE_INSTALL_LIBDIR:PATH=%{_libdir} -DINCLUDE_INSTALL_DIR:PATH=%{_includedir} \
117 -DLIB_INSTALL_DIR:PATH=%{_libdir} -DSYSCONF_INSTALL_DIR:PATH=%{_sysconfdir} \
118 -DSHARE_INSTALL_PREFIX:PATH=%{_datadir} \
119 %{?_cmake_skip_rpath} -DUSE_TBB_SYSTEM_DEPS=ON -DUSE_MYRIAD_SYSTEM_DEPS=ON \
120 -DENABLE_VPU=ON -DENABLE_MYRIAD=ON -DENABLE_MYRIAD_MVNC_TESTS=OFF -DENABLE_MYRIAD_NO_BOOT=OFF \
121 -DBUILD_ADE_DOCUMENTATION=OFF -DBUILD_ADE_TUTORIAL=OFF \
122 -DBUILD_PKGCONFIG=OFF -DBUILD_SHARED_LIBS=OFF -DBUILD_TESTING=OFF -DBUILD_TESTS=OFF \
123 -DCLDNN__INCLUDE_EXAMPLES=OFF -DCMAKE_BUILD_TYPE=Release -DCOVERAGE=OFF \
124 -DDEVELOPMENT_PLUGIN_MODE=OFF-DENABLE_ADE_TESTING=OFF \
125 -DENABLE_AFFINITY_GENERATOR=OFF -DENABLE_ALTERNATIVE_TEMP=OFF -DENABLE_CLDNN=OFF \
126 -DENABLE_CLDNN_BUILD=OFF -DENABLE_CLDNN_TESTS=OFF -DENABLE_CPPCHECK=OFF -DENABLE_CPPLINT=OFF \
127 -DENABLE_CPPLINT_REPORT=OFF -DENABLE_CPP_CCT=OFF -DENABLE_DEBUG_SYMBOLS=OFF \
128 -DENABLE_FUZZING=OFF -DENABLE_GAPI_TESTS=OFF -DENABLE_GNA=OFF -DENABLE_LTO=OFF \
129 -DENABLE_MKL_DNN=OFF \
130 -DENABLE_OBJECT_DETECTION_TESTS=ON -DENABLE_OPENCV=OFF -DENABLE_PLUGIN_RPATH=OFF \
131 -DENABLE_PROFILING_ITT=OFF -DENABLE_PROFILING_RAW=OFF -DENABLE_PYTHON=OFF -DENABLE_ROCKHOPER=OFF \
132 -DENABLE_SAMPLES=OFF -DENABLE_SAMPLES_CORE=OFF -DENABLE_SEGMENTATION_TESTS=OFF -DENABLE_TESTS=ON \
133 -DTREAT_WARNING_AS_ERROR=OFF %{_extra_cmake_flags}
138 pushd inference-engine
140 %{__make} %{?_smp_mflags}
143 sed -i 's|@VERSION@|%{version}|g' openvino.pc.in
144 sed -i 's|@PREFIX@|%{_prefix}|g' openvino.pc.in
145 sed -i 's|@LIB_INSTALL_DIR@|%{_libdir}|g' openvino.pc.in
146 sed -i 's|@INCLUDE_INSTALL_DIR@|%{_includedir}|g' openvino.pc.in
149 mkdir -p %{buildroot}%{_libdir}
150 mkdir -p %{buildroot}%{_libdir}/pkgconfig
151 cp openvino.pc.in %{buildroot}%{_libdir}/pkgconfig/openvino.pc
153 pushd inference-engine/bin/%{install_arch}/Release
154 install -m 644 lib/*.so %{buildroot}%{_libdir}
155 install -m 644 lib/*.xml %{buildroot}%{_libdir}
156 rm -rf lib/libstb_image.a
157 rm -rf lib/libgflags_nothreads.a
158 rm -rf lib/libgtest_main.a
159 rm -rf lib/libgtest.a
160 rm -rf lib/libgmock_main.a
161 rm -rf lib/libgmock.a
162 install -m 644 lib/*.a %{buildroot}%{_libdir}
165 mkdir -p %{buildroot}%{_includedir}
166 mkdir -p %{buildroot}%{_includedir}/builders
167 mkdir -p %{buildroot}%{_includedir}/cpp
168 mkdir -p %{buildroot}%{_includedir}/details
169 mkdir -p %{buildroot}%{_includedir}/details/os
170 mkdir -p %{buildroot}%{_includedir}/hetero
171 mkdir -p %{buildroot}%{_includedir}/multi-device
172 pushd inference-engine
173 install -m 644 include/*.h* %{buildroot}%{_includedir}
174 install -m 644 include/builders/*.h* %{buildroot}%{_includedir}/builders/
175 install -m 644 include/cpp/*.h* %{buildroot}%{_includedir}/cpp/
176 install -m 644 include/details/*.h* %{buildroot}%{_includedir}/details/
177 install -m 644 include/details/os/*.h* %{buildroot}%{_includedir}/details/os/
178 install -m 644 include/hetero/*.h* %{buildroot}%{_includedir}/hetero/
179 install -m 644 include/multi-device/*.h* %{buildroot}%{_includedir}/multi-device/
182 # Block running tests until it is stabilized
184 #pushd inference-engine/bin/%{install_arch}/Release
185 #LD_LIBRARY_PATH=./lib ./InferenceEngineUnitTests
195 %manifest %{name}.manifest
201 %manifest %{name}.manifest
204 %{_libdir}/pkgconfig/openvino.pc