firmware-utils: add HLK-RM04 tool
[15.05/openwrt.git] / tools / firmware-utils / Makefile
1 #
2 # Copyright (C) 2006-2012 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 include $(TOPDIR)/rules.mk
8
9 PKG_NAME := firmware-utils
10
11 include $(INCLUDE_DIR)/host-build.mk
12 include $(INCLUDE_DIR)/kernel.mk
13
14 define cc
15         $(HOSTCC) $(HOST_CFLAGS) -include endian.h $(HOST_STATIC_LINKING) -o $(HOST_BUILD_DIR)/bin/$(firstword $(1)) $(foreach src,$(1),src/$(src).c) $(2)
16 endef
17
18 define Host/Compile
19         mkdir -p $(HOST_BUILD_DIR)/bin
20         $(call cc,addpattern)
21         $(call cc,trx)
22         $(call cc,motorola-bin)
23         $(call cc,dgfirmware)
24         $(call cc,mkdir615h1 md5)
25         $(call cc,trx2usr)
26         $(call cc,ptgen)
27         $(call cc,airlink)
28         $(call cc,srec2bin)
29         $(call cc,mkmylofw)
30         $(call cc,mkcsysimg)
31         $(call cc,mkzynfw)
32         $(call cc,lzma2eva,-lz)
33         $(call cc,mkcasfw)
34         $(call cc,mkfwimage,-lz)
35         $(call cc,mkfwimage2,-lz)
36         $(call cc,imagetag imagetag_cmdline)
37         $(call cc,add_header)
38         $(call cc,makeamitbin)
39         $(call cc,encode_crc)
40         $(call cc,nand_ecc)
41         $(call cc,mkplanexfw sha1)
42         $(call cc,mktplinkfw md5)
43         $(call cc,mktplinkfw2 md5)
44         $(call cc,pc1crypt)
45         $(call cc,osbridge-crc)
46         $(call cc,wrt400n cyg_crc32)
47         $(call cc,mkdniimg)
48         $(call cc,mktitanimg)
49         $(call cc,mkchkimg)
50         $(call cc,mkzcfw cyg_crc32)
51         $(call cc,spw303v)
52         $(call cc,trx2edips)
53         $(call cc,xorimage)
54         $(call cc,buffalo-enc buffalo-lib, -Wall)
55         $(call cc,buffalo-tag buffalo-lib, -Wall)
56         $(call cc,buffalo-tftp buffalo-lib, -Wall)
57         $(call cc,mkwrgimg md5, -Wall)
58         $(call cc,mkedimaximg)
59         $(call cc,mkbrncmdline)
60         $(call cc,mkbrnimg)
61         $(call cc,mkdapimg)
62         $(call cc, mkcameofw, -Wall)
63         $(call cc,seama md5)
64         $(call cc,fix-u-media-header cyg_crc32,-Wall)
65         $(call cc,hcsmakeimage bcmalgo)
66         $(call cc,mkporayfw, -Wall)
67         $(call cc,mkhilinkfw, -lcrypto)
68         $(call cc,mkdcs932, -Wall)
69 endef
70
71 define Host/Install
72         $(INSTALL_BIN) $(HOST_BUILD_DIR)/bin/* $(STAGING_DIR_HOST)/bin/
73 endef
74
75 $(eval $(call HostBuild))