File: use-implicit-rules.patch

package info (click to toggle)
mwrap 1.2.1-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 980 kB
  • sloc: cpp: 3,271; ansic: 856; makefile: 251; lex: 233; sh: 2
file content (57 lines) | stat: -rw-r--r-- 1,538 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
Description: Use implicit rules in Makefile and force use of LDFLAGS
Author: Rafael Laboissière <rafael@debian.org>
Forwarded: not-needed
Last-Update: 2020-08-04

--- mwrap-0.33.12.orig/src/Makefile
+++ mwrap-0.33.12/src/Makefile
@@ -5,48 +5,41 @@ include ../make.inc
 
 ../mwrap: mwrap.o lex.yy.o mwrap-ast.o mwrap-typecheck.o \
 	mwrap-mgen.o mwrap-cgen.o mwrap-ast.h
-	$(CXX) -o ../mwrap mwrap.o mwrap-ast.o \
+	$(CXX) $(LDFLAGS) -o ../mwrap mwrap.o mwrap-ast.o \
 		mwrap-typecheck.o mwrap-mgen.o mwrap-cgen.o \
 		lex.yy.o
 
 mwrap.o: mwrap.cc lex.yy.c mwrap-ast.h
-	$(CXX) -c mwrap.cc
 
 mwrap.cc mwrap.hh: mwrap.y
 	$(BISON) -d -v mwrap.y -o mwrap.cc
 
 ifeq ($(shell bison --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\).*$$/\1/p'), 3)
 ERROR_VERBOSE = %define parse.error verbose
 else
 ERROR_VERBOSE = %error-verbose
 endif
 
 mwrap.y: mwrap.y.in
 	sed -e 's/@ERROR_VERBOSE@/$(ERROR_VERBOSE)/' < mwrap.y.in > mwrap.y
 
 lex.yy.o: lex.yy.c mwrap.hh
-	$(CC) -c lex.yy.c
 
 lex.yy.c: mwrap.l
 	$(FLEX) mwrap.l
 
 mwrap-ast.o: mwrap-ast.cc mwrap-ast.h 
-	$(CXX) -c -g mwrap-ast.cc
 
 mwrap-typecheck.o: mwrap-typecheck.cc mwrap-ast.h
-	$(CXX) -c -g mwrap-typecheck.cc
 
 mwrap-cgen.o: mwrap-cgen.cc mwrap-ast.h mwrap-support.h
-	$(CXX) -c -g mwrap-cgen.cc
 
 mwrap-mgen.o: mwrap-mgen.cc mwrap-ast.h
-	$(CXX) -c -g mwrap-mgen.cc
 
 mwrap-support.h: mwrap-support.c stringify
 	./stringify mex_header < mwrap-support.c > mwrap-support.h
 
 stringify: stringify.c
-	$(CC) -o stringify stringify.c
 
 
 # === Clean-up targets ===