aboutsummaryrefslogtreecommitdiff
path: root/benchmarks/nttcp/files/Makefile
blob: 4b727c8ac528d541c9663a36a960cd8194a1488f (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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
# This code was written and is copyrighted 1996,1998 by
#
#       Elmar Bartel
#       Institut fuer Informatik
#       Technische Universitaet Muenchen
#       bartel@informatik.tu-muenchen.de
#
# Permission to use, copy, modify and distribute this software
# and its documentation for any purpose, except making money, is
# herby granted, provided that the above copyright notice and
# this permission appears in all places, where this code is
# referenced or used literally.

# uncomment the settings for your system and type make.
# if there is no setting available, simply try to use
# the most closest settings. 
# Finally let me know what you used, to get it running.


## For System V4.1 (AT&T) either cc or gcc
## And for SINIX V4.1 (either mips or intel).
#ARCH=
#LIB=	-lsocket -lnsl
#CC=	cc
#OPT=	-O
#DBG=	-g
#INC=	

## For DEC (Mips)ULTRIX 4.1
#ARCH=	-Dultrix
#LIB=
#CC=	gcc
#OPT=	-O2
#DBG=	
#INC=	

## For HPUX 9.* with gcc
#ARCH=	-Dhpux9
#LIB=
#CC=	gcc
#OPT=	-O2
#DBG=	-g
#INC=	

## For HPUX 9.* with cc
#ARCH=	-Ae -Dhpux9
#LIB=
#CC=	cc
#OPT=	-O
#DBG=	-g
#INC=	


## For HPUX 10.* with gcc
#ARCH=	-Dhpux
#LIB=
#CC=	gcc
#OPT=	-O2
#DBG=	-g
#INC=	

## For HPUX 10.* with cc
#ARCH=	-Ae -Dhpux
#LIB=
#CC=	cc
#OPT=	-O
#DBG=	-g
#INC=	

## For SunOS 4.1 with clcc
#ARCH=-DSunOS4
#LIB=	
#OPT=	-O2
#CC=	clcc
#DBG=	
#INC=	

## For SunOS 4.1 with gcc
#ARCH=-DSunOS4
#LIB=	
#OPT=	-O2
#CC=	gcc
#DBG=	
#INC=	

## For SunOS 5.3 with gcc
#ARCH=-DSunOS53
#LIB=	-lsocket -lnsl -lucb
#OPT=	-O2
#CC=	gcc
#DBG=	
#INC=	

## For SunOS 5.[456] with cc from SunSoft
#ARCH=-DSunOS54
#LIB=	-lsocket -lnsl
#OPT=	-O
#CC=	/usr/ccs/bin/cc
#CC=	/opt/SUNWspro/bin/cc
#DBG=	-g
#INC=	

## For SunOS 5.[456] with gcc
#ARCH=-DSunOS54
#LIB=	-lsocket -lnsl
#OPT=	-O2
#CC=	gcc
#DBG=	-Wall -g
#INC=	

## For FreeBSD
ARCH=	-DFreeBSD
LIB=
OPT=	-O2
CC=	cc
DBG=	
INC=	

## For SGI IRIX 5.3, 6.2 (cc or gcc)
#ARCH=
#LIB=
#OPT=	-O
#CC=	cc
#DBG=	
#INC=	

## For IBM AIX 2.3
#ARCH=	-Daix
#LIB=
#OPT=	-O
#CC=	cc
#DBG=	
#INC=	

## For OSF/1 10.41
#ARCH=	
#LIB=
#OPT=	-O -Olimit 700
#CC=	cc
#DBG=	
#INC=	

## For Linux with gcc
#ARCH=
#LIB=	
#OPT=	-O2
#CC=	gcc
#DBG=	
#INC=	

VERSION=	1.4
prefix=		/usr/local/dist/DIR/nttcp-$(VERSION)
#prefix=		/usr/local
#CFLAGS =	$(ARCH) $(DBG) $(DEF) $(INC) $(OPT) -DVERSION=\"$(VERSION)\"
CFLAGS =	$(ARCH) $(CFLG) -DVERSION=\"$(VERSION)\"
LFLAGS = 	$(DBG) 

nttcp:		nttcp.o support.o
		$(CC) $(LFLAGS) nttcp.o -o nttcp support.o $(LIB)

support.o:	support.c support.h

dist:
		if [ -d nttcp-$(VERSION) ]; then \
		    rm -f nttcp-$(VERSION)/*; \
		else \
		    mkdir nttcp-$(VERSION); \
		fi
		ln nttcp.c nttcp.1 support.c support.h \
		   README Makefile nttcp-$(VERSION)
		tar cvf - nttcp-$(VERSION) | gzip > /tmp/nttcp-$(VERSION).tar.gz; \
		zip -lgr /tmp/nttcp`echo $(VERSION)|tr -d .`.zip nttcp-$(VERSION)

install:	nttcp
		-mkdir -p $(prefix)/bin
		-mkdir -p $(prefix)/man/man1
		cp nttcp $(prefix)/bin
		cp nttcp.1 $(prefix)/man/man1

clean:
		rm -f *.o

clobber:	clean
		rm -rf core nttcp nttcp-$(VERSION)