[Dist/Debian] Prepare for GCC >= 10 98/278798/2 sandbox/mzx/ubt22 sandbox/wooksong
authorMyungJoo Ham <myungjoo.ham@samsung.com>
Tue, 26 Jul 2022 07:30:49 +0000 (16:30 +0900)
committerMyungJoo Ham <myungjoo.ham@samsung.com>
Thu, 28 Jul 2022 05:19:17 +0000 (14:19 +0900)
Ubuntu 22.04 / GCC >= 10 incurs errors in openvino.

Change-Id: I6470ad318fcd6f6dffcd88eab95fd52dbaa027f8
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
debian/control
debian/rules
inference-engine/src/mkldnn_plugin/mkldnn_memory_solver.hpp
inference-engine/tests/helpers/tests_file_utils.hpp

index 246301b..ccf8778 100644 (file)
@@ -4,8 +4,8 @@ Section: libs
 Priority: optional
 Build-Depends: debhelper (>= 9.0.0), quilt,
  cmake, pkg-config,
- gcc-9 | gcc-8 | gcc-7 | gcc-6 | gcc-5,
- g++-9 | g++-8 | g++-7 | g++-6 | g++-5,
+ gcc-10 | gcc-8 | gcc-7 | gcc-6 | gcc-5,
+ g++-10 | g++-8 | g++-7 | g++-6 | g++-5,
  libusb-1.0-0-dev
 Standards-Version: 4.1.4
 Vcs-Git: git://git.tizen.org/platform/upstream/dldt
index 4276a84..96af22e 100755 (executable)
@@ -63,7 +63,7 @@ override_dh_auto_configure: prepare_tbb
        cd $(SRC_ROOT)/inference-engine/thirdparty && \
                        rm -rf *.tar.gz $(EXTERNAL_NGRAPH_ARCHIVE)
        cd $(SRC_ROOT)/inference-engine && rm -rf build && mkdir -p build
-       cd $(SRC_ROOT)/inference-engine/build && cmake .. \
+       cd $(SRC_ROOT)/inference-engine/build && if [ -f /usr/bin/gcc-10 ]; then export CC=/usr/bin/gcc-10 && export CXX=/usr/bin/g++-10; fi && cmake .. \
                        -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_INSTALL_PREFIX:PATH=$(PREFIX) \
                        -DCMAKE_INSTALL_LIBDIR:PATH=$(LIBDIR) -DINCLUDE_INSTALL_DIR:PATH=$(INCDIR) \
                        -DLIB_INSTALL_DIR:PATH=$(LIBDIR) -DSYSCONF_INSTALL_DIR:PATH=$(SYSCONFDIR) \
@@ -83,7 +83,9 @@ override_dh_auto_configure: prepare_tbb
                        -DENABLE_OBJECT_DETECTION_TESTS=ON -DENABLE_OPENCV=OFF -DENABLE_PLUGIN_RPATH=OFF \
                        -DENABLE_PROFILING_ITT=OFF -DENABLE_PROFILING_RAW=OFF -DENABLE_PYTHON=OFF -DENABLE_ROCKHOPER=OFF \
                        -DENABLE_SAMPLES=OFF -DENABLE_SAMPLES_CORE=OFF -DENABLE_SEGMENTATION_TESTS=OFF -DENABLE_TESTS=ON \
-                       -DTREAT_WARNING_AS_ERROR=OFF
+                       -DTREAT_WARNING_AS_ERROR=OFF \
+                       -DCMAKE_CXX_FLAGS="-Wno-odr -fno-lto"
+
 
 override_dh_auto_build:
                dh_auto_build --builddirectory=$(SRC_ROOT)/inference-engine/build --
index 3abb891..18be4f2 100644 (file)
@@ -18,6 +18,8 @@
 #include <mach/mach.h>
 #endif
 
+#include <time.h>
+
 namespace testing { namespace FileUtils {
 #ifdef _WIN32
     /// @brief TODO: description