CFE-ready mtd driver, needs fixing though, update kernel config
[openwrt.git] / package / busybox / Makefile
1 #
2 # Copyright (C) 2006 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
11 PKG_NAME:=busybox
12 PKG_VERSION:=1.4.1
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=http://www.busybox.net/downloads \
17 http://distfiles.gentoo.org/distfiles/
18 PKG_MD5SUM:=5728403bce309cdabcffa414e2e64052
19
20 include $(INCLUDE_DIR)/package.mk
21
22 init-y :=
23 init-$(CONFIG_BUSYBOX_CONFIG_HTTPD) += httpd
24 init-$(CONFIG_BUSYBOX_CONFIG_CROND) += cron
25 init-$(CONFIG_BUSYBOX_CONFIG_TELNETD) += telnet
26
27 define Package/busybox
28 SECTION:=base
29 CATEGORY:=Base system
30 TITLE:=Core utilities for embedded Linux
31 URL:=http://busybox.net/
32 MENU:=1
33 endef
34
35 define Package/busybox/description
36 The Swiss Army Knife of embedded Linux.
37 It slices, it dices, it makes Julian Fries.
38 endef
39
40 define Package/busybox/config
41 source "$(SOURCE)/target-config.in"
42 menu "Configuration"
43 depends on PACKAGE_busybox
44 source "$(SOURCE)/config/Config.in"
45 endmenu
46 endef
47
48 define Build/Configure
49 $(SCRIPT_DIR)/gen_busybox_config.pl $(TOPDIR)/.config > $(PKG_BUILD_DIR)/.config
50 yes '' | $(MAKE) -C $(PKG_BUILD_DIR) \
51 CC="$(TARGET_CC)" \
52 CROSS_COMPILE="$(TARGET_CROSS)" \
53 ARCH="$(ARCH)" \
54 oldconfig
55 endef
56
57 define Build/Compile
58 $(MAKE) -C $(PKG_BUILD_DIR) \
59 CC="$(TARGET_CC)" \
60 CROSS_COMPILE="$(TARGET_CROSS)" \
61 EXTRA_CFLAGS="$(TARGET_CFLAGS)" \
62 ARCH="$(ARCH)" \
63 IPKG_ARCH="$(ARCH)" \
64 all
65 endef
66
67 define Package/busybox/install
68 $(MAKE) -C $(PKG_BUILD_DIR) \
69 CC="$(TARGET_CC)" \
70 CROSS_COMPILE="$(TARGET_CROSS)" \
71 EXTRA_CFLAGS="$(TARGET_CFLAGS)" \
72 ARCH="$(ARCH)" \
73 IPKG_ARCH="$(ARCH)" \
74 CONFIG_PREFIX="$(1)" \
75 install
76 $(INSTALL_DIR) $(1)/etc/init.d
77 for tmp in $(init-y); do \
78 $(INSTALL_BIN) ./files/$$$$tmp $(1)/etc/init.d/$$$$tmp; \
79 done
80 -rm -rf $(1)/lib64
81 endef
82
83 $(eval $(call BuildPackage,busybox))
This page took 0.055192 seconds and 5 git commands to generate.