From: Yuval Lifshitz Date: Thu, 12 Sep 2019 13:16:41 +0000 (+0300) Subject: nautilus: cmake/BuildDPDK: ignore gcc8/9 warnings X-Git-Tag: v14.2.5~52^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=2bf60f718ceb8f1deb895d12d338df39ea384a06;p=ceph.git nautilus: cmake/BuildDPDK: ignore gcc8/9 warnings Signed-off-by: Yuval Lifshitz Conflicts: cmake/modules/BuildDPDK.cmake this change is not cherry-picked from master, because master has picked up an updated SPDK which is in turn using a DPDK containing fixes like a385972c, 3370975b, 74f27710 and e5e193ac and a36b40dd. these changes either disables the"address-of-packed-member" warnings or addresses "error=stringop-truncation" warnings. --- diff --git a/cmake/modules/BuildDPDK.cmake b/cmake/modules/BuildDPDK.cmake index 12a831a8b10a6..fe4a0acf15f2c 100644 --- a/cmake/modules/BuildDPDK.cmake +++ b/cmake/modules/BuildDPDK.cmake @@ -71,11 +71,13 @@ function(do_build_dpdk dpdk_dir) "\"${target}\" not listed in ${supported_targets}") endif() + set(EXTRA_CFLAGS "-Wno-unknown-warning-option -Wno-stringop-truncation -Wno-address-of-packed-member -fPIC") + include(ExternalProject) ExternalProject_Add(dpdk-ext SOURCE_DIR ${CMAKE_SOURCE_DIR}/src/spdk/dpdk CONFIGURE_COMMAND $(MAKE) config O=${dpdk_dir} T=${target} - BUILD_COMMAND env CC=${CMAKE_C_COMPILER} $(MAKE) O=${dpdk_dir} EXTRA_CFLAGS=-fPIC + BUILD_COMMAND env CC=${CMAKE_C_COMPILER} $(MAKE) O=${dpdk_dir} EXTRA_CFLAGS=${EXTRA_CFLAGS} BUILD_IN_SOURCE 1 INSTALL_COMMAND "true") ExternalProject_Add_Step(dpdk-ext patch-config