summaryrefslogtreecommitdiff
path: root/security/rhash/files/patch-Makefile
blob: 54ec56fab093e1ee78d5dfec0f0142b9a3ae93bc (plain) (blame)
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
--- Makefile.orig	2016-11-05 23:22:07 UTC
+++ Makefile
@@ -6,9 +6,9 @@ VERSION = 1.3.4
 PREFIX  ?= /usr/local
 CC      ?= gcc
 # using OPTFLAGS/OPTLDFLAGS for compatibilty with old scripts using this makefile
-OPTFLAGS = -O2 -DNDEBUG -fomit-frame-pointer -ffunction-sections -fdata-sections
+OPTFLAGS = -DNDEBUG -fomit-frame-pointer -ffunction-sections -fdata-sections
 OPTLDFLAGS =
-CFLAGS = $(OPTFLAGS)
+CFLAGS += $(OPTFLAGS)
 LDFLAGS = $(OPTLDFLAGS)
 ADDCFLAGS =
 ADDLDFLAGS =
@@ -71,7 +71,7 @@ lib-shared: $(SHAREDLIB)
 lib-static: $(LIBRHASH)
 
 install: all install-binary install-data install-symlinks
-install-shared: $(SHARED_TRG) install-shared-binary install-data install-symlinks
+install-shared: $(SHARED_TRG) install-shared-binary install-lib-static install-lib-shared install-data install-symlinks
 install-data: install-man install-conf
 uninstall: uninstall-binary uninstall-data uninstall-symlinks
 
@@ -106,7 +106,7 @@ install-man:
 
 install-conf:
 	$(INSTALL) -d $(DESTDIR)/etc
-	tr -d \\r < dist/rhashrc.sample > rc.tmp && $(INSTALL_DATA) rc.tmp $(DESTDIR)/etc/rhashrc
+	tr -d \\r < dist/rhashrc.sample > rc.tmp && $(INSTALL_DATA) rc.tmp $(DESTDIR)$(PREFIX)/etc/rhashrc.sample
 	rm -f rc.tmp
 
 # dependencies should be properly set, otherwise 'make -j<n>' can fail
@@ -127,7 +127,7 @@ install-lib-static: $(LIBRHASH)
 	+make -C librhash install-lib-static
 
 install-lib-shared: $(SHAREDLIB)
-	+make -C librhash install-lib-shared
+	+make -C librhash install-lib-shared install-so-link
 
 $(SHAREDLIB):
 	+make -C librhash lib-shared