]> sigrok.org Git - sigrok-firmware-fx2lafw.git/commitdiff
Added rules to Makefile to convert firmware to binary
authorJoel Holdsworth <redacted>
Mon, 12 Mar 2012 22:07:33 +0000 (22:07 +0000)
committerJoel Holdsworth <redacted>
Mon, 12 Mar 2012 22:07:33 +0000 (22:07 +0000)
Makefile.include

index 213b6698e34f936e8fc4fe9cac472bf655131d43..5c01a958019fb4b8b2a2c20332b2c4e0a6458764 100644 (file)
 ## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
 ##
 
+OBJCOPY ?= objcopy
+
 FX2LIBDIR ?= ../../fx2lib
+BUILDDIR ?= build
 
 DEBUG ?= 0
 ifeq ($(DEBUG), 1)
@@ -30,5 +33,7 @@ endif
 
 SDCCFLAGS += -I../../include/
 
-include $(FX2LIBDIR)/lib/fx2.mk
+$(BUILDDIR)/$(BASENAME).fw: $(BUILDDIR)/$(BASENAME).ihx
+       $(OBJCOPY) -Iihex $< -Obinary $@
 
+include $(FX2LIBDIR)/lib/fx2.mk