File: pass-down-cflags.patch

package info (click to toggle)
sparse 0.5.0-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 1,936 kB
  • ctags: 3,948
  • sloc: ansic: 27,901; perl: 248; sh: 233; makefile: 166
file content (15 lines) | stat: -rw-r--r-- 419 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
From: Loïc Minier <lool@debian.org>
Subject: Pass down CPPFLAGS and CFLAGS from rules as to use dpkg-buildflags, hardening flags in particular

--- a/Makefile
+++ b/Makefile
@@ -12,7 +12,8 @@
 
 
 CC = gcc
-CFLAGS = -O2 -finline-functions -fno-strict-aliasing -g
+CFLAGS += $(CPPFLAGS)
+CFLAGS += -O2 -finline-functions -fno-strict-aliasing -g
 CFLAGS += -Wall -Wwrite-strings
 LDFLAGS += -g -Wl,--as-needed
 LD = gcc