<div id="appVersion:飞书-4.8.1-editorVersion:0.9.6"></div><div><div style="line-height:1.68"><div style="font-family:arial,helvetica,sans-serif;color:rgb(31,35,41);line-height:1.68"><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">Hi, </span><span class=" backgroundcolor fontweight  fontsize fontcolor " style="background-color:rgba(0,0,0,0);font-weight:400;font-size:14px;color:#1f2329">I got an error when I specified gcc8.3 toolchain to build LLVM13. </span><span class=" fontsize " style="font-size:14px">Here is my host environment:</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">Debian9</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">gcc6.3</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">Manully built toolchain: gcc8.3</span></div><div class="" dir="auto" style="margin:4px 0px"><br></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">===============================================================================================</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">Here is my command:</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">$ CXX=/home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/bin/g++ CC=/home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/bin/gcc cmake -G Ninja -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra;lld;lldb;openmp" -DLLVM_ENABLE_RUNTIMES="compiler-rt;libcxx;libcxxabi;libunwind" -DLLVM_TARGETS_TO_BUILD="X86;ARM;AArch64" -DCMAKE_BUILD_TYPE=Release  -DLLVM_BUILD_LLVM_DYLIB=ON -DLLVM_LINK_LLVM_DYLIB=ON -DCMAKE_CXX_LINK_FLAGS="-Wl,-rpath /home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/lib64 -L/home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/lib64 -Wl,-rpath /home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/sysroot/lib64 -L/home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/sysroot/lib64 -Wl,-dynamic-linker /home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/sysroot/lib64/</span><span class="outer-u-container "><span class=" hyperlink-href:ld-linux-x86-64.so fontsize " style="font-size:14px"><a href="http://ld-linux-x86-64.so" rel="noopener" target="_blank" style="text-decoration:none;color:rgb(51,112,255)">ld-linux-x86-64.so</a></span></span><span class=" fontsize " style="font-size:14px">.2 -L/home/liuke.gehry/toolchain/x86_64-x86_64-gcc-830/sysroot/lib64/</span><span class="outer-u-container "><span class=" hyperlink-href:ld-linux-x86-64.so fontsize " style="font-size:14px"><a href="http://ld-linux-x86-64.so" rel="noopener" target="_blank" style="text-decoration:none;color:rgb(51,112,255)">ld-linux-x86-64.so</a></span></span><span class=" fontsize " style="font-size:14px">.2" ../llvm</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">$ ninja</span></div><div class="" dir="auto" style="margin:4px 0px"><br></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">[99/302] Building C object CMakeFiles/clang_rt.builtins-i386.dir/floatsisf.c.o</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">FAILED: CMakeFiles/clang_rt.builtins-i386.dir/floatsisf.c.o</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">/home/liuke.gehry/llvm/llvm-project/build_with_gcc/./bin/clang --target=x86_64-unknown-linux-gnu -DVISIBILITY_HIDDEN  -O3 -DNDEBUG    -m32 -std=c11 -fPIC -fno-builtin -fvisibility=hidden -MD -MT CMakeFiles/clang_rt.builtins-i386.dir/floatsisf.c.o -MF CMakeFiles/clang_rt.builtins-i386.dir/floatsisf.c.o.d -o CMakeFiles/clang_rt.builtins-i386.dir/floatsisf.c.o   -c /home/liuke.gehry/llvm/llvm-project/compiler-rt/lib/builtins/floatsisf.c</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">In file included from /home/liuke.gehry/llvm/llvm-project/compiler-rt/lib/builtins/floatsisf.c:16:</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">In file included from /home/liuke.gehry/llvm/llvm-project/compiler-rt/lib/builtins/fp_lib.h:23:</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">In file included from /home/liuke.gehry/llvm/llvm-project/compiler-rt/lib/builtins/int_lib.h:93:</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">In file included from /data00/home/liuke.gehry/llvm/llvm-project/build_with_gcc/lib/clang/13.0.1/include/limits.h:21:</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">In file included from /usr/include/limits.h:25:</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">/usr/include/features.h:364:12: fatal error: 'sys/cdefs.h' file not found</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">#  include <sys/cdefs.h></span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">           ^~~~~~~~~~~~~</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" fontsize " style="font-size:14px">1 error generated.</span></div><div class="" dir="auto" style="margin:4px 0px"><span class=" backgroundcolor fontweight  fontsize fontcolor " style="background-color:rgba(0,0,0,0);font-weight:400;font-size:14px;color:#1f2329">===============================================================================================</span></div><div class="" dir="auto" style="margin:4px 0px"><br></div><div class="" dir="auto" style="margin:4px 0px"><span class=" backgroundcolor fontweight  fontsize fontcolor " style="background-color:rgba(0,0,0,0);font-weight:400;font-size:14px;color:#1f2329">I know I can solve it through 'apt install'. But I do not need 32-bits binary . How can I disable '-m32' when building builtins? Or is it a necessary process?</span></div></div></div></div>