]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/blame - src/patches/libpcap-0.8.3-shared.patch
Wir kehren zurueck zu Kudzu, da hwinfo noch mehr Aerger macht.
[people/teissler/ipfire-2.x.git] / src / patches / libpcap-0.8.3-shared.patch
CommitLineData
cd1a2927
MT
1diff -ruN libpcap-0.8.3.old/Makefile.in libpcap-0.8.3/Makefile.in
2--- libpcap-0.8.3.old/Makefile.in 2001-01-18 05:05:12.000000000 +0100
3+++ libpcap-0.8.3/Makefile.in 2004-01-25 14:40:47.000000000 +0100
4@@ -22,6 +22,10 @@
5 #
6 # Various configurable paths (remember to edit Makefile.in, not Makefile)
7 #
8+MAJOR=0
9+MINOR=8
10+SUBMINOR=3
11+VERSION = $(MAJOR).$(MINOR).$(SUBMINOR)
12
13 # Top level hierarchy
14 prefix = @prefix@
15@@ -47,7 +51,7 @@
16 DEFS = @DEFS@
17
18 # Standard CFLAGS
19-CFLAGS = $(CCOPT) $(INCLS) $(DEFS)
20+CFLAGS = $(CCOPT) $(INCLS) $(DEFS) -fPIC -DPIC
21
22 INSTALL = @INSTALL@
23 INSTALL_PROGRAM = @INSTALL_PROGRAM@
24@@ -91,9 +95,14 @@
25 TAGFILES = \
26 $(SRC) $(HDR) $(TAGHDR)
27
28-CLEANFILES = $(OBJ) libpcap.a $(GENSRC) $(GENHDR) lex.yy.c
29
30-all: libpcap.a
31+
32+CLEANFILES = $(OBJ) libpcap.a $(GENSRC) $(GENHDR) lex.yy.c libpcap.so.$(VERSION)
33+
34+all: libpcap.a libpcap.so.$(VERSION)
35+
36+libpcap.so.$(VERSION):
37+ gcc -shared -Wl,-soname -Wl,libpcap.so.$(VERSION) -o libpcap.so.$(VERSION) $(OBJ) -lc
38
39 libpcap.a: $(OBJ)
40 @rm -f $@
41@@ -139,6 +148,10 @@
42 [ -d $(DESTDIR)$(libdir) ] || \
43 (mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
44 $(INSTALL_DATA) libpcap.a $(DESTDIR)$(libdir)/libpcap.a
45+ $(INSTALL_DATA) libpcap.so.$(VERSION) $(DESTDIR)$(libdir)/libpcap.so.$(VERSION)
46+ ln -sf libpcap.so.$(VERSION) $(DESTDIR)$(libdir)/libpcap.so
47+ ln -sf libpcap.so.$(VERSION) $(DESTDIR)$(libdir)/libpcap.so.$(MAJOR)
48+ ln -sf libpcap.so.$(VERSION) $(DESTDIR)$(libdir)/libpcap.so.$(MAJOR).$(MINOR)
49 $(RANLIB) $(DESTDIR)$(libdir)/libpcap.a
50 [ -d $(DESTDIR)$(includedir) ] || \
51 (mkdir -p $(DESTDIR)$(includedir); chmod 755 $(DESTDIR)$(includedir))