Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 09 Jan 2020 09:10:51 +0000
From:      bugzilla-noreply@freebsd.org
To:        powerpc@FreeBSD.org
Subject:   [Bug 243180] security/afl: fix build on powerpc64 elfv2
Message-ID:  <bug-243180-25139-IIKzOok862@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-243180-25139@https.bugs.freebsd.org/bugzilla/>
References:  <bug-243180-25139@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D243180

--- Comment #2 from Piotr Kubaj <pkubaj@FreeBSD.org> ---
(In reply to Tobias Kortkamp from comment #1)
I don't have aarch64 to test on, so I'll leave it up to you :)

afl needs -mabi=3Delfv2 because it uses LLVM 8. LLVM 9 has patches that for=
 elfv2
that are autoapplied when building on elfv2, so that it doesn't use elfv1.

This is done with:
OPTIONS_DEFAULT_powerpc64=3D      ${PPC_ABI:tu:MELFV2} OPENMP
ELFV2_EXTRA_PATCHES=3D    ${PATCHDIR}/ppc64-elfv2
at https://svnweb.freebsd.org/ports/head/devel/llvm90/Makefile?view=3Dmarkup
The extra patches are simply
https://svnweb.freebsd.org/ports/head/devel/llvm90/files/ppc64-elfv2/patch-=
lib_Target_PowerPC_PPCTargetMachine.cpp?view=3Dmarkup
and
https://svnweb.freebsd.org/ports/head/devel/llvm90/files/ppc64-elfv2/patch-=
tools_clang_lib_Basic_Targets_PPC.h?view=3Dmarkup

They just set up clang to build for elfv2. It can be done without those pat=
ches
by passing -mabi=3Delfv2.

LLVM 8 doesn't have those patches but can still build for elfv2 after passi=
ng
-mabi=3Delfv2.

If afl++ is the superior alternative to this port (with only pros and no co=
ns),
then I guess it's fine not to fix it, but then why keep this port in the tr=
ee?
:)

--=20
You are receiving this mail because:
You are on the CC list for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-243180-25139-IIKzOok862>