[Reproducible-builds] Bug#828178: afl: FTBFS: clang error unknown argument -fdebug-prefix-map=/build/afl-2.16b=.'

Daniel Kahn Gillmor dkg at fifthhorseman.net
Mon Jun 27 20:58:44 UTC 2016


Hi Daniel--

On Sat 2016-06-25 16:09:08 -0400, Daniel Stender wrote:
> AFL fails to build from source in reproducible builds test build
> environments like this (log from 2.16b-1 build):
>
> <cut>
> lang-3.7 -g -O2 -fdebug-prefix-map=/build/afl-2.16b=. -fPIE -fstack-protector-strong -Wformat -Werror=format-security -Wall -D_FORTIFY_SOURCE=2 -g -Wno-pointer-sign -DAFL_PATH=\"/usr/lib/afl\" -DBIN_PATH=\"/usr/bin\" -DVERSION=\"2.16b\"  afl-clang-fast.c -o ../afl-clang-fast -fPIE -pie -Wl,-z,relro -Wl,-z,now
> clang: error: unknown argument: '-fdebug-prefix-map=/build/afl-2.16b=.'
> Makefile:79: recipe for target '../afl-clang-fast' failed
> </cut>

I think clang introduced -fdebug-prefix-map in 3.8.0 (see
https://bugs.debian.org/819185) and afl build-depends on clang-3.7.

I assume that it's the reproducible-builds toolchain that's adding the
-fdebug-prefix-map option to CFLAGS, right?  That's good -- it should
help avoid variations in the generated binaries due to build path alone,
so please keep it!  seems like the right fix here is either to build afl
against a newer version of clang, or to resolve #819185 by backporting
the option to clang-3.7.

> I'm going in it, soon.

I don't know what this means, sorry!

  --dkg



More information about the Reproducible-builds mailing list