# ------------------------------------------ # Sample Makefile for RoBiOS Userprograms # by Thomas Braeunl & Thomas Lampart # ------------------------------------------ # this is where the cross compiler lives HOME = /user/res/uwarobot BIN = ${HOME}/gcc-m68k/lib/gcc-lib/m68k-coff/2.7.2/ #INC = ${HOME}/gcc-m68k/include INCC = ${HOME}/libc/include # this is where the latest libraries live MC = /user/res/uwarobot/mc INC1 = ${MC}/include # compiler names and flags CC = m68k-coff-gcc AS = m68k-coff-as LD = m68k-coff-ld OBJCOPY = m68k-coff-objcopy OPTIMZE = -O -g CPU = 68332 LFLAGS = -Map map -T${MC}/ldfiles/robi-ram.ld -L${MC}/lib CFLAGS = -B${BIN} -m${CPU} ${OPTIMZE} -I${INCC} -I${INC1} -ansi -pedantic -c -msoft-float AFLAGS = -m${CPU} ${HARD} # you have to adjust this for use with own programs # -------------------------------------------------- OBJS = walk.o gym.o PROG = walk # -------------------------------------------------- .s.o: ${AS} ${AFLAGS} -o $*.o $*.s .c.o: ${CC} ${CFLAGS} $*.c all: echocwd ${PROG} ${PROG}: ${OBJS} ${LD} ${LFLAGS} -o $@ ${OBJS} -limpro -lmym -lmyc -lmygcc -lrobi ${OBJCOPY} -O srec ${PROG} ${PROG}.hex clean: echocwd rm -f ${OBJS} ${PROG} ${PROG}.hex core map echocwd: @pwd