2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
12 PKG_VERSION
:=2.6.15-060110
15 PKG_BUILD_DIR
:=$(BUILD_DIR
)/iproute2-
$(PKG_VERSION
)
16 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
17 PKG_SOURCE_URL
:=http
://developer.osdl.org
/dev
/iproute2
/download
/
18 PKG_MD5SUM
:=04f57a6d366d36426d276178b600f5c5
21 include $(INCLUDE_DIR
)/package.mk
27 TITLE
:=A routing control utility
32 TITLE
:=A traffic control utility
35 define Build
/Configure
36 $(SED
) "s:-O2:${TARGET_CFLAGS}:g" $(PKG_BUILD_DIR
)/Makefile
37 $(SED
) "s,-I/usr/include/db3,," $(PKG_BUILD_DIR
)/Makefile
38 $(SED
) "s,^KERNEL_INCLUDE.*,KERNEL_INCLUDE=$(LINUX_DIR)/include," \
39 $(PKG_BUILD_DIR
)/Makefile
40 $(SED
) "s,^LIBC_INCLUDE.*,LIBC_INCLUDE=$(STAGING_DIR)/include," \
41 $(PKG_BUILD_DIR
)/Makefile
42 # For now disable compiling of the misc directory because it seems to fail
43 rm -rf
$(PKG_BUILD_DIR
)/misc
44 $(SED
) "s, misc,," $(PKG_BUILD_DIR
)/Makefile
48 $(MAKE
) -j1
-C
$(PKG_BUILD_DIR
)/netem HOSTCC
=$(HOSTCC
) CFLAGS
="-D_GNU_SOURCE -O2 -Wstrict-prototypes -Wall -I ../include -DRESOLVE_HOSTNAMES"
49 $(MAKE
) -j1
-C
$(PKG_BUILD_DIR
) $(TARGET_CONFIGURE_OPTS
) KERNEL_INCLUDE
=$(LINUX_DIR
)/include all tc
/tc ip
/ip
52 define Package
/ip
/install
53 install -d
-m0755
$(1)/usr
/sbin
54 install -m0755
$(PKG_BUILD_DIR
)/ip
/ip
$(1)/usr
/sbin
/
57 define Package
/tc
/install
58 install -d
-m0755
$(1)/usr
/sbin
59 install -m0755
$(PKG_BUILD_DIR
)/tc
/tc
$(1)/usr
/sbin
/
62 $(eval
$(call BuildPackage
,ip
))
63 $(eval
$(call BuildPackage
,tc
))