From 3fd6880c95aa8cd2320d4c97143d37ac4a7c1cf870b28638f86a1b8e176d274d Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Sun, 4 Apr 2021 08:47:30 +0000 Subject: [PATCH] Accepting request 882850 from home:haasn:branches:devel:tools - install `afl-clang-lto`, recommended by upstream as the best variant - add dependency on `lld` - bump llvm-devel up to >= 11.0.0 - fix /usr/bin/env path in afl.cmin scripts - prevent stripping of runtime objects (fix bug 1184324) OBS-URL: https://build.opensuse.org/request/show/882850 OBS-URL: https://build.opensuse.org/package/show/devel:tools/afl?expand=0&rev=134 --- afl.changes | 9 +++++++++ afl.spec | 13 ++++++++++--- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/afl.changes b/afl.changes index 90bd3d4..39a0fb1 100644 --- a/afl.changes +++ b/afl.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Sat Apr 3 23:31:18 UTC 2021 - Niklas Haas + +- install `afl-clang-lto`, recommended by upstream as the best variant + - add dependency on `lld` + - bump llvm-devel up to >= 11.0.0 +- fix /usr/bin/env path in afl.cmin scripts +- prevent stripping of runtime objects (fix bug 1184324) + ------------------------------------------------------------------- Mon Mar 29 12:29:54 UTC 2021 - Guillaume GARDET diff --git a/afl.spec b/afl.spec index 578fb4d..f964562 100644 --- a/afl.spec +++ b/afl.spec @@ -27,8 +27,10 @@ Source1: afl-rpmlintrc Patch1: afl-3.0c-fix-paths.patch BuildRequires: clang BuildRequires: gcc-c++ -BuildRequires: llvm-devel +BuildRequires: lld +BuildRequires: llvm-devel >= 11.0.0 BuildRequires: python3-devel +Requires: lld %description American fuzzy lop is a security-oriented fuzzer that employs a novel type @@ -48,14 +50,15 @@ use cases - say, common image parsing or file compression libraries. %prep %setup -q -n AFLplusplus-%version %patch1 -p1 -sed -i 's|#!/usr/bin/env bash|#!/bin/bash|g' afl-cmin +sed -i 's|#!/usr/bin/env sh|#!/bin/sh|g' afl-cmin +sed -i 's|#!/usr/bin/env bash|#!/bin/bash|g' afl-cmin.bash %build export CFLAGS="$CFLAGS %{optflags} -fno-lto" %ifnarch %{ix86} x86_64 export AFL_NO_X86=1 %endif -make %{?_smp_mflags} PREFIX=%{_prefix} LIBEXEC_DIR=%{_libexecdir} DOC_DIR=%{_docdir} +make %{?_smp_mflags} PREFIX=%{_prefix} LIBEXEC_DIR=%{_libexecdir} DOC_DIR=%{_docdir} # make radamsa %install @@ -63,6 +66,7 @@ make %{?_smp_mflags} PREFIX=%{_prefix} LIBEXEC_DIR=%{_libexecdir} DOC_DIR=%{_doc export AFL_NO_X86=1 %endif make %{?_smp_mflags} PREFIX=%{_prefix} LIBEXEC_DIR=%{_libexecdir} DOC_DIR=%{_docdir} MAN_PATH=%{_mandir}/man8 DESTDIR=%{buildroot} install +chmod -x %{buildroot}/%{_libexecdir}/%{name}/*.o %files %license docs/COPYING LICENSE @@ -74,13 +78,16 @@ make %{?_smp_mflags} PREFIX=%{_prefix} LIBEXEC_DIR=%{_libexecdir} DOC_DIR=%{_doc %ifarch x86_64 aarch64 ppc64 ppc64le s390x %{_libexecdir}/%{name}/afl-compiler-rt-64.o %{_libexecdir}/%{name}/afl-llvm-rt-64.o +%{_libexecdir}/%{name}/afl-llvm-rt-lto-64.o %endif %ifarch %ix86 %{arm} %{_libexecdir}/%{name}/afl-compiler-rt-32.o %{_libexecdir}/%{name}/afl-llvm-rt-32.o +%{_libexecdir}/%{name}/afl-llvm-rt-lto-32.o %endif %{_libexecdir}/%{name}/afl-compiler-rt.o %{_libexecdir}/%{name}/afl-llvm-rt.o +%{_libexecdir}/%{name}/afl-llvm-rt-lto.o %{_libexecdir}/%{name}/dynamic_list.txt %{_libexecdir}/%{name}/*.so %dir %{_datadir}/%{name}