]>
Commit | Line | Data |
---|---|---|
1 | --- arpd-1.0.2.orig/Makefile | |
2 | +++ arpd-1.0.2/Makefile | |
3 | @@ -3,16 +3,19 @@ | |
4 | VERSION = 1.0.2 | |
5 | KERNELVERSION = linux-2.0.0 | |
6 | ||
7 | -# DEBUG = -DDEBUG | |
8 | - | |
9 | CC = gcc | |
10 | -CFLAGS = -m486 -O6 -pipe -fomit-frame-pointer -Wall \ | |
11 | - -DARPD_VERSION=\"$(VERSION)\" $(DEBUG) | |
12 | +CFLAGS = -m486 -O3 -pipe -fomit-frame-pointer -Wall | |
13 | +CDEFS = -DARPD_VERSION=\"$(VERSION)\" -DNDEBUG | |
14 | ||
15 | all: arpd | |
16 | ||
17 | +arpd: arpd.o | |
18 | + | |
19 | +.c.o: | |
20 | + $(CC) $(CPPFLAGS) $(CFLAGS) $(CDEFS) -c $< -o $@ | |
21 | + | |
22 | clean: | |
23 | - rm -f arpd | |
24 | + rm -f arpd *.o core | |
25 | ||
26 | package: clean | |
27 | -(cd /usr/src; \ | |
28 | --- arpd-1.0.2.orig/arpd.c | |
29 | +++ arpd-1.0.2/arpd.c | |
30 | @@ -14,6 +14,9 @@ | |
31 | #include <syslog.h> | |
32 | #include <fcntl.h> | |
33 | #include <string.h> | |
34 | +#include <limits.h> | |
35 | +#include <sys/types.h> | |
36 | +#include <errno.h> | |
37 | #include <net/if_arp.h> | |
38 | #include <sys/socket.h> | |
39 | #include <netinet/in.h> | |
40 | @@ -41,7 +44,7 @@ | |
41 | void arpd_walk_procfs(struct arpd_request *, void *); | |
42 | void arpd_walk_flush(struct arpd_request *, void *); | |
43 | void arpd_walk (void (*fn)(struct arpd_request *, void *), void *); | |
44 | -static struct arpd_request * arpd_find (unsigned long, __u32, | |
45 | +static struct arpd_request * arpd_find (unsigned long, u_int32_t, | |
46 | struct arpd_request *); | |
47 | ||
48 | int main(int argc, char **argv) | |
49 | @@ -147,7 +150,7 @@ | |
50 | ||
51 | /* if newent == NULL, we are doing a lookup, else its an update */ | |
52 | ||
53 | -static struct arpd_request * arpd_find (unsigned long dev, __u32 ip, | |
54 | +static struct arpd_request * arpd_find (unsigned long dev, u_int32_t ip, | |
55 | struct arpd_request * newent) | |
56 | { | |
57 | int depth, i; | |
58 | @@ -264,7 +267,7 @@ | |
59 | struct in_addr inaddr; | |
60 | ||
61 | inaddr.s_addr = request->ip; | |
62 | - fprintf(stderr, "Tbl: %s (%08lx)\n", | |
63 | + fprintf(stderr, "Tbl: %s (%08x)\n", | |
64 | inet_ntoa(inaddr), ntohl(request->ip)); | |
65 | return; | |
66 | } | |
67 | --- arpd-1.0.2.orig/debian/README.debian | |
68 | +++ arpd-1.0.2/debian/README.debian | |
69 | @@ -0,0 +1,6 @@ | |
70 | +arpd for DEBIAN | |
71 | +---------------------- | |
72 | + | |
73 | +So far nothing to say. | |
74 | + | |
75 | +Dominik Kubla <kubla@netz.klinik.uni-mainz.de>, Sun, 24 Nov 1996 20:32:09 +0100 | |
76 | --- arpd-1.0.2.orig/debian/changelog | |
77 | +++ arpd-1.0.2/debian/changelog | |
78 | @@ -0,0 +1,52 @@ | |
79 | +arpd (1.0.2-7) unstable; urgency=high | |
80 | + | |
81 | + * temporary release to use mknod instead of MAKEDEV - fixes #38398 | |
82 | + | |
83 | + -- Elie Rosenblum <fnord@debian.org> Thu, 27 May 1999 16:27:55 -0500 | |
84 | + | |
85 | +arpd (1.0.2-6) frozen; urgency=low | |
86 | + | |
87 | + * brought up to new standards compliance | |
88 | + | |
89 | + -- Elie Rosenblum <fnord@debian.org> Sun, 15 Mar 1998 13:08:42 -0500 | |
90 | + | |
91 | +arpd (1.0.2-5) unstable; urgency=low | |
92 | + | |
93 | + * Fixed FSF address in copyright file. | |
94 | + * Linked 'undocumented' manpage. Fixes bug without a tracking # yet | |
95 | + * added force-reload / force-restart methods to init.d script | |
96 | + * Fixed Bug#19269 (md5sums) | |
97 | + | |
98 | + -- Elie Rosenblum <fnord@debian.org> Sat, 14 Mar 1998 10:43:45 -0500 | |
99 | + | |
100 | +arpd (1.0.2-4) unstable; urgency=low | |
101 | + | |
102 | + * Fixed policy in postinst by getting arpd added to makedev | |
103 | + * Changed init.d script to comply with policy | |
104 | + | |
105 | + -- Elie Rosenblum <fnord@debian.org> Tue, 13 Jan 1998 18:17:38 -0500 | |
106 | + | |
107 | +arpd (1.0.2-3) unstable; urgency=low | |
108 | + | |
109 | + * Fixed init.d script | |
110 | + * Brought up to libc6 | |
111 | + * Changed postinst script to comply with policy | |
112 | + | |
113 | + -- Elie Rosenblum <fnord@debian.org> Tue, 16 Dec 1997 12:10:36 -0500 | |
114 | + | |
115 | +arpd (1.0.2-2) experimental; urgency=low | |
116 | + | |
117 | + * Created postinst script. | |
118 | + * Public release. | |
119 | + | |
120 | + -- Dominik Kubla <dominik@debian.org> Tue, 4 Feb 1997 17:44:03 +0100 | |
121 | + | |
122 | +arpd (1.0.2-1) experimental; urgency=low | |
123 | + | |
124 | + * Internal Release. | |
125 | + | |
126 | + -- Dominik Kubla <kubla@Uni-Mainz.DE> Sun, 24 Nov 1996 20:32:09 +0100 | |
127 | + | |
128 | +Local variables: | |
129 | +mode: debian-changelog | |
130 | +End: | |
131 | --- arpd-1.0.2.orig/debian/init.d | |
132 | +++ arpd-1.0.2/debian/init.d | |
133 | @@ -0,0 +1,61 @@ | |
134 | +#!/bin/sh | |
135 | +# | |
136 | +# This file was automatically customized by debmake on Sun, 24 Nov 1996 20:32:09 +0100 | |
137 | +# | |
138 | +# Written by Miquel van Smoorenburg <miquels@drinkel.ow.org>. | |
139 | +# Modified for Debian GNU/Linux by Ian Murdock <imurdock@gnu.ai.mit.edu>. | |
140 | +# Modified for Debian by Christoph Lameter <clameter@debian.org> | |
141 | + | |
142 | +PATH=/bin:/usr/bin:/sbin:/usr/sbin | |
143 | +DAEMON=/usr/sbin/arpd | |
144 | +# The following value is extracted by debstd to figure out how to generate | |
145 | +# the postinst script. Edit the field to change the way the script is | |
146 | +# registered through update-rc.d (see the manpage for update-rc.d!) | |
147 | +FLAGS="defaults 20" | |
148 | + | |
149 | +test -f $DAEMON || exit 0 | |
150 | + | |
151 | +usage () { | |
152 | + echo "Usage: $0 {start|stop|reload|force-reload|force-restart}" 1>&2 | |
153 | + exit 1 | |
154 | +} | |
155 | + | |
156 | +dorun () { | |
157 | + case "$1" in | |
158 | + start) | |
159 | + if [ -c /dev/arpd ]; then | |
160 | + echo -n "Starting user-space ARP daemon: arpd" | |
161 | + start-stop-daemon --start --verbose --quiet --exec $DAEMON | |
162 | + echo "." | |
163 | + else | |
164 | + echo "Not starting ARP daemon without /dev/arpd." | |
165 | + fi | |
166 | + ;; | |
167 | + stop) | |
168 | + echo -n "Stopping user-space ARP daemon: arpd" | |
169 | + start-stop-daemon --quiet --stop --verbose --exec $DAEMON | |
170 | + echo "." | |
171 | + ;; | |
172 | + restart) | |
173 | + dorun force-restart | |
174 | + ;; | |
175 | + force-reload) | |
176 | + dorun force-restart | |
177 | + ;; | |
178 | + force-restart) | |
179 | + dorun stop | |
180 | + dorun start | |
181 | + ;; | |
182 | + *) | |
183 | + usage | |
184 | + ;; | |
185 | + esac | |
186 | +} | |
187 | + | |
188 | +if [ "$#" -eq "1" ]; then | |
189 | + dorun "$1" | |
190 | +else | |
191 | + usage | |
192 | +fi | |
193 | + | |
194 | +exit 0 | |
195 | --- arpd-1.0.2.orig/debian/control | |
196 | +++ arpd-1.0.2/debian/control | |
197 | @@ -0,0 +1,16 @@ | |
198 | +Source: arpd | |
199 | +Section: net | |
200 | +Priority: extra | |
201 | +Maintainer: Elie Rosenblum <fnord@debian.org> | |
202 | +Standards-Version: 2.4.0.0 | |
203 | + | |
204 | +Package: arpd | |
205 | +Architecture: any | |
206 | +Depends: ${shlibs:Depends}, makedev (>=1.6-29) | |
207 | +Description: A user-space ARP daemon | |
208 | + The ARP daemon moves the management of the ARP (Address Resolution | |
209 | + Protocol) table from kernel to user space. It is useful for sites | |
210 | + with LARGE network segments (256+ systems per segment), because the | |
211 | + kernel hash tables are not optimized to handle this situation. To use | |
212 | + the ARP daemon your kernel needs to have ARPD and NETLINK support | |
213 | + enabled. The standard kernels of Debian GNU/Linux lack this support. | |
214 | --- arpd-1.0.2.orig/debian/copyright | |
215 | +++ arpd-1.0.2/debian/copyright | |
216 | @@ -0,0 +1,30 @@ | |
217 | +This package was debianized by Dominik Kubla kubla@netz.klinik.uni-mainz.de on | |
218 | +Sun, 24 Nov 1996 20:32:09 +0100. | |
219 | + | |
220 | +It was downloaded from http://www.loran.com/~layes/arpd/arpd-1.0.2.tar.gz | |
221 | + | |
222 | +Copyright: | |
223 | + | |
224 | +(So as not to confuse RMS or anyone else, arpd is not a derivative nor | |
225 | +is it a part of the GNU project. I include the GPL here only because it | |
226 | +mostly applies and I'm too lazy to write my own legalese. Although you | |
227 | +will see 'gcc' in the Makefile, feel free to use any compiler you wish | |
228 | +if it makes you happy.) | |
229 | + | |
230 | +This program is free software; you can redistribute it and/or modify it | |
231 | +under the terms of the GNU General Public License as published by the | |
232 | +Free Software Foundation; either version 2, or (at your option) any | |
233 | +later version. | |
234 | + | |
235 | +This program is distributed in the hope that it will be useful, | |
236 | +but WITHOUT ANY WARRANTY; without even the implied warranty of | |
237 | +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
238 | +GNU General Public License for more details. | |
239 | + | |
240 | +You should have received a copy of the GNU General Public License | |
241 | +along with this program; if not, write to the Free Software | |
242 | +Foundation, 59 Temple Place - Suite 330, | |
243 | +Boston, MA 02111-1307, USA. | |
244 | + | |
245 | +On Debian GNU/Linux systems, the complete text of the GNU General | |
246 | +Public License can be found in `/usr/doc/copyright/GPL'. | |
247 | --- arpd-1.0.2.orig/debian/rules | |
248 | +++ arpd-1.0.2/debian/rules | |
249 | @@ -0,0 +1,60 @@ | |
250 | +#!/usr/bin/make -f | |
251 | +# Sample debian.rules file - for GNU Hello (1.3). | |
252 | +# Copyright 1994,1995 by Ian Jackson. | |
253 | +# I hereby give you perpetual unlimited permission to copy, | |
254 | +# modify and relicense this file, provided that you do not remove | |
255 | +# my name from the file itself. (I assert my moral right of | |
256 | +# paternity under the Copyright, Designs and Patents Act 1988.) | |
257 | +# This file may have to be extensively modified | |
258 | +# | |
259 | +# Modified to be a prototype for debmake by Christoph Lameter <clameter@debian.org> | |
260 | + | |
261 | +package=arpd | |
262 | + | |
263 | +build: | |
264 | + $(checkdir) | |
265 | + make CFLAGS="-g -O2 -Wall" | |
266 | + touch build | |
267 | + | |
268 | +clean: | |
269 | + $(checkdir) | |
270 | + -rm -f build | |
271 | + -make clean | |
272 | + -rm `find . -name "*~"` | |
273 | + -rm -rf debian/tmp debian/files* core | |
274 | + | |
275 | +binary-indep: checkroot build | |
276 | + $(checkdir) | |
277 | +# There are no architecture-independent files to be uploaded | |
278 | +# generated by this package. If there were any they would be | |
279 | +# made here. | |
280 | + | |
281 | +binary-arch: checkroot build | |
282 | + $(checkdir) | |
283 | + -rm -rf debian/tmp | |
284 | + install -d debian/tmp/usr/sbin | |
285 | + install -s -m 0755 arpd debian/tmp/usr/sbin | |
286 | + install -d debian/tmp/usr/man/man8 | |
287 | + ln -s ../man7/undocumented.7.gz debian/tmp/usr/man/man8/arpd.8.gz | |
288 | + debstd CHANGES README* | |
289 | + dpkg-gencontrol | |
290 | + chown -R root.root debian/tmp | |
291 | + chmod -R go=rX debian/tmp | |
292 | + dpkg --build debian/tmp .. | |
293 | + | |
294 | +define checkdir | |
295 | + test -f debian/rules | |
296 | +endef | |
297 | + | |
298 | +# Below here is fairly generic really | |
299 | + | |
300 | +binary: binary-indep binary-arch | |
301 | + | |
302 | +source diff: | |
303 | + @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false | |
304 | + | |
305 | +checkroot: | |
306 | + $(checkdir) | |
307 | + test root = "`whoami`" | |
308 | + | |
309 | +.PHONY: binary binary-arch binary-indep clean checkroot | |
310 | --- arpd-1.0.2.orig/debian/postinst | |
311 | +++ arpd-1.0.2/debian/postinst | |
312 | @@ -0,0 +1,34 @@ | |
313 | +#!/bin/sh | |
314 | + | |
315 | +makedevice() { | |
316 | +# arpd device added as of makedev 1.6-29 | |
317 | +# arpd no longer in makedev | |
318 | + rm -f /dev/arpd | |
319 | + mknod /dev/arpd c 36 8 || true | |
320 | + #( | |
321 | + #cd /dev | |
322 | + #./MAKEDEV -vc arpd | |
323 | + #) | |
324 | +} | |
325 | + | |
326 | +if [ ! -c /dev/arpd ] | |
327 | +then | |
328 | + cat<<__EOF | |
329 | + | |
330 | +To run arpd, you _must_ have the /dev/arpd character device with major | |
331 | +number 36 and minor 8. Your system does not have this device. If you say | |
332 | +no here, you will have to create the device by hand with MAKEDEV arpd. | |
333 | + | |
334 | +__EOF | |
335 | + echo -n "May I create /dev/arpd for you? [yn] " | |
336 | + read answer | |
337 | + echo | |
338 | + case "x$answer" in | |
339 | + x|xy|xY|xyes|xYes|xYES) | |
340 | + makedevice | |
341 | + ;; | |
342 | + *) | |
343 | + echo "Very well, not creating /dev/arpd." | |
344 | + ;; | |
345 | + esac | |
346 | +fi | |
347 | --- arpd-1.0.2.orig/debian/conffiles | |
348 | +++ arpd-1.0.2/debian/conffiles | |
349 | @@ -0,0 +1 @@ | |
350 | +/etc/init.d/arpd | |
351 | --- arpd-1.0.2.orig/debian/substvars | |
352 | +++ arpd-1.0.2/debian/substvars | |
353 | @@ -0,0 +1 @@ | |
354 | +shlibs:Depends=libc6 |