XScale support (Gateway 7001), take two
[openwrt.git] / openwrt / target / linux / package / base-files / Makefile
1 # $Id$
2
3 include $(TOPDIR)/rules.mk
4
5 PKG_NAME := base-files-arch
6 PKG_RELEASE := 2
7 PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
8
9 include $(TOPDIR)/package/rules.mk
10
11 IDIR_OPENWRT:=$(PKG_BUILD_DIR)/ipkg
12 IPKG_OPENWRT:=$(PACKAGE_DIR)/base-files-$(BOARD)-$(KERNEL)_$(PKG_RELEASE)_$(ARCH).ipk
13
14 $(PKG_BUILD_DIR)/.prepared:
15 mkdir -p $(PKG_BUILD_DIR)
16 touch $@
17
18 ifeq ($(BOARD),ar7)
19 $(PKG_BUILD_DIR)/adam2patcher: src/adam2patcher.c
20 $(TARGET_CC) -o $@ $<
21
22 $(PKG_BUILD_DIR)/.built: $(PKG_BUILD_DIR)/adam2patcher
23
24 $(IDIR_OPENWRT)/sbin/adam2patcher: $(PKG_BUILD_DIR)/adam2patcher
25 mkdir -p $(IDIR_OPENWRT)/sbin
26 $(CP) $(PKG_BUILD_DIR)/adam2patcher $(IDIR_OPENWRT)/sbin
27
28 $(IPKG_OPENWRT): $(IDIR_OPENWRT)/sbin/adam2patcher
29 endif
30
31 ifeq ($(BOARD),brcm)
32 $(PKG_BUILD_DIR)/jffs2root: src/jffs2root.c
33 $(TARGET_CC) -o $@ $<
34
35 $(PKG_BUILD_DIR)/.built: $(PKG_BUILD_DIR)/jffs2root
36
37 $(IDIR_OPENWRT)/sbin/jffs2root: $(PKG_BUILD_DIR)/jffs2root
38 mkdir -p $(IDIR_OPENWRT)/sbin
39 $(CP) $(PKG_BUILD_DIR)/jffs2root $(IDIR_OPENWRT)/sbin
40
41 $(IPKG_OPENWRT): $(IDIR_OPENWRT)/sbin/jffs2root
42 endif
43
44 $(PKG_BUILD_DIR)/.built:
45 touch $@
46
47 $(IDIR_OPENWRT):
48 $(SCRIPT_DIR)/make-ipkg-dir.sh $(IDIR_OPENWRT) ipkg/base-files-arch.control $(PKG_RELEASE) $(ARCH)
49 $(SED) s,base-files-arch,base-files-$(BOARD)-$(KERNEL),g $(IDIR_OPENWRT)/CONTROL/control
50
51 $(IPKG_OPENWRT): $(IDIR_OPENWRT)
52 [ -d files/$(BOARD)-$(KERNEL) ] && $(CP) -fpR files/$(BOARD)-$(KERNEL)/* $(IDIR_OPENWRT)/
53 find $(IDIR_OPENWRT) -name CVS | xargs rm -rf
54 find $(IDIR_OPENWRT) -name .svn | xargs rm -rf
55 $(RSTRIP) $(IDIR_OPENWRT)
56 $(IPKG_BUILD) $(IDIR_OPENWRT) $(PACKAGE_DIR)
57
58 install-targets: compile openwrt-install
59
60 openwrt-install:
61 $(IPKG) install $(IPKG_OPENWRT)
62
63 compile-targets: install-dev $(IPKG_OPENWRT)
64 install-dev:
65 mkdir -p $(STAGING_DIR)/usr/include
66 $(CP) ./include/[a-z]* $(STAGING_DIR)/usr/include/
This page took 0.078541 seconds and 5 git commands to generate.