Skip to content

Commit

Permalink
chroot-fixups: prevent %install of llvm from taking ages to complete
Browse files Browse the repository at this point in the history
The `brp-llvm-compile-lto-elf` script does not work well in our scanning
environment and causes the %install section of `llvm-16.0.6-4.el9` to
take 7 days to complete.

Depends-on: csutils#179
Closes: https://github.com/kdudka/csmock/pull/new/chroot-fixup-llvm
  • Loading branch information
kdudka committed Jul 16, 2024
1 parent e9f8060 commit b3a2279
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions scripts/chroot-fixups/rpm-build-scripts.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
#!/bin/sh
#!/bin/bash

script="/usr/lib/rpm/redhat/brp-mangle-shebangs"
if [ -x $script ]; then
(set -x; sed -e 's/fail=1/fail=0/' -i $script )
fi

script="/usr/lib/rpm/brp-strip-static-archive"
if [ -f $script ]; then
ln -sfvT /bin/true $script
fi
# skip RPM scripts running in %install that are not needed and break scans
for script in /usr/lib/rpm/{redhat/brp-llvm-compile-lto-elf,brp-strip-static-archive}; do
if [ -f "$script" ]; then
ln -fsvT /bin/true "$script"
fi
done

0 comments on commit b3a2279

Please sign in to comment.