File: 0001-fix-buildflags.patch

package info (click to toggle)
unrar-nonfree 1%3A6.2.6-1%2Bdeb12u1
  • links: PTS, VCS
  • area: non-free
  • in suites: bookworm
  • size: 1,976 kB
  • sloc: cpp: 28,439; makefile: 712; sh: 11
file content (43 lines) | stat: -rw-r--r-- 1,155 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
From: Nick Andrik <nick.andrik@gmail.com>
Date: Mon, 21 Jan 2013 23:07:40 +0100
Subject: unrar-nonfree: Doesn't export build flags

Forwarded: not-needed
Closes: 694611
Source: unrar-nonfree
Version: 1:4.1.4-1
Thanks: Felix Geyer <fgeyer@debian.org>

Added hardening support (Closes: #694611)
---
 makefile | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/makefile b/makefile
index 55af49b..c5ceb31 100644
--- a/makefile
+++ b/makefile
@@ -3,12 +3,12 @@
 
 # Linux using GCC
 CXX=c++
-CXXFLAGS=-O2 -Wno-logical-op-parentheses -Wno-switch -Wno-dangling-else
+CXXFLAGS=-Wno-logical-op-parentheses -Wno-switch -Wno-dangling-else
 LIBFLAGS=-fPIC
 DEFINES=-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DRAR_SMP
 STRIP=strip
 AR=ar
-LDFLAGS=-pthread
+LDFLAGS+=-pthread
 DESTDIR=/usr
 
 # Linux using LCC
@@ -160,7 +160,7 @@ lib:	WHAT=RARDLL
 lib:	CXXFLAGS+=$(LIBFLAGS)
 lib:	$(OBJECTS) $(LIB_OBJ)
 	@rm -f libunrar.*
-	$(LINK) -shared -o libunrar.so $(LDFLAGS) $(OBJECTS) $(LIB_OBJ)
+	$(LINK) -Wl,-soname,libunrar.so.5 -shared -o libunrar.so $(LDFLAGS) $(OBJECTS) $(LIB_OBJ)
 	$(AR) rcs libunrar.a $(OBJECTS) $(LIB_OBJ)
 
 install-unrar: