Displaying 12 results from an estimated 12 matches for "dcmake_try_compile_target_type".
2020 Nov 10
1
Building an LLVM cross-compiler
...this:
>I like this. I hope you don't mind if I borrow some of these ideas to
>play with. C_COMPILER_WORKS is something I've never heard of.
I'm also working on building a clang-based toolchain from scratch.
To avoid CMake bailing out when a binary can't be linked, I use:
-DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY
Along with:
-DCMAKE_SYSTEM_NAME="Generic"
-DCMAKE_SYSTEM_PROCESSOR="powerpc"
Best Regards,
Vlad
2020 Sep 14
2
Cross compiling for ARMv7-m
Hi Peter,
On Wed, 26 Feb 2020 at 18:37, Peter Smith via llvm-dev
<llvm-dev at lists.llvm.org> wrote:
>
> Hello Arslan,
>
> > I am guessing I can borrow libraries such as lc and lm from GCC
> > arm-none-eabi*, but for clang_rt.builtins-arm.a (which I thought
> > should've been built with LLVM build but I couldn't find that library
> > in my build
2018 Dec 13
2
Compiling for baremetal ARMv4 on Ubuntu Linux
...SANITIZERS=OFF
-DCOMPILER_RT_BUILD_XRAY=OFF -DCOMPILER_RT_BUILD_LIBFUZZER=OFF
-DCOMPILER_RT_BUILD_PROFILE=OFF
-DCMAKE_C_COMPILER=/usr/local/myclang/bin/clang
-DCMAKE_AR=/usr/local/myclang/bin/llvm-ar
-DCMAKE_NM=/usr/local/myclang/bin/llvm-nm
-DCMAKE_RANLIB=/usr/local/myclang/bin/llvm-ranlib
-DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY
-DCMAKE_C_COMPILER_TARGET="arm-linux-gnueabihf"
-DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON
-DLLVM_CONFIG_PATH=/usr/local/myclang/bin/llvm-config
-DCMAKE_ASM_FLAGS="--target=arm-linux-gnueabihf -march=armv7a
--gcc-toolchain=/home/crichter/arm-linux-gnueabihf/gcc-arm
--s...
2018 Dec 14
3
Compiling for baremetal ARMv4 on Ubuntu Linux
..._BUILD_SANITIZERS=OFF -DCOMPILER_RT_BUILD_XRAY=OFF -DCOMPILER_RT_BUILD_LIBFUZZER=OFF -DCOMPILER_RT_BUILD_PROFILE=OFF -DCMAKE_C_COMPILER=/usr/local/myclang/bin/clang -DCMAKE_AR=/usr/local/myclang/bin/llvm-ar -DCMAKE_NM=/usr/local/myclang/bin/llvm-nm -DCMAKE_RANLIB=/usr/local/myclang/bin/llvm-ranlib -DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY -DCMAKE_C_COMPILER_TARGET="arm-linux-gnueabihf" -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON -DLLVM_CONFIG_PATH=/usr/local/myclang/bin/llvm-config -DCMAKE_ASM_FLAGS="--target=arm-linux-gnueabihf -march=armv7a --gcc-toolchain=/home/crichter/arm-linux-gnueabihf/gcc-arm --sysroot...
2019 Nov 20
2
libunwind is not configured with -funwind-tables when building it for ARM Linux?
...and compiler-rt
>>
>>
>> That’s what I’m doing as well.
>
> Apologies for the delay in responding, I thought I'd better dig out
> build my script to check to see what unwind tables were present in
> libunwind. I found that when building libunwind I needed
> -DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY for the CMake test for
> unwind tables to succeed when cross-compiling. If I took that out the
> test failed and I ended up with no exceptions.
Thank you for your time!
I’ve tried CMAKE_TRY_COMPILE_TARGET_TYPE and it works. But setting this option manually seems suboptimal to...
2019 Feb 04
2
Compiling for baremetal ARMv4 on Ubuntu Linux
..._BUILD_SANITIZERS=OFF -DCOMPILER_RT_BUILD_XRAY=OFF -DCOMPILER_RT_BUILD_LIBFUZZER=OFF -DCOMPILER_RT_BUILD_PROFILE=OFF -DCMAKE_C_COMPILER=/usr/local/myclang/bin/clang -DCMAKE_AR=/usr/local/myclang/bin/llvm-ar -DCMAKE_NM=/usr/local/myclang/bin/llvm-nm -DCMAKE_RANLIB=/usr/local/myclang/bin/llvm-ranlib -DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY -DCMAKE_C_COMPILER_TARGET="arm-linux-gnueabihf" -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON -DLLVM_CONFIG_PATH=/usr/local/myclang/bin/llvm-config -DCMAKE_ASM_FLAGS="--target=arm-linux-gnueabihf -march=armv7a --gcc-toolchain=/home/crichter/arm-linux-gnueabihf/gcc-arm --sysroot...
2019 Mar 04
2
Compiling for baremetal ARMv4 on Ubuntu Linux
..._BUILD_SANITIZERS=OFF -DCOMPILER_RT_BUILD_XRAY=OFF -DCOMPILER_RT_BUILD_LIBFUZZER=OFF -DCOMPILER_RT_BUILD_PROFILE=OFF -DCMAKE_C_COMPILER=/usr/local/myclang/bin/clang -DCMAKE_AR=/usr/local/myclang/bin/llvm-ar -DCMAKE_NM=/usr/local/myclang/bin/llvm-nm -DCMAKE_RANLIB=/usr/local/myclang/bin/llvm-ranlib -DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY -DCMAKE_C_COMPILER_TARGET="arm-linux-gnueabihf" -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON -DLLVM_CONFIG_PATH=/usr/local/myclang/bin/llvm-config -DCMAKE_ASM_FLAGS="--target=arm-linux-gnueabihf -march=armv7a --gcc-toolchain=/home/crichter/arm-linux-gnueabihf/gcc-arm --sysroot...
2018 Dec 10
2
Compiling for baremetal ARMv4 on Ubuntu Linux
...SANITIZERS=OFF
-DCOMPILER_RT_BUILD_XRAY=OFF -DCOMPILER_RT_BUILD_LIBFUZZER=OFF
-DCOMPILER_RT_BUILD_PROFILE=OFF
-DCMAKE_C_COMPILER=/usr/local/myclang/bin/clang
-DCMAKE_AR=/usr/local/myclang/bin/llvm-ar
-DCMAKE_NM=/usr/local/myclang/bin/llvm-nm
-DCMAKE_RANLIB=/usr/local/myclang/bin/llvm-ranlib
-DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY
-DCMAKE_C_COMPILER_TARGET="arm-linux-gnueabihf"
-DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON
-DLLVM_CONFIG_PATH=/usr/local/myclang/bin/llvm-config
-DCMAKE_ASM_FLAGS="--target=arm-linux-gnueabihf -march=armv7a"
-DCMAKE_C_FLAGS="--target=arm-linux-gnueabihf -march...
2019 Mar 11
2
Compiling for baremetal ARMv4 on Ubuntu Linux
..._BUILD_SANITIZERS=OFF -DCOMPILER_RT_BUILD_XRAY=OFF -DCOMPILER_RT_BUILD_LIBFUZZER=OFF -DCOMPILER_RT_BUILD_PROFILE=OFF -DCMAKE_C_COMPILER=/usr/local/myclang/bin/clang -DCMAKE_AR=/usr/local/myclang/bin/llvm-ar -DCMAKE_NM=/usr/local/myclang/bin/llvm-nm -DCMAKE_RANLIB=/usr/local/myclang/bin/llvm-ranlib -DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY -DCMAKE_C_COMPILER_TARGET="arm-linux-gnueabihf" -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON -DLLVM_CONFIG_PATH=/usr/local/myclang/bin/llvm-config -DCMAKE_ASM_FLAGS="--target=arm-linux-gnueabihf -march=armv7a --gcc-toolchain=/home/crichter/arm-linux-gnueabihf/gcc-arm --sysroot...
2019 Nov 18
2
libunwind is not configured with -funwind-tables when building it for ARM Linux?
> On 18 Nov 2019, at 19:55, Peter Smith <peter.smith at linaro.org> wrote:
>
> On Mon, 18 Nov 2019 at 15:23, Sergej Jaskiewicz <jaskiewiczs at icloud.com <mailto:jaskiewiczs at icloud.com>> wrote:
>>
>> Hi Peter,
>>
>> Thanks for your response.
>>
>> On 18 Nov 2019, at 17:44, Peter Smith <peter.smith at linaro.org> wrote:
2018 Dec 07
2
Compiling for baremetal ARMv4 on Ubuntu Linux
...SANITIZERS=OFF
-DCOMPILER_RT_BUILD_XRAY=OFF -DCOMPILER_RT_BUILD_LIBFUZZER=OFF
-DCOMPILER_RT_BUILD_PROFILE=OFF
-DCMAKE_C_COMPILER=/usr/local/myclang/bin/clang
-DCMAKE_AR=/usr/local/myclang/bin/llvm-ar
-DCMAKE_NM=/usr/local/myclang/bin/llvm-nm
-DCMAKE_RANLIB=/usr/local/myclang/bin/llvm-ranlib
-DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY
-DCMAKE_C_COMPILER_TARGET="arm-linux-gnueabihf"
-DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON
-DLLVM_CONFIG_PATH=/usr/local/myclang/bin/llvm-config
-DCMAKE_C_FLAGS="--target=arm-linux-gnueabihf -march=armv7a
--gcc-toolchain=/usr/arm-linux-gnueabihf
--sysroot=/usr/arm-linu...
2018 Dec 04
2
Compiling for baremetal ARMv4 on Ubuntu Linux
I am currently trying to compile a pretty simple program to work on an
experimental board. It contains an (FPGA-version of) an ARMv4 processor.
So basically, I try this (on my Ubuntu 18.04.1 LTS):
clang -v --target=arm-none-eabi -c barehello.c -o barehelloCLANG.o
clang -v --target=arm-none-eabi -c io.c -o io.o
clang -v --target=arm-none-eabi barehelloCLANG.o io.o -o
helloCLANGstatic -static