1 #############################################################
5 #############################################################
6 include $(TOPDIR
)/rules.mk
11 PKG_SOURCE_URL
:=http
://developer.osdl.org
/dev
/iproute2
/download
/
12 PKG_SOURCE
:=$(PKG_NAME
)-2.6.9-041019.
tar.gz
13 PKG_BUILD_DIR
:=$(BUILD_DIR
)/iproute2-2.6
.9
16 PKG_IP
:=$(PACKAGE_DIR
)/ip_
$(PKG_VERSION
)-$(PKG_RELEASE
)_
$(ARCH
).ipk
17 PKG_IP_DIR
:=$(PKG_BUILD_DIR
)/ipkg
/ip
19 PKG_TC
:=$(PACKAGE_DIR
)/tc_
$(PKG_VERSION
)-$(PKG_RELEASE
)_
$(ARCH
).ipk
20 PKG_TC_DIR
:=$(PKG_BUILD_DIR
)/ipkg
/tc
22 $(DL_DIR
)/$(PKG_SOURCE
):
23 $(WGET
) -P
$(DL_DIR
) $(PKG_SOURCE_URL
)/$(PKG_SOURCE
)
25 $(PKG_BUILD_DIR
)/.patched
: $(DL_DIR
)/$(PKG_SOURCE
)
26 $(PKG_CAT
) $(DL_DIR
)/$(PKG_SOURCE
) |
tar -C
$(BUILD_DIR
) $(TAR_OPTIONS
) -
27 $(PATCH
) $(PKG_BUILD_DIR
) .
/patches
28 $(SED
) "s:-O2:${TARGET_CFLAGS}:g" $(PKG_BUILD_DIR
)/Makefile
29 touch
$(PKG_BUILD_DIR
)/.patched
31 $(PKG_BUILD_DIR
)/.configured
: $(PKG_BUILD_DIR
)/.patched
32 $(SED
) "s,-I/usr/include/db3,," $(PKG_BUILD_DIR
)/Makefile
33 $(SED
) "s,^KERNEL_INCLUDE.*,KERNEL_INCLUDE=$(LINUX_DIR)/include," \
34 $(PKG_BUILD_DIR
)/Makefile
35 $(SED
) "s,^LIBC_INCLUDE.*,LIBC_INCLUDE=$(STAGING_DIR)/include," \
36 $(PKG_BUILD_DIR
)/Makefile
37 # For now disable compiling of the misc directory because it seems to fail
38 rm -rf
$(PKG_BUILD_DIR
)/misc
39 $(SED
) "s, misc,," $(PKG_BUILD_DIR
)/Makefile
40 touch
$(PKG_BUILD_DIR
)/.configured
42 $(PKG_BUILD_DIR
)/tc
/tc
: $(PKG_BUILD_DIR
)/.configured
43 $(MAKE
) -C
$(PKG_BUILD_DIR
) $(TARGET_CONFIGURE_OPTS
) KERNEL_INCLUDE
=$(LINUX_DIR
)/include all tc
/tc
45 $(PKG_BUILD_DIR
)/ip
/ip
: $(PKG_BUILD_DIR
)/.configured
46 $(MAKE
) -C
$(PKG_BUILD_DIR
) $(TARGET_CONFIGURE_OPTS
) KERNEL_INCLUDE
=$(LINUX_DIR
)/include all ip
/ip
49 $(PKG_IP
): $(PKG_BUILD_DIR
)/ip
/ip
$(PACKAGE_DIR
)
50 $(SCRIPT_DIR
)/make-ipkg-dir.sh
$(PKG_IP_DIR
) ip.control
$(PKG_VERSION
)-$(PKG_RELEASE
) $(ARCH
)
51 mkdir
-p
$(PKG_IP_DIR
)/usr
/sbin
52 cp
$< $(PKG_IP_DIR
)/usr
/sbin
/
53 $(STRIP
) $(PKG_IP_DIR
)/usr
/sbin
/*
54 $(IPKG_BUILD
) $(PKG_IP_DIR
) $(PACKAGE_DIR
)
56 $(IPKG_STATE_DIR
)/info/ip.list
: $(PKG_IP
)
57 $(IPKG
) install $(PKG_IP
)
59 $(PKG_TC
): $(PKG_BUILD_DIR
)/tc
/tc
$(PACKAGE_DIR
)
60 $(SCRIPT_DIR
)/make-ipkg-dir.sh
$(PKG_TC_DIR
) tc.control
$(PKG_VERSION
)-$(PKG_RELEASE
) $(ARCH
)
61 mkdir
-p
$(PKG_TC_DIR
)/usr
/sbin
62 cp
$< $(PKG_TC_DIR
)/usr
/sbin
/
63 $(STRIP
) $(PKG_TC_DIR
)/usr
/sbin
/*
64 $(IPKG_BUILD
) $(PKG_TC_DIR
) $(PACKAGE_DIR
)
66 $(IPKG_STATE_DIR
)/info/tc.list
: $(PKG_TC
)
67 $(IPKG
) install $(PKG_TC
)
70 mkdir
-p
$(PACKAGE_DIR
)
73 ifneq ($(BR2_PACKAGE_IPROUTE2_IP
),)
76 ifneq ($(BR2_PACKAGE_IPROUTE2_TC
),)
80 ifeq ($(BR2_PACKAGE_IPROUTE2_IP
),y
)
81 INSTALL_TARGETS
+= $(IPKG_STATE_DIR
)/info/ip.list
83 ifeq ($(BR2_PACKAGE_IPROUTE2_TC
),y
)
84 INSTALL_TARGETS
+= $(IPKG_STATE_DIR
)/info/tc.list
87 source
: $(DL_DIR
)/$(PKG_SOURCE
)
88 prepare
: $(PKG_BUILD_DIR
)/.patched
90 install: $(INSTALL_TARGETS
)
93 rm -rf
$(PKG_BUILD_DIR
)
This page took 0.043503 seconds and 5 git commands to generate.