blob: b4f649d0b4a49df536268049d97b6e771179a60b (
plain)
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
|
$NetBSD: patch-aa,v 1.2 2009/07/08 14:28:29 joerg Exp $
--- makefile.orig 2004-09-21 23:33:40.000000000 +0200
+++ makefile
@@ -15,8 +15,8 @@ VERSION = 2.3pl1
# for the rest of the world, it is probably better to put the binaries
# in /usr/local/netperf or /opt/netperf
#
-#NETPERF_HOME = /usr/local/netperf
-NETPERF_HOME = /opt/netperf
+NETPERF_HOME = ${PREFIX}/netperf
+#NETPERF_HOME = /opt/netperf
# The compiler on your system might be somewhere else, and/or have
# a different name.
@@ -113,7 +113,8 @@ CC = cc
# netserver via the netperf command line with -T
LOG_FILE=DEBUG_LOG_FILE="\"/tmp/netperf.debug\""
-CFLAGS = -O -D$(LOG_FILE) -DNEED_MAKEFILE_EDIT
+CFLAGS = -O -D$(LOG_FILE)
+CFLAGS+=-fno-strength-reduce -DUSE_LOOPER -DHISTOGRAM -DDO_UNIX -DDO_IPV6
# Some platforms, and some options, require additional libraries.
# you can add to the "LIBS =" line to accomplish this. if you find
@@ -216,19 +217,12 @@ nettest_dns.o: nettest_dns.c nettest_dn
netserver.o: netserver.c nettest_bsd.h netlib.h makefile
install: netperf netserver
- mkdir -p $(NETPERF_HOME)
+ mkdir -p ${DESTDIR}$(NETPERF_HOME)
chmod -w *.[ch]
- chmod +x $(NETPERF_SCRIPTS)
- @if [ ! -d $(NETPERF_HOME) ]; then \
- mkdir $(NETPERF_HOME) && chmod a+rx $(NETPERF_HOME); \
- fi
- cp netperf $(NETPERF_HOME)
- cp netserver $(NETPERF_HOME)
- cp $(NETPERF_SCRIPTS) $(NETPERF_HOME)
- chmod a+rx $(NETPERF_HOME)/netperf $(NETPERF_HOME)/netserver
- @for i in $(NETPERF_SCRIPTS); do \
- chmod a+rx $(NETPERF_HOME)/$$i; \
- done
+ ${BSD_INSTALL_PROGRAM} netperf ${DESTDIR}$(NETPERF_HOME)
+ ${BSD_INSTALL_PROGRAM} netserver ${DESTDIR}$(NETPERF_HOME)
+ ${BSD_INSTALL_SCRIPT} $(NETPERF_SCRIPTS) ${DESTDIR}$(NETPERF_HOME)
+
clean:
rm -f *.o netperf netserver core
|