
ifeq ($(top_srcdir),)
top_srcdir = ../
endif

ifeq ($(top_blddir),)
top_blddir = ../../
endif

ifeq ($(top_appdir),)
top_appdir = ../
endif

LIBDIR = ../efsl/

MCU=atmega128

include $(top_srcdir)/Makedefs.avr-gcc

TARG      = $(PROJ).hex
ITARG     = $(PROJ).bin

BIN       = $(TRGT)objcopy

BINDIR    = $(top_srcdir)/bin/$(MCU)

CPFLAGS   = $(MCFLAGS) -I. -Os -g -Wall $(DEFS)
LDFLAGS   = $(MCFLAGS) -L$(LIBDIR) 

ELFCOF    = $(BIN) --debugging \
	--change-section-address .data-0x800000 \
	--change-section-address .bss-0x800000 \
	--change-section-address .noinit-0x800000 \
	--change-section-address .eeprom-0x810000
