Package: original-awk / 2012-12-20-6

03-cflags-and-cppflags-together.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
From: Santiago Vila <sanvila@debian.org>
Subject: Drop CFLAGS when linking. Add CPPFLAGS when compiling

--- a/makefile
+++ b/makefile
@@ -48,7 +48,7 @@
 	 awk.1
 
 a.out:	ytab.o $(OFILES)
-	$(CC) $(CFLAGS) ytab.o $(OFILES) $(ALLOC)  -lm
+	$(CC) ytab.o $(OFILES) $(ALLOC)  -lm
 
 $(OFILES):	awk.h ytab.h proto.h
 
@@ -56,7 +56,7 @@
 	$(YACC) $(YFLAGS) awkgram.y
 	mv y.tab.c ytab.c
 	mv y.tab.h ytab.h
-	$(CC) $(CFLAGS) -c ytab.c
+	$(CC) $(CPPFLAGS) $(CFLAGS) -c ytab.c
 
 proctab.c:	maketab
 	./maketab >proctab.c