> -----Original Message----- > From: dev <[email protected]> On Behalf Of Juraj Linke? > Sent: Friday, October 2, 2020 5:38 PM > To: [email protected]; [email protected]; > [email protected]; [email protected] > Cc: [email protected]; Juraj Linkeš <[email protected]> > Subject: [dpdk-dev] [PATCH v3 1/3] build: add aarch64 clang to meson cross- > compile > > Create meson cross file arm64_armv8_linux_clang_ubuntu1804. > Use clang/LLVM toolchain with sysroot pointing to gcc cross stdlib. > > Signed-off-by: Juraj Linkeš <[email protected]> > --- > config/arm/arm64_armv8_linux_clang_ubuntu1804 | 20 > +++++++++++++++++++ > 1 file changed, 20 insertions(+) > create mode 100644 config/arm/arm64_armv8_linux_clang_ubuntu1804 > > diff --git a/config/arm/arm64_armv8_linux_clang_ubuntu1804 > b/config/arm/arm64_armv8_linux_clang_ubuntu1804 > new file mode 100644 > index 000000000..67f475eb0 > --- /dev/null > +++ b/config/arm/arm64_armv8_linux_clang_ubuntu1804 > @@ -0,0 +1,20 @@ > +[binaries] > +c = 'clang' > +cpp = 'clang++' > +ar = 'llvm-ar' > +strip = 'llvm-strip' > +llvm-config = 'llvm-config' > +pcap-config = 'llvm-config' > +pkgconfig = 'aarch64-linux-gnu-pkg-config' > + > +[host_machine] > +system = 'linux' > +cpu_family = 'aarch64' > +cpu = 'armv8-a' > +endian = 'little' > + > +[properties] > +implementor_id = 'generic' > +implementor_pn = 'default' > +c_args = ['-target', 'aarch64-linux-gnu', '--sysroot', > +'/usr/aarch64-linux-gnu', '--gcc-toolchain=/usr'] c_link_args = > +['-target', 'aarch64-linux-gnu', '-fuse-ld=lld'] > -- > 2.20.1
I understand specific flags are needed by clang to do cross compiling. Path to gnu libc which is required could be different on some other systems. The cross file works on Ubuntu, and could be referred to by other systems. Reviewed-by: Ruifeng Wang <[email protected]>

