From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id CC19FA00BE; Thu, 10 Feb 2022 16:43:34 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D5BB142770; Thu, 10 Feb 2022 16:43:15 +0100 (CET) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mails.dpdk.org (Postfix) with ESMTP id AE483426ED; Thu, 10 Feb 2022 16:43:08 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1644507789; x=1676043789; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=veIxnvD4HcP71geTR9XiNe9UbAQ5n7+OKC29V7i55zI=; b=YXa2qRd6Gfw4KNmm+GZRaPuvyYW8S3DVBTthTaCSAyxac0iAhuyIVI0N 5jCHga5Rx02YKLdfj2i99ATDN7tBRq2inOh0bUv5I+GDcF0onLDelzja9 GN4KsSXOBHhQ1BQ39j9G5sV0/hTk6UNk00GJy7wfrhoA6oV7UffUjeuo/ G8voMyF7WkQxdcoRTAy4m93yHe+w/ZIWX1CB2puoL3WlFTdfepBioP9Ak 88F94lL2SWifm62t9VobDlxxGxuHuNwTi7cYgeOFqtQlIsPtveXOIwekD x6YD10b1OHzOxdxJVxS5kT98eNj5OPeUTNVwDkcr1MSXg1v06AyBSHmdw Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10254"; a="247101207" X-IronPort-AV: E=Sophos;i="5.88,359,1635231600"; d="scan'208";a="247101207" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Feb 2022 07:43:06 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,359,1635231600"; d="scan'208";a="485723489" Received: from silpixa00399126.ir.intel.com ([10.237.223.162]) by orsmga006.jf.intel.com with ESMTP; 10 Feb 2022 07:43:04 -0800 From: Bruce Richardson To: dev@dpdk.org Cc: Bruce Richardson , adrien.mazarguil@6wind.com, stable@dpdk.org, Yuanhan Liu , Maxime Coquelin Subject: [PATCH v4 6/7] vhost: fix incompatible header includes for C++ Date: Thu, 10 Feb 2022 15:42:38 +0000 Message-Id: <20220210154239.587185-7-bruce.richardson@intel.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20220210154239.587185-1-bruce.richardson@intel.com> References: <20220204174209.440207-1-bruce.richardson@intel.com> <20220210154239.587185-1-bruce.richardson@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org The virtio kernel header includes are already noted as being incompatible with C++. We can ensure that the header is safe for inclusion in C++ code by not including those headers during C++ builds. While not ideal, this does ensure that all DPDK headers can be included in C++ code without errors. Fixes: f8904d563691 ("vhost: fix header for strict compilation flags") Cc: adrien.mazarguil@6wind.com Cc: stable@dpdk.org Signed-off-by: Bruce Richardson --- lib/vhost/rte_vhost.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/vhost/rte_vhost.h b/lib/vhost/rte_vhost.h index b454c05868..2acb31df2d 100644 --- a/lib/vhost/rte_vhost.h +++ b/lib/vhost/rte_vhost.h @@ -21,10 +21,12 @@ extern "C" { #endif +#ifndef __cplusplus /* These are not C++-aware. */ #include #include #include +#endif #define RTE_VHOST_USER_CLIENT (1ULL << 0) #define RTE_VHOST_USER_NO_RECONNECT (1ULL << 1) -- 2.32.0