From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] eal: fix build of external apps with clang on armv8 Date: Mon, 14 Jan 2019 17:27:27 +0100 Message-ID: <2566607.iMXo4xvV1S@xps> References: <20190114161442.8277-1-i.maximets@samsung.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org, Pavan Nikhilesh , stable@dpdk.org To: Ilya Maximets Return-path: In-Reply-To: <20190114161442.8277-1-i.maximets@samsung.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 14/01/2019 17:14, Ilya Maximets: > In case DPDK built using GCC, RTE_TOOLCHAIN_CLANG is not defined. > But 'rte_atomic.h' is a generic header that included to the > external apps like OVS while building with DPDK. As a result, > clang build of OVS fails on ARMv8 if DPDK built using gcc: > > include/generic/rte_atomic.h:215:9: error: > implicit declaration of function '__atomic_exchange_2' > is invalid in C99 > include/generic/rte_atomic.h:494:9: error: > implicit declaration of function '__atomic_exchange_4' > is invalid in C99 > include/generic/rte_atomic.h:772:9: error: > implicit declaration of function '__atomic_exchange_8' > is invalid in C99 > > We need to check for current compiler, not the compiler used for > DPDK build. Right, API cannot rely on internal build system configuration. > Fixes: 7bdccb93078e ("eal: fix ARM build with clang") > Cc: stable@dpdk.org > > Signed-off-by: Ilya Maximets Acked-by: Thomas Monjalon