Actions
Feature #19126
openclang: Cannot compile with Control Flow Integrity (CFI)
Status:
Open
Assignee:
-
Target version:
-
Description
Maybe related #19124
Reproduction¶
sudo dnf install -y yum-utils
sudo yum-config-manager --enable crb
sudo dnf install -y \
make bc binutils-gold mold patch git bison xz autoconf automake m4 libtool pkg-config perl-interpreter \
gmp-devel openssl-devel readline-devel libyaml-devel gdbm-devel zlib-devel libffi-devel \
ncurses-devel readline-devel glibc-static glibc-devel llvm-toolset
LINKER=lld # also tried bfd and mold
FLAGS='-fsanitize=cfi'
LINKFLAGS="-fuse-ld=$LINKER -fsanitize=cfi -flto=thin -fvisibility=default" # also tried =hidden
EXE_LINKFLAGS=''
export \
CC=clang \
CXX=clang++ \
LD=$LINKER \
CPPFLAGS="$FLAGS" \
CFLAGS="$FLAGS" \
CXXFLAGS="$FLAGS" \
DCFLAGS="$FLAGS" \
XCFLAGS="$FLAGS" \
MJIT_CFLAGS="$FLAGS" \
DLDFLAGS="$FLAGS $LINKFLAGS" \
LDFLAGS="$FLAGS $LINKFLAGS" \
XLDFLAGS="$FLAGS $LINKFLAGS $EXE_LINKFLAGS"
./configure --disable-install-doc --enable-shared && \
make -j && \
make test && \
sudo make install
Output¶
compiling enc/trans/newline.c
./revision.h unchanged
compiling version.c
linking miniruby
generating encdb.h
make: *** [uncommon.mk:1178: builtin_binary.inc] Illegal instruction (core dumped)
make: *** Waiting for unfinished jobs....
make: *** [uncommon.mk:841: .rbconfig.time] Illegal instruction (core dumped)
make: *** [uncommon.mk:1129: encdb.h] Illegal instruction (core dumped)
!!! Compiling ruby 3.1.2 failed!
Actions
Like0
Like0