blob: 093f74508196b4906d805adc9b71e61cd9818a98 (
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
|
--- Makefile.in.orig Mon Sep 25 11:06:00 2006
+++ Makefile.in Sun Jul 8 18:36:39 2007
@@ -98,22 +98,18 @@
CLEANFILES = $(OBJ) libpcap.a $(GENSRC) $(GENHDR) lex.yy.c
-all: libpcap.a
+all: libpcap.a libpcap.so.2
libpcap.a: $(OBJ)
@rm -f $@
ar rc $@ $(OBJ) $(LIBS)
$(RANLIB) $@
-shared: libpcap.$(DYEXT)
+#shared: libpcap.$(DYEXT)
-#
-# XXX - this works with GNU ld, but won't necessarily work with native
-# ld on, for example, various SVR4-flavored platforms, or Digital UNIX.
-#
-libpcap.so: $(OBJ)
+libpcap.so.2: $(OBJ)
@rm -f $@
- $(CC) -shared -o $@.`cat VERSION` $(OBJ) $(DAGLIBS)
+ $(CC) -shared -Wl,-x -o libpcap.so.2 -Wl,-soname,libpcap.so.2 `lorder *.o | tsort -q`
# the following rule succeeds, but the result is untested.
libpcap.dylib: $(OBJ)
@@ -174,6 +170,8 @@
install: libpcap.a
[ -d $(DESTDIR)$(libdir) ] || \
(mkdir -p $(DESTDIR)$(libdir); chmod 755 $(DESTDIR)$(libdir))
+ $(INSTALL_DATA) libpcap.so.2 $(DESTDIR)$(libdir)/libpcap.so.2
+ ln -fs $(DESTDIR)$(libdir)/libpcap.so.2 $(DESTDIR)$(libdir)/libpcap.so
$(INSTALL_DATA) libpcap.a $(DESTDIR)$(libdir)/libpcap.a
$(RANLIB) $(DESTDIR)$(libdir)/libpcap.a
[ -d $(DESTDIR)$(includedir) ] || \
|