Magellan Linux

Contents of /branches/R11-unstable/core/iproute2/iproute2-4.20.0-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 32178 - (show annotations) (download)
Mon Apr 29 11:49:13 2019 UTC (4 years, 11 months ago) by niro
File size: 1552 byte(s)
-release branches/R11-unstable
1 # $Id$
2
3 PNAME="iproute2"
4 PVER="4.20.0"
5 PBUILD="r1"
6
7 PCAT="sys-apps"
8
9 DESCRIPTION="Collection of utilities for controlling TCP/IP networking and Traffic Control."
10 HOMEPAGE="http://linux-net.osdl.org/index.php/Iproute2"
11
12 # arpd needs db
13 DEPEND=">= dev-db/db-6.2
14 >= net-misc/iptables-1.4"
15
16 SDEPEND=">= virtual/kernel-headers
17 >= virtual/sed"
18
19 PROVIDE="virtual/iproute2"
20
21 # get the right pver
22 if [[ ${PVER} != ${PVER%.*.*.*} ]]
23 then
24 MYPVER="${PVER%.*}-${PVER##*.}"
25 else
26 MYPVER="${PVER}"
27 fi
28
29 SRCFILE="${PNAME}-${MYPVER}.tar.xz"
30 SRCDIR="${BUILDDIR}/${PNAME}-${MYPVER}"
31
32 sminclude mbuild
33 msetfeature "!check"
34
35 SRC_URI=(
36 http://www.kernel.org/pub/linux/utils/net/${PNAME}/${SRCFILE}
37 http://devresources.linux-foundation.org/dev/${PNAME}/download/${SRCFILE}
38 http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/distfiles/${SRCFILE}
39 mirror://${PNAME}/${SRCFILE}
40 )
41
42 UP2DATE="updatecmd http://www.kernel.org/pub/linux/utils/net/${PNAME}/ | highesttarball xz"
43
44 src_prepare()
45 {
46 munpack ${SRCFILE} || die
47 cd ${SRCDIR}
48
49 # fix cflags
50 sed -i "s:-O2:${CFLAGS}:" Makefile || die
51
52 # fix libdir
53 sed -i "/^LIBDIR/s:=.*:=/$(mlibdir):" Makefile || die
54 }
55
56 src_compile()
57 {
58 cd ${SRCDIR}
59 mmake \
60 IPT_LIB_DIR=$(pkg-config xtables --variable=xtlibdir) \
61 SBINDIR=/usr/sbin \
62 LIBDIR=/usr/$(mlibdir) \
63 || die
64 }
65
66 src_install()
67 {
68 cd ${SRCDIR}
69 make DESTDIR=${BINDIR} \
70 DOCDIR=/usr/share/doc/${PNAME}-${PVER} \
71 MANDIR=/usr/share/man \
72 SBINDIR=/usr/sbin \
73 LIBDIR=/usr/$(mlibdir) \
74 install || die
75 minstalldocs ABOUT-NLS COPYING README* TODO || die
76 }