| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Clang 8.0 is going to be released in Feb-March 2019
so here we switch to release/8.x branch a bit early
so we can provide some feedback for release to be good on
OE
If one needs to use stable 7.0.1 release please use thud branch
clang 8.0 does have RISC-V backend, enable it
clang: Add building experimental targets e.g. riscv
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
| |
This helps build SDKs for risc-v when meta-clang is in layer mix
even though clang for risc-v may not fully work yet
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
| |
This was trying to build runtime during build but we already have
recipes for libcxx and compiler-rt to do that, unless we merge them into
clang recipe, we need to keep using them to provide nativesdk clang runtime
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is an overhaul of clang/llvm project related recipes
* switch to using a flat mono repo for all clang/llvm projects
* Add llvm-project-source recipe which will prepare source tree in
work-shared for all recipes much like kernel and gcc
* build lld as part of clang recipes, its much easier and saves build
time and hopefully nativesdk version will be built now for free
* switch to official git repos at git://github.com/llvm-project
* Adjust all recipes to use shared sources
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Update compiler-rt/llvm/clang/lld licence checksums
Triggerred due to copyright year update to 2018
Add libunwind and libcxxabi license to checksum list too
- Switch to https protocol for fetching from github
- Fix _finite functions on musl
- Package new .so files built with clang
- package libLLVM-${MAJOR_VER}.so as well since llvm-7 generates it
without MINOR_VERSION
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
| |
llvm-config is, by default, broken by the SSTATE_SCAN_CMD. This patch
removes llvm-config from SSTATE_SCAN_FILES.
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
|
|
|
|
|
|
| |
Allow shared or static libs to be selected by package config. Default to shared.
Signed-off-by: Michael Davis <michael.davis@essvote.com>
|
|
|
|
|
|
| |
This is no longer needed
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Daniel Díaz <daniel.diaz@linaro.org>
|
|
|
|
|
|
|
|
| |
Without this, we get a syntax error when we don't override
LLVM_TARGETS_TO_BUILD_TARGET because LLVM_TARGETS_TO_BUILD_TARGET gets
set as something like "X86X86" instead of "X86;X86".
Signed-off-by: Martin Kelly <mkelly@xevo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I could not manage to build nativesdk-clang, I encountered errors as
follows: (trimmed for purpose)
| ../gcc/x86_64-pokysdk-linux/6.3.0/ld::
| cannot find crt1.o: No such file or directory
| cannot find crtbegin.o: No such file or directory
| cannot find -lgcc
| cannot find -lgcc_s
After some investigation, I found it's caused by the llvm native tools
could not compile with crosssdk toolchains. (special linking flags
are needed)
So we introduce a cmake-native class with a task to generate a native
toolchain file, it will be used to build llvm native tools by passed
with CROSS_TOOLCHAIN_FLAGS_NATIVE.
Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
| |
This should speed up clang when compiling other stuff
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
| |
ninja is in OE-Core now
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes:
ERROR: clang-5.0.0+gitAUTOINC+f65227fd46_2ce35b601d-r0 do_package: QA Issue: clang: Files/directories were installed but not shipped in any package:
/usr/share/opt-viewer
/usr/share/opt-viewer/optrecord.py
/usr/share/opt-viewer/opt-viewer.py
/usr/share/opt-viewer/opt-stats.py
/usr/share/opt-viewer/optpmap.py
/usr/share/opt-viewer/opt-diff.py
/usr/share/opt-viewer/style.css
Please set FILES such that these items are packaged. Alternatively if they are unneeded, avoid installing them or delete them within do_install.
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When we are building an unreleased version the so name is:
libLLVM-MAJOR.MINORsvn.so
instead of just
libLLVM-MAJOR.MINOR.so
E.g.:
libLLVM-5.0svn.so
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
|
|
|
|
|
|
|
|
| |
Originally TARGETS_TO_BUILD was limited to the target architecture,
which is not enough to build code for heterogenous systems such as (in
my case) AMDGPU.
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
| |
Use regular expressions for mapping to a llvm arch
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As described in issue #33, LLVM_TARGETS_TO_BUILD should include
build host as well as target arches and that fails since we build
clang-native once for all due to its inherent cross compilable nature
if one needs to limit the targets please set it in local.conf or
via a bbappend in own layer e.g.
LLVM_TARGETS_TO_BUILD = "ARM"
if you only need 32bit arm or
LLVM_TARGETS_TO_BUILD = "ARM;Aarch64"
in case of both arm 32bit and 64bit
fixes #33
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
cmake.bbclass in oe-core master (soon to be Pyro) doesn't set
CMAKE_CROSSCOMPILING unconditionally, but only when it's actually
cross-compiling.
This means the clang-native build doesn't think it's cross-compiling, so the
recipe can be simplified.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
|
|
|
|
|
| |
Binutils is not needed during compile time. Add it instead to
RRECOMMENDS_clang.
Signed-off-by: Ismo Puustinen <ismo.puustinen@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Allow the user to not build all clang target architectures (by default, all
architectures are built). This speeds up build times and reduces image size.
Note, however, that the set of architectures built must still be the same
between the native and cross clang, because the native llvm-config reports
--targets-built according to what "clang-native" supports. Thus when we have
target libraries that are a subset of native libraries, the cross llvm-config
will fail because it can't find some of the libraries that the native
llvm-config finds.
Signed-off-by: Martin Kelly <mkelly@xevo.com>
|
|
|
|
|
|
|
| |
It's useful to have a shared library version of LLVM for programs that require
it.
Signed-off-by: Martin Kelly <mkelly@xevo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The llvm-common wrapper refers to the LLVM_WANT_RELEASE variable, which is not
actually exported, so it fails. In addition, meta-clang does not support
multiple side-by-side LLVM versions anyway, so the logic isn't really needed.
After fixing these issues, I discovered that llvm-config doesn't cross-compile
properly without more extensive wrapping. Specifically, the native llvm-config
supplies --libdir, and other arguments relative to its current
executable path, so it points into the native sysroot rather than the target
sysroot. In addition, it supplies the native rather than the target compile
CFLAGS, LDFLAGS, etc.
Fix these issues by doing the following:
- Alter the llvm-config to intercept certain flags, such as --cflags, while
passing on other flags to the native llvm-config.
- Patch llvm-config to be able to specify an alternate root location on which to
base --libdir, etc. in order to optionally point into the target sysroot when
needed.
Signed-off-by: Martin Kelly <mkelly@xevo.com>
|
|
|
|
| |
Signed-off-by: Martin Kelly <mkelly@xevo.com>
|
|
|
|
| |
Signed-off-by: Martin Kelly <mkelly@xevo.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
| |
It was looking into compiler install area but for OE
cross compiling scenario the compiler runtime is installed
into target sysroot, Fix clang to look into sysroot
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
| |
clang
One can still use -stdlib=libstdc++ and -rtlib=libgcc to use gcc runtime
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
| |
Slows down compilation by 6x
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
We need full triplet for it to use right linker/assembler
for complete compile step, otherwise it invokes gcc to do
linking and that confuses options e.g. pasing -Wa,--noexecstack
gets passed to gcc during link, this is a gnu assembler option
gcc: error: unrecognized command line option ‘--noexecstack’; did you mean ‘--no-backtrace’?
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes #26
Configuring a default target to match the target
is needed since we are cross building clang to run
on target by default it chooss the build host as
target
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
With the layer defaults (TOOLCHAIN ??= gcc) clang for target fails
to build due to missing compilers in the native (recipe specific)
sysroot.
Set the necessary additional DEPENDS if TOOLCHAIN = gcc to get the
compilers installed.
Signed-off-by: Mikko Ylinen <mikko.ylinen@linux.intel.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
clang was searching for <install-dir>/../lib for target libs this started to
break when rss changed the location of cross compiler to be inside package build
dir and suddenly the prefix for target sysroot and cross compiler install path
fall under same path.
Fixes issues like
| arm-oe-linux-gnueabi-clang++ -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7 -mlittle-endi
an -march=armv7a -D__extern_always_inline=inline -no-integrated-as -Wno-error=unused-command-line-argu
ment --sysroot=/mnt/a/build/tmp-glibc/work/cortexa7t2hf-neon-vfpv4-oe-linux-gnueabi/gptfdisk/1.0.1-r0/
recipe-sysroot crc32.o support.o guid.o gptpart.o mbrpart.o basicmbr.o mbr.o gpt.o bsd.o parttypes.o a
ttributes.o diskio.o diskio-unix.o cgdisk.o gptcurses.o -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -
fstack-protector-strong -Wl,-z,relro,-z,now -luuid -lncursesw -o cgdisk
| /mnt/a/build/tmp-glibc/work/cortexa7t2hf-neon-vfpv4-oe-linux-gnueabi/gptfdisk/1.0.1-r0/recipe-sysroo
t-native/usr/bin/../lib/libncursesw.so.5: file not recognized: File format not recognized
| clang-4.0: error: linker command failed with exit code 1 (use -v to see invocation)
| make: *** [Makefile:21: cgdisk] Error 1
Here it picked libncursesw.so.5 from native sysroot which is wrong for cross compile
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
| |
3.9 is now branched for morty
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
| |
AEABI floating point helper functions always use AAPCS (soft-float)
calling convention. Recognize MUSLEABI targets to fix the code generated
for musl-based hard-float builds.
Signed-off-by: Dominic Sacré <dominic.sacre@gmx.de>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixed QA warning e.g.
ERROR: QA Issue: clang: Files/directories were installed but not shipped in any package:
/usr/lib/cmake
/usr/lib/cmake/clang
/usr/lib/cmake/llvm
/usr/lib/cmake/clang/ClangTargets-release.cmake
/usr/lib/cmake/clang/ClangConfig.cmake
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
| |
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
| |
Drop upstreamed patches
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
|
|
|
|
|
| |
Otherwise llvm-tblgen cannot be found if clang happens
to be built before clang-native.
Signed-off-by: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com>
|
|
|
|
|
|
|
|
|
|
| |
This solves some clang issues. A few recipes rely on gcc's
-I= syntax. This is a backport of the feature to the 3.8
branch. It's already in 3.9.
See https://llvm.org/bugs/show_bug.cgi?id=26965
Signed-off-by: Daniel McGregor <daniel.mcgregor@vecima.com>
|