Advertisement
z-nexx

Untitled

May 18th, 2015
483
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Make 0.43 KB | None | 0 0
  1. SHELL=/bin/sh
  2. XC16PATH=/opt/microchip/xc16/v1.24
  3. ASM=$(XC16PATH)/bin/xc16-as
  4. ASMFLAGS=-omf=elf -p24FJ256DA206
  5. LD=$(XC16PATH)/bin/xc16-ld
  6. LDFLAGS=-T $(XC16PATH)/support/PIC24F/gld/p24FJ256DA206.gld
  7. BIN2HEX=$(XC16PATH)/bin/xc16-bin2hex
  8. BIN2HEXFLAGS=
  9. SRC=main.s
  10.  
  11. $(notdir $(shell pwd)): $(SRC)
  12.     $(ASM) $(ASMFLAGS) -o $@.elf $^
  13.     $(LD) $(LDFLAGS) -o $@.bin $@.elf
  14.     $(BIN2HEX) $(BIN2HEXFLAGS) $@.bin
  15.  
  16. clean:
  17.     rm -rf *.elf *.hex
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement