summaryrefslogtreecommitdiffstats
path: root/meta/packages
diff options
context:
space:
mode:
Diffstat (limited to 'meta/packages')
-rw-r--r--meta/packages/libpcap/libpcap-1.0.0/aclocal.patch156
-rw-r--r--meta/packages/libpcap/libpcap-1.0.0/config-fixes.patch (renamed from meta/packages/libpcap/libpcap-0.9.3/config-fixes.patch)0
-rw-r--r--meta/packages/libpcap/libpcap-1.0.0/ieee80215-arphrd.patch22
-rw-r--r--meta/packages/libpcap/libpcap-1.0.0/ldflags.patch12
-rw-r--r--meta/packages/libpcap/libpcap-1.0.0/shared.patch (renamed from meta/packages/libpcap/libpcap-0.9.3/shared.patch)5
-rw-r--r--meta/packages/libpcap/libpcap.inc21
-rw-r--r--meta/packages/libpcap/libpcap_0.9.3.bb33
-rw-r--r--meta/packages/libpcap/libpcap_1.0.0.bb19
8 files changed, 231 insertions, 37 deletions
diff --git a/meta/packages/libpcap/libpcap-1.0.0/aclocal.patch b/meta/packages/libpcap/libpcap-1.0.0/aclocal.patch
new file mode 100644
index 0000000000..29cd275d58
--- /dev/null
+++ b/meta/packages/libpcap/libpcap-1.0.0/aclocal.patch
@@ -0,0 +1,156 @@
1diff -Naru libpcap-0.9.7.orig/aclocal.m4 libpcap-0.9.7/acinclude.m4
2--- libpcap-0.9.7.orig/aclocal.m4 2007-09-16 01:19:51.000000000 +0200
3+++ libpcap-0.9.7/aclocal.m4 2007-09-16 02:45:52.000000000 +0200
4@@ -42,7 +42,7 @@
5 dnl ac_cv_lbl_gcc_vers
6 dnl LBL_CFLAGS
7 dnl
8-AC_DEFUN(AC_LBL_C_INIT,
9+AC_DEFUN([AC_LBL_C_INIT],
10 [AC_PREREQ(2.12)
11 AC_BEFORE([$0], [AC_PROG_CC])
12 AC_BEFORE([$0], [AC_LBL_FIXINCLUDES])
13@@ -169,7 +169,7 @@
14 # Make sure we use the V_CCOPT flags, because some of those might
15 # disable inlining.
16 #
17-AC_DEFUN(AC_LBL_C_INLINE,
18+AC_DEFUN([AC_LBL_C_INLINE],
19 [AC_MSG_CHECKING(for inline)
20 save_CFLAGS="$CFLAGS"
21 CFLAGS="$V_CCOPT"
22@@ -225,7 +225,7 @@
23 dnl LIBS
24 dnl LBL_LIBS
25 dnl
26-AC_DEFUN(AC_LBL_LIBPCAP,
27+AC_DEFUN([AC_LBL_LIBPCAP],
28 [AC_REQUIRE([AC_LBL_LIBRARY_NET])
29 dnl
30 dnl save a copy before locating libpcap.a
31@@ -293,7 +293,7 @@
32 dnl RETSIGTYPE (defined)
33 dnl RETSIGVAL (defined)
34 dnl
35-AC_DEFUN(AC_LBL_TYPE_SIGNAL,
36+AC_DEFUN([AC_LBL_TYPE_SIGNAL],
37 [AC_BEFORE([$0], [AC_LBL_LIBPCAP])
38 AC_TYPE_SIGNAL
39 if test "$ac_cv_type_signal" = void ; then
40@@ -323,7 +323,7 @@
41 dnl
42 dnl AC_LBL_FIXINCLUDES
43 dnl
44-AC_DEFUN(AC_LBL_FIXINCLUDES,
45+AC_DEFUN([AC_LBL_FIXINCLUDES],
46 [if test "$GCC" = yes ; then
47 AC_MSG_CHECKING(for ANSI ioctl definitions)
48 AC_CACHE_VAL(ac_cv_lbl_gcc_fixincludes,
49@@ -369,7 +369,7 @@
50 dnl $2 (yacc appended)
51 dnl $3 (optional flex and bison -P prefix)
52 dnl
53-AC_DEFUN(AC_LBL_LEX_AND_YACC,
54+AC_DEFUN([AC_LBL_LEX_AND_YACC],
55 [AC_ARG_WITH(flex, [ --without-flex don't use flex])
56 AC_ARG_WITH(bison, [ --without-bison don't use bison])
57 if test "$with_flex" = no ; then
58@@ -422,7 +422,7 @@
59 dnl
60 dnl DECLWAITSTATUS (defined)
61 dnl
62-AC_DEFUN(AC_LBL_UNION_WAIT,
63+AC_DEFUN([AC_LBL_UNION_WAIT],
64 [AC_MSG_CHECKING(if union wait is used)
65 AC_CACHE_VAL(ac_cv_lbl_union_wait,
66 AC_TRY_COMPILE([
67@@ -451,7 +451,7 @@
68 dnl
69 dnl HAVE_SOCKADDR_SA_LEN (defined)
70 dnl
71-AC_DEFUN(AC_LBL_SOCKADDR_SA_LEN,
72+AC_DEFUN([AC_LBL_SOCKADDR_SA_LEN],
73 [AC_MSG_CHECKING(if sockaddr struct has sa_len member)
74 AC_CACHE_VAL(ac_cv_lbl_sockaddr_has_sa_len,
75 AC_TRY_COMPILE([
76@@ -476,7 +476,7 @@
77 dnl
78 dnl HAVE_SOCKADDR_STORAGE (defined)
79 dnl
80-AC_DEFUN(AC_LBL_SOCKADDR_STORAGE,
81+AC_DEFUN([AC_LBL_SOCKADDR_STORAGE],
82 [AC_MSG_CHECKING(if sockaddr_storage struct exists)
83 AC_CACHE_VAL(ac_cv_lbl_has_sockaddr_storage,
84 AC_TRY_COMPILE([
85@@ -509,7 +509,7 @@
86 dnl won't be using code that would use that member, or we wouldn't
87 dnl compile in any case).
88 dnl
89-AC_DEFUN(AC_LBL_HP_PPA_INFO_T_DL_MODULE_ID_1,
90+AC_DEFUN([AC_LBL_HP_PPA_INFO_T_DL_MODULE_ID_1],
91 [AC_MSG_CHECKING(if dl_hp_ppa_info_t struct has dl_module_id_1 member)
92 AC_CACHE_VAL(ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1,
93 AC_TRY_COMPILE([
94@@ -535,7 +535,7 @@
95 dnl
96 dnl ac_cv_lbl_have_run_path (yes or no)
97 dnl
98-AC_DEFUN(AC_LBL_HAVE_RUN_PATH,
99+AC_DEFUN([AC_LBL_HAVE_RUN_PATH],
100 [AC_MSG_CHECKING(for ${CC-cc} -R)
101 AC_CACHE_VAL(ac_cv_lbl_have_run_path,
102 [echo 'main(){}' > conftest.c
103@@ -561,7 +561,7 @@
104 dnl int32_t (defined)
105 dnl u_int32_t (defined)
106 dnl
107-AC_DEFUN(AC_LBL_CHECK_TYPE,
108+AC_DEFUN([AC_LBL_CHECK_TYPE],
109 [AC_MSG_CHECKING(for $1 using $CC)
110 AC_CACHE_VAL(ac_cv_lbl_have_$1,
111 AC_TRY_COMPILE([
112@@ -590,7 +590,7 @@
113 dnl
114 dnl LBL_ALIGN (DEFINED)
115 dnl
116-AC_DEFUN(AC_LBL_UNALIGNED_ACCESS,
117+AC_DEFUN([AC_LBL_UNALIGNED_ACCESS],
118 [AC_MSG_CHECKING(if unaligned accesses fail)
119 AC_CACHE_VAL(ac_cv_lbl_unaligned_fail,
120 [case "$host_cpu" in
121@@ -695,7 +695,7 @@
122 dnl HAVE_OS_PROTO_H (defined)
123 dnl os-proto.h (symlinked)
124 dnl
125-AC_DEFUN(AC_LBL_DEVEL,
126+AC_DEFUN([AC_LBL_DEVEL],
127 [rm -f os-proto.h
128 if test "${LBL_CFLAGS+set}" = set; then
129 $1="$$1 ${LBL_CFLAGS}"
130@@ -825,7 +825,7 @@
131 dnl statically and happen to have a libresolv.a lying around (and no
132 dnl libnsl.a).
133 dnl
134-AC_DEFUN(AC_LBL_LIBRARY_NET, [
135+AC_DEFUN([AC_LBL_LIBRARY_NET], [
136 # Most operating systems have gethostbyname() in the default searched
137 # libraries (i.e. libc):
138 # Some OSes (eg. Solaris) place it in libnsl
139@@ -848,7 +848,7 @@
140 dnl Test for __attribute__
141 dnl
142
143-AC_DEFUN(AC_C___ATTRIBUTE__, [
144+AC_DEFUN([AC_C___ATTRIBUTE__], [
145 AC_MSG_CHECKING(for __attribute__)
146 AC_CACHE_VAL(ac_cv___attribute__, [
147 AC_COMPILE_IFELSE(
148@@ -886,7 +886,7 @@
149 dnl
150 dnl -Scott Barron
151 dnl
152-AC_DEFUN(AC_LBL_TPACKET_STATS,
153+AC_DEFUN([AC_LBL_TPACKET_STATS],
154 [AC_MSG_CHECKING(if if_packet.h has tpacket_stats defined)
155 AC_CACHE_VAL(ac_cv_lbl_tpacket_stats,
156 AC_TRY_COMPILE([
diff --git a/meta/packages/libpcap/libpcap-0.9.3/config-fixes.patch b/meta/packages/libpcap/libpcap-1.0.0/config-fixes.patch
index 166816eb8f..166816eb8f 100644
--- a/meta/packages/libpcap/libpcap-0.9.3/config-fixes.patch
+++ b/meta/packages/libpcap/libpcap-1.0.0/config-fixes.patch
diff --git a/meta/packages/libpcap/libpcap-1.0.0/ieee80215-arphrd.patch b/meta/packages/libpcap/libpcap-1.0.0/ieee80215-arphrd.patch
new file mode 100644
index 0000000000..f29c7cb54c
--- /dev/null
+++ b/meta/packages/libpcap/libpcap-1.0.0/ieee80215-arphrd.patch
@@ -0,0 +1,22 @@
1Index: libpcap-1.0.0/pcap-linux.c
2===================================================================
3--- libpcap-1.0.0.orig/pcap-linux.c 2009-01-28 11:58:54.000000000 +0300
4+++ libpcap-1.0.0/pcap-linux.c 2009-01-28 11:59:04.000000000 +0300
5@@ -1616,6 +1616,17 @@
6 * so let's use "Linux-cooked" mode. Jean II */
7 //handle->md.cooked = 1;
8 break;
9+#ifndef ARPHRD_IEEE80215
10+#define ARPHRD_IEEE80215 804
11+#endif
12+#ifndef ARPHRD_IEEE80215_PHY
13+#define ARPHRD_IEEE80215_PHY 805
14+#endif
15+
16+ case ARPHRD_IEEE80215:
17+ case ARPHRD_IEEE80215_PHY:
18+ handle->linktype = DLT_IEEE802_15_4;
19+ break;
20
21 /* ARPHRD_LAPD is unofficial and randomly allocated, if reallocation
22 * is needed, please report it to <daniele@orlandi.com> */
diff --git a/meta/packages/libpcap/libpcap-1.0.0/ldflags.patch b/meta/packages/libpcap/libpcap-1.0.0/ldflags.patch
new file mode 100644
index 0000000000..66ab5f725f
--- /dev/null
+++ b/meta/packages/libpcap/libpcap-1.0.0/ldflags.patch
@@ -0,0 +1,12 @@
1diff -urN libpcap-1.0.0.orig/Makefile.in libpcap-1.0.0/Makefile.in
2--- libpcap-1.0.0.orig/Makefile.in 2008-10-28 01:26:13.000000000 +0000
3+++ libpcap-1.0.0/Makefile.in 2009-04-02 13:54:20.000000000 +0000
4@@ -326,7 +326,7 @@
5 #
6 libpcap.so: $(OBJ)
7 @rm -f $@
8- $(CC) -shared -Wl,-soname,$@.1 -o $@.`cat $(srcdir)/VERSION` $(OBJ) $(DAGLIBS)
9+ $(CC) $(LDFLAGS) -shared -Wl,-soname,$@.1 -o $@.`cat $(srcdir)/VERSION` $(OBJ) $(DAGLIBS)
10
11 #
12 # The following rule succeeds, but the result is untested.
diff --git a/meta/packages/libpcap/libpcap-0.9.3/shared.patch b/meta/packages/libpcap/libpcap-1.0.0/shared.patch
index cc66a5e5ef..cbdb181633 100644
--- a/meta/packages/libpcap/libpcap-0.9.3/shared.patch
+++ b/meta/packages/libpcap/libpcap-1.0.0/shared.patch
@@ -1,7 +1,4 @@
1 1Patch currently not applied but would be better or worse than customised do_install?
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5 2
6--- libpcap-0.9.3/Makefile.in~shared 3--- libpcap-0.9.3/Makefile.in~shared
7+++ libpcap-0.9.3/Makefile.in 4+++ libpcap-0.9.3/Makefile.in
diff --git a/meta/packages/libpcap/libpcap.inc b/meta/packages/libpcap/libpcap.inc
new file mode 100644
index 0000000000..d8f0b2561c
--- /dev/null
+++ b/meta/packages/libpcap/libpcap.inc
@@ -0,0 +1,21 @@
1DESCRIPTION = "Network Packet Capture Library"
2HOMEPAGE = "http://www.tcpdump.org/"
3SECTION = "libs/network"
4LICENSE = "BSD"
5DEPENDS = "flex-native bison-native"
6
7SRC_URI = "http://www.tcpdump.org/release/libpcap-${PV}.tar.gz"
8
9inherit autotools
10
11EXTRA_OECONF = "--with-pcap=linux"
12
13CPPFLAGS_prepend = "-I${S} "
14CFLAGS_prepend = "-I${S} "
15CXXFLAGS_prepend = "-I${S} "
16
17do_configure_prepend () {
18 if [ ! -e acinclude.m4 ]; then
19 cat aclocal.m4 > acinclude.m4
20 fi
21}
diff --git a/meta/packages/libpcap/libpcap_0.9.3.bb b/meta/packages/libpcap/libpcap_0.9.3.bb
deleted file mode 100644
index 61be09d8cd..0000000000
--- a/meta/packages/libpcap/libpcap_0.9.3.bb
+++ /dev/null
@@ -1,33 +0,0 @@
1DESCRIPTION = "Network Packet Capture Library"
2HOMEPAGE = "http://www.tcpdump.org/"
3LICENSE = "BSD"
4SECTION = "libs/network"
5PR = "r2"
6
7SRC_URI = "http://www.at.tcpdump.org/release/libpcap-${PV}.tar.gz \
8 file://shared.patch;patch=1 \
9 file://config-fixes.patch;patch=1"
10
11inherit autotools
12
13EXTRA_OECONF = "--with-pcap=linux"
14
15CPPFLAGS_prepend = "-I${S} "
16CFLAGS_prepend = "-I${S} "
17CXXFLAGS_prepend = "-I${S} "
18
19do_configure_prepend () {
20 if [ ! -e acinclude.m4 ]; then
21 cat aclocal.m4 > acinclude.m4
22 fi
23}
24
25# Does anything really need these things?
26#do_stage () {
27# autotools_stage_all
28#
29# install -d ${STAGING_INCDIR}/net
30# ln -sf ${STAGING_INCDIR}/pcap-bpf.h ${STAGING_INCDIR}/net/bpf.h
31#
32# install -m 0644 acinclude.m4 ${STAGING_DATADIR}/aclocal/libpcap.m4
33#}
diff --git a/meta/packages/libpcap/libpcap_1.0.0.bb b/meta/packages/libpcap/libpcap_1.0.0.bb
new file mode 100644
index 0000000000..edd9706b1e
--- /dev/null
+++ b/meta/packages/libpcap/libpcap_1.0.0.bb
@@ -0,0 +1,19 @@
1require libpcap.inc
2
3PR = "r0"
4
5SRC_URI += "file://config-fixes.patch;patch=1 \
6 file://aclocal.patch;patch=1 \
7 file://ieee80215-arphrd.patch;patch=1 \
8 file://ldflags.patch;patch=1"
9
10#
11# make install doesn't cover the shared lib
12# make install-shared is just broken (no symlinks)
13#
14do_install_prepend () {
15 install -d ${D}${libdir}
16 install -d ${D}${bindir}
17 oe_runmake install-shared DESTDIR=${D}
18 oe_libinstall -a -so libpcap ${D}${libdir}
19}