[ar71xx] make use the USB controller on the WP543 board
[openwrt.git] / target / sdk / Makefile
1 #
2 # Copyright (C) 2006-2008 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10 include $(INCLUDE_DIR)/kernel.mk
11 include $(INCLUDE_DIR)/host.mk
12
13 override MAKEFLAGS=
14
15 PKG_OS:=$(shell uname -s)
16 PKG_CPU:=$(shell uname -m)
17
18 SDK_NAME:=OpenWrt-SDK-$(BOARD)-for-$(PKG_OS)-$(PKG_CPU)
19 SDK_BUILD_DIR:=$(BUILD_DIR)/$(SDK_NAME)
20 EXCLUDE_DIRS:=*/ccache */stamp */man */share */stampfiles */info
21
22 all: compile
23
24 $(BIN_DIR)/$(SDK_NAME).tar.bz2: clean
25 mkdir -p $(SDK_BUILD_DIR)/dl $(SDK_BUILD_DIR)/package
26 $(CP) $(INCLUDE_DIR) $(SCRIPT_DIR) $(TOPDIR)/docs $(SDK_BUILD_DIR)/
27 $(TAR) -cf - -C $(TOPDIR) $(foreach exclude,$(EXCLUDE_DIRS),--exclude="$(exclude)") --exclude="staging_dir/$(ARCH)" staging_dir | \
28 $(TAR) -xf - -C $(SDK_BUILD_DIR)
29 mkdir -p $(SDK_BUILD_DIR)/target/linux
30 $(CP) $(GENERIC_PLATFORM_DIR) $(PLATFORM_DIR) $(SDK_BUILD_DIR)/target/linux/
31 rm -rf \
32 $(SDK_BUILD_DIR)/target/linux/*/files \
33 $(SDK_BUILD_DIR)/target/linux/*/patches
34 $(CP) \
35 $(TOPDIR)/LICENSE \
36 $(TOPDIR)/feeds.conf.default \
37 $(TOPDIR)/rules.mk \
38 $(TOPDIR)/.config \
39 ./files/Config.in \
40 ./files/Makefile \
41 ./files/README.SDK \
42 $(SDK_BUILD_DIR)/
43 $(CP) \
44 ./files/package/rules.mk \
45 $(TOPDIR)/package/Makefile \
46 $(SDK_BUILD_DIR)/package/
47 echo REVISION:="$(REVISION)" > $(SDK_BUILD_DIR)/include/version.mk
48 find $(SDK_BUILD_DIR) -name .git | $(XARGS) rm -rf
49 find $(SDK_BUILD_DIR) -name .svn | $(XARGS) rm -rf
50 find $(SDK_BUILD_DIR) -name CVS | $(XARGS) rm -rf
51 (cd $(BUILD_DIR); \
52 tar cfj $@ $(SDK_NAME); \
53 )
54
55 download:
56 prepare:
57 compile: $(BIN_DIR)/$(SDK_NAME).tar.bz2
58 install: compile
59
60 clean:
61 rm -rf $(SDK_BUILD_DIR) $(BIN_DIR)/$(SDK_NAME).tar.bz2
This page took 0.047183 seconds and 5 git commands to generate.