diff options
Diffstat (limited to 'meta/recipes-connectivity/iproute2')
3 files changed, 81 insertions, 0 deletions
diff --git a/meta/recipes-connectivity/iproute2/iproute2.inc b/meta/recipes-connectivity/iproute2/iproute2.inc new file mode 100644 index 0000000000..3db21db8d9 --- /dev/null +++ b/meta/recipes-connectivity/iproute2/iproute2.inc | |||
@@ -0,0 +1,37 @@ | |||
1 | SUMMARY = "TCP / IP networking and traffic control utilities" | ||
2 | DESCRIPTION = "Iproute2 is a collection of utilities for controlling \ | ||
3 | TCP / IP networking and traffic control in Linux. Of the utilities ip \ | ||
4 | and tc are the most important. ip controls IPv4 and IPv6 \ | ||
5 | configuration and tc stands for traffic control." | ||
6 | HOMEPAGE = "http://www.linuxfoundation.org/collaborate/workgroups/networking/iproute2" | ||
7 | SECTION = "base" | ||
8 | LICENSE = "GPLv2+" | ||
9 | LIC_FILES_CHKSUM = "file://COPYING;md5=eb723b61539feef013de476e68b5c50a \ | ||
10 | file://ip/ip.c;beginline=3;endline=8;md5=689d691d0410a4b64d3899f8d6e31817" | ||
11 | |||
12 | DEPENDS = "flex-native bison-native iptables" | ||
13 | |||
14 | inherit update-alternatives | ||
15 | |||
16 | EXTRA_OEMAKE = "CC='${CC}' KERNEL_INCLUDE=${STAGING_INCDIR} DOCDIR=${docdir}/iproute2 SUBDIRS='lib tc ip' SBINDIR='${base_sbindir}' LIBDIR='${libdir}'" | ||
17 | |||
18 | do_install () { | ||
19 | oe_runmake DESTDIR=${D} install | ||
20 | mv ${D}${base_sbindir}/ip ${D}${base_sbindir}/ip.iproute2 | ||
21 | install -d ${D}${datadir} | ||
22 | mv ${D}/share/* ${D}${datadir}/ || true | ||
23 | rm ${D}/share -rf || true | ||
24 | } | ||
25 | |||
26 | # There are only .so files in iproute2 | ||
27 | INSANE_SKIP_${PN} = "dev-so" | ||
28 | |||
29 | FILES_${PN} += "${libdir}/tc" | ||
30 | FILES_${PN}-dbg += "${libdir}/tc/.debug" | ||
31 | |||
32 | ALTERNATIVE_${PN} = "ip" | ||
33 | ALTERNATIVE_TARGET[ip] = "${base_sbindir}/ip.${BPN}" | ||
34 | ALTERNATIVE_LINK_NAME[ip] = "${base_sbindir}/ip" | ||
35 | ALTERNATIVE_PRIORITY = "100" | ||
36 | |||
37 | PARALLEL_MAKE = "" | ||
diff --git a/meta/recipes-connectivity/iproute2/iproute2/configure-cross.patch b/meta/recipes-connectivity/iproute2/iproute2/configure-cross.patch new file mode 100644 index 0000000000..866609ca99 --- /dev/null +++ b/meta/recipes-connectivity/iproute2/iproute2/configure-cross.patch | |||
@@ -0,0 +1,32 @@ | |||
1 | From 85b0589b4843c03e8e6fd9416d71ea449a73c5c0 Mon Sep 17 00:00:00 2001 | ||
2 | From: Koen Kooi <koen@dominion.thruhere.net> | ||
3 | Date: Thu, 3 Nov 2011 10:46:16 +0100 | ||
4 | Subject: [PATCH] make configure cross compile safe | ||
5 | |||
6 | According to Kevin Tian: | ||
7 | Upstream-Status: Pending | ||
8 | |||
9 | Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> | ||
10 | Signed-off-by: Shane Wang <shane.wang@intel.com> | ||
11 | |||
12 | Index: iproute2-3.7.0/configure | ||
13 | =================================================================== | ||
14 | --- iproute2-3.7.0.orig/configure | ||
15 | +++ iproute2-3.7.0/configure | ||
16 | @@ -2,6 +2,7 @@ | ||
17 | # This is not an autconf generated configure | ||
18 | # | ||
19 | INCLUDE=${1:-"$PWD/include"} | ||
20 | +SYSROOT=$1 | ||
21 | |||
22 | # Make a temp directory in build tree. | ||
23 | TMPDIR=$(mktemp -d config.XXXXXX) | ||
24 | @@ -158,7 +159,7 @@ check_ipt_lib_dir() | ||
25 | return | ||
26 | fi | ||
27 | |||
28 | - for dir in /lib /usr/lib /usr/local/lib | ||
29 | + for dir in $SYSROOT/lib $SYSROOT/usr/lib $SYSROOT/usr/local/lib | ||
30 | do | ||
31 | for file in $dir/{xtables,iptables}/lib*t_*so ; do | ||
32 | if [ -f $file ]; then | ||
diff --git a/meta/recipes-connectivity/iproute2/iproute2_3.10.0.bb b/meta/recipes-connectivity/iproute2/iproute2_3.10.0.bb new file mode 100644 index 0000000000..2220467c87 --- /dev/null +++ b/meta/recipes-connectivity/iproute2/iproute2_3.10.0.bb | |||
@@ -0,0 +1,12 @@ | |||
1 | require iproute2.inc | ||
2 | |||
3 | SRC_URI = "${KERNELORG_MIRROR}/linux/utils/net/${BPN}/${BPN}-${PV}.tar.xz \ | ||
4 | file://configure-cross.patch \ | ||
5 | " | ||
6 | |||
7 | SRC_URI[md5sum] = "45fb5427fc723a0001c72b92c931ba02" | ||
8 | SRC_URI[sha256sum] = "c4023d8d722a1ed673474ca0e5a2d61ebd747cc7001a91321757422d9074c97e" | ||
9 | |||
10 | # CFLAGS are computed in Makefile and reference CCOPTS | ||
11 | # | ||
12 | EXTRA_OEMAKE_append = " CCOPTS='${CFLAGS}'" | ||