2011-03-03 11:06:19 +02:00
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=avrdude
|
2012-09-10 18:32:58 +03:00
|
|
|
PKG_VERSION:=5.11.1
|
2011-03-03 11:06:19 +02:00
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
|
|
PKG_SOURCE_URL:=http://download.savannah.gnu.org/releases/avrdude/
|
|
|
|
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
2011-03-11 08:44:45 +02:00
|
|
|
PKG_RELEASE:=2
|
2011-03-03 11:06:19 +02:00
|
|
|
PKG_INSTALL:=1
|
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/avrdude
|
2011-03-03 11:42:52 +02:00
|
|
|
SECTION:=utils
|
|
|
|
CATEGORY:=Utilities
|
|
|
|
TITLE:=AVR Downloader/UploaDEr
|
|
|
|
URL:=http://www.bsdhome.com/avrdude/
|
2012-10-15 14:12:12 +03:00
|
|
|
DEPENDS:=+libncurses +libusb +libreadline +libftdi +libusb-1.0
|
2011-03-03 11:06:19 +02:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/avrdude/description
|
|
|
|
AVRDUDE is software for programming Atmel AVR Microcontrollers.
|
|
|
|
endef
|
|
|
|
|
2011-03-03 11:42:52 +02:00
|
|
|
define Package/avrdude/conffiles
|
|
|
|
/etc/avrdude.conf
|
|
|
|
endef
|
2011-03-03 11:06:19 +02:00
|
|
|
|
2011-03-04 04:14:33 +02:00
|
|
|
CONFIGURE_ARGS+= \
|
|
|
|
--enable-shared \
|
|
|
|
--disable-static \
|
|
|
|
--disable-parport
|
|
|
|
|
2011-03-04 04:32:19 +02:00
|
|
|
ifeq ($(CONFIG_TARGET_xburst_qi_lb60),y)
|
2012-09-10 18:32:58 +03:00
|
|
|
BEN_AVRDUDE_PATCHES_URL:=http://projects.qi-hardware.com/index.php/p/ben-blinkenlights/source/file/master/avrdude/patches
|
|
|
|
BEN_PATCH:=patch -Np1
|
2011-03-11 08:44:45 +02:00
|
|
|
define Build/Prepare
|
|
|
|
$(call Build/Prepare/Default)
|
|
|
|
|
|
|
|
mkdir -p $(PKG_BUILD_DIR)/nanonote-patches
|
|
|
|
wget -O $(PKG_BUILD_DIR)/nanonote-patches/series $(BEN_AVRDUDE_PATCHES_URL)/series
|
|
|
|
(cd $(PKG_BUILD_DIR); \
|
|
|
|
while read L; do \
|
|
|
|
wget -O $(PKG_BUILD_DIR)/nanonote-patches/$$$$L $(BEN_AVRDUDE_PATCHES_URL)/$$$$L; \
|
|
|
|
$(BEN_PATCH) < nanonote-patches/$$$$L; \
|
|
|
|
done < $(PKG_BUILD_DIR)/nanonote-patches/series; \
|
|
|
|
)
|
|
|
|
endef
|
|
|
|
|
2011-03-04 04:14:33 +02:00
|
|
|
#the qi_lb60-patches have some new .c file
|
2011-03-03 11:42:52 +02:00
|
|
|
define Build/Configure
|
|
|
|
(cd $(PKG_BUILD_DIR); aclocal; automake)
|
|
|
|
$(call Build/Configure/Default)
|
2011-03-03 11:06:19 +02:00
|
|
|
endef
|
|
|
|
|
2011-03-04 04:14:33 +02:00
|
|
|
#with out </dev/null. make stop at "config.status: creating avrdude.conf.tmp"
|
|
|
|
MAKE_FLAGS+=</dev/null
|
|
|
|
|
|
|
|
define Build/Compile
|
|
|
|
$(call Build/Compile/Default)
|
|
|
|
# the joy of autocrap (we need this to generate avrdude.conf)
|
|
|
|
$(call Build/Configure/Default)
|
|
|
|
endef
|
|
|
|
endif
|
2011-03-03 11:42:52 +02:00
|
|
|
|
|
|
|
define Package/avrdude/install
|
|
|
|
$(INSTALL_DIR) $(1)/etc
|
|
|
|
$(INSTALL_CONF) $(PKG_INSTALL_DIR)/etc/avrdude.conf $(1)/etc/
|
|
|
|
$(INSTALL_DIR) $(1)/usr/bin
|
|
|
|
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/avrdude $(1)/usr/bin/
|
|
|
|
endef
|
2011-03-03 11:06:19 +02:00
|
|
|
$(eval $(call BuildPackage,avrdude))
|
|
|
|
|
|
|
|
# The following comments configure the Emacs editor. Just ignore them.
|
|
|
|
# Local Variables:
|
|
|
|
# compile-command: "make -C ~/openwrt-xburst.full_system package/avrdude/{clean,compile} -j2 V=99"
|
|
|
|
# End:
|