Root/avrdude/Makefile

Source at commit 1b3135c created 7 years 10 months ago.
By Xiangfu Liu, new package: SDL-widgets: a GUI toolkit on top of the SDL libraries
1# This is free software, licensed under the GNU General Public License v2.
2# See /LICENSE for more information.
3
4include $(TOPDIR)/rules.mk
5
6PKG_NAME:=avrdude
7PKG_VERSION:=5.10
8
9PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
10PKG_SOURCE_URL:=http://download.savannah.gnu.org/releases/avrdude/
11PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
12PKG_RELEASE:=2
13PKG_INSTALL:=1
14
15include $(INCLUDE_DIR)/package.mk
16
17define Package/avrdude
18  SECTION:=utils
19  CATEGORY:=Utilities
20  TITLE:=AVR Downloader/UploaDEr
21  URL:=http://www.bsdhome.com/avrdude/
22  DEPENDS:=+libncurses +libusb +libreadline
23endef
24
25define Package/avrdude/description
26    AVRDUDE is software for programming Atmel AVR Microcontrollers.
27endef
28
29define Package/avrdude/conffiles
30/etc/avrdude.conf
31endef
32
33CONFIGURE_ARGS+= \
34    --enable-shared \
35    --disable-static \
36    --disable-parport
37
38ifeq ($(CONFIG_TARGET_xburst_qi_lb60),y)
39BEN_AVRDUDE_PATCHES_URL:=http://projects.qi-hardware.com/index.php/p/ben-blinkenlights/source/file/master/avrdude/patches/
40BEN_PATCH:=patch -Np2
41define Build/Prepare
42    $(call Build/Prepare/Default)
43
44    mkdir -p $(PKG_BUILD_DIR)/nanonote-patches
45    wget -O $(PKG_BUILD_DIR)/nanonote-patches/series $(BEN_AVRDUDE_PATCHES_URL)/series
46    (cd $(PKG_BUILD_DIR); \
47     while read L; do \
48            wget -O $(PKG_BUILD_DIR)/nanonote-patches/$$$$L $(BEN_AVRDUDE_PATCHES_URL)/$$$$L; \
49        $(BEN_PATCH) < nanonote-patches/$$$$L; \
50     done < $(PKG_BUILD_DIR)/nanonote-patches/series; \
51    )
52endef
53
54#the qi_lb60-patches have some new .c file
55define Build/Configure
56    (cd $(PKG_BUILD_DIR); aclocal; automake)
57    $(call Build/Configure/Default)
58endef
59
60#with out </dev/null. make stop at "config.status: creating avrdude.conf.tmp"
61MAKE_FLAGS+=</dev/null
62
63define Build/Compile
64    $(call Build/Compile/Default)
65# the joy of autocrap (we need this to generate avrdude.conf)
66    $(call Build/Configure/Default)
67endef
68endif
69
70define Package/avrdude/install
71    $(INSTALL_DIR) $(1)/etc
72    $(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/avrdude.conf $(1)/etc/
73    $(INSTALL_DIR) $(1)/usr/bin
74    $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/avrdude $(1)/usr/bin/
75endef
76$(eval $(call BuildPackage,avrdude))
77
78# The following comments configure the Emacs editor. Just ignore them.
79# Local Variables:
80# compile-command: "make -C ~/openwrt-xburst.full_system package/avrdude/{clean,compile} -j2 V=99"
81# End:
82

Archive Download this file



interactive