[package] switch irssi to using the build variants infrastructure (#6726)
[openwrt/svn-archive/archive.git] / devel / ksymoops / Makefile
1 #
2 # Copyright (C) 2009 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9 include $(INCLUDE_DIR)/kernel.mk
10
11 PKG_NAME:=ksymoops
12 PKG_VERSION:=2.4.11
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=@KERNEL/linux/utils/kernel/ksymoops/v2.4/
17 PKG_MD5SUM:=4a8249e182a5dbc75e566d162e9f3314
18
19 PKG_BUILD_DEPENDS:=binutils
20
21 include $(INCLUDE_DIR)/package.mk
22
23 define Package/ksymoops
24 SECTION:=utils
25 CATEGORY:=Utilities
26 DEPENDS:=@LINUX_2_6 @mips||mipsel||m68k||i386
27 TITLE:=Interpret oops of the kernel
28 URL:=http://www.kernel.org/pub/linux/utils/kernel/ksymoops/v2.4/
29 MENU:=1
30 endef
31
32 define Package/kexec-tools/description
33 endef
34
35 define Build/Configure
36 endef
37
38 TARGET=$(strip $(shell echo $(TARGET_CFLAGS) | cut -d- -f4 | cut -d= -f2))
39
40 define Build/Compile
41 $(MAKE) -C $(PKG_BUILD_DIR) \
42 CC="$(TARGET_CC)" \
43 BFD_PREFIX="$(STAGING_DIR)/usr" \
44 DEF_TARGET='\"$(TARGET)\"' \
45 DEF_ARCH='\"$(ARCH)\"' \
46 DEF_MAP='\"$(LINUX_DIR)/System.map\"' \
47 CROSS="$(TARGET_CROSS)" \
48 INSTALL_PREFIX="$(PKG_INSTALL_DIR)" \
49 all install
50 endef
51
52 define Package/ksymoops/install
53 $(INSTALL_DIR) $(1)/bin
54 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/bin/$(TARGET_CROSS)ksymoops $(1)/bin/ksymoops
55 endef
56
57 $(eval $(call BuildPackage,ksymoops))