llvm / llvm-project

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.
http://llvm.org
Other
29.19k stars 12.04k forks source link

Ubuntu packages have IR in .a files instead of native code #43285

Open llvmbot opened 5 years ago

llvmbot commented 5 years ago
Bugzilla Link 43940
Version trunk
OS Linux
Attachments build.bash
Reporter LLVM Bugzilla Contributor
CC @zygoloid

Extended Description

Recently in Ubuntu packages I started to see that libclang .a files contain .o files that contain LLVM bitcode instead of native code.

This breaks linking other tools with ld and makes linking with ld.lld terribly slow because it has to rebuild bitcode into native code.

There is a workaround (see build.bash), but relying on it defeats the purpose of using binary packages because it is also terribly slow.

llvmbot commented 5 years ago

build.bash

llvmbot commented 5 years ago

Some keywords to make it more searcheable: /usr/bin/ld: /usr/lib/llvm-10/lib/libclangCodeGen.a: error adding symbols: archive has no index; run ranlib to add one