Source: rustc
Version: 1.6.0+dfsg1-1
Severity: serious
Justification: fails to build from source

Builds of rustc have been failing with errors along the lines of

  gcc -I/«BUILDDIR»/rustc-1.6.0+dfsg1/src/compiler-rt/lib 
-I/«BUILDDIR»/rustc-1.6.0+dfsg1/src/compiler-rt/include -Wall -g -fPIC -m32 -g 
-O2 -fstack-protector-strong -Wformat =format-security -std=c99 -c -o 
/«BUILDDIR»/rustc-1.6.0+dfsg1/i686-unknown-linux-gnu/rt/compiler-rt/triple/builtins/i386/SubDir.lib__builtins/ashlti3.o
 /«BUILDDIR»/rustc-1.6.0+dfsg1/src/compiler-rt/lib/builtins/ashlti3.c
  gcc: error: =format-security: No such file or directory
  Makefile:267: recipe for target 
'/«BUILDDIR»/rustc-1.6.0+dfsg1/i686-unknown-linux-gnu/rt/compiler-rt/triple/builtins/i386/SubDir.lib__builtins/ashlti3.o'
 failed
  make[3]: *** 
[/«BUILDDIR»/rustc-1.6.0+dfsg1/i686-unknown-linux-gnu/rt/compiler-rt/triple/builtins/i386/SubDir.lib__builtins/ashlti3.o]
 Error 1
  make[3]: Leaving directory '/«BUILDDIR»/rustc-1.6.0+dfsg1/src/compiler-rt'
  /«BUILDDIR»/rustc-1.6.0+dfsg1/mk/rt.mk:364: recipe for target 
'i686-unknown-linux-gnu/rt/libcompiler-rt.a' failed
  make[2]: *** [i686-unknown-linux-gnu/rt/libcompiler-rt.a] Error 2

The issue appears to stem from logic in mk/rt.mk that tries to strip
-Werror from CFLAGS via $(subst ...), which is happy to replace partial
words, and as such interacts poorly with typical hardening flags.  I'd
suggest instead using $(filter-out ...).

Could you please take a look?

Thanks!

Reply via email to