File: fix-linking.patch

package info (click to toggle)
blobandconquer 1.11-dfsg%2B20-1.3
  • links: PTS
  • area: main
  • in suites: bullseye
  • size: 89,660 kB
  • sloc: cpp: 39,032; ansic: 362; makefile: 142
file content (25 lines) | stat: -rw-r--r-- 866 bytes parent folder | download | duplicates (3)
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
Description: Fix the link commands
 With ld --as-needed, order of arguments is actually important, libs should
 always come after objects. Also honor $LDFLAGS.
Author: Andreas Moog <amoog@ubuntu.com>
Author: Andrey Rahmatullin <wrar@debian.org>
Bug: http://sourceforge.net/support/tracker.php?aid=3325206
Bug-Ubuntu: https://bugs.launchpad.net/bugs/765986

Index: blobandconquer-1.11-dfsg+20/makefile
===================================================================
--- blobandconquer-1.11-dfsg+20.orig/makefile
+++ blobandconquer-1.11-dfsg+20/makefile
@@ -101,10 +101,10 @@ all: $(ALL)
 
 # linking the program.
 $(PROG): $(GAMEOBJS)
-	$(CXX) $(LIBS) $(GAMEOBJS) -o $(PROG)
+	$(CXX) $(LDFLAGS) $(GAMEOBJS) -o $(PROG) $(LIBS)
 	
 pak: $(PAKOBJS)
-	$(CXX) $(LIBS) $(PAKOBJS) -o pak
+	$(CXX) $(LDFLAGS) $(PAKOBJS) -o pak $(LIBS)
 	
 %.mo: %.po
 	msgfmt -c -o $@ $<