2002-12-20 20:59:11 +00:00
|
|
|
#
|
|
|
|
# Makefile for the joystick library
|
|
|
|
#
|
|
|
|
|
|
|
|
.SUFFIXES: .o .s .c
|
|
|
|
|
2004-10-26 19:28:26 +00:00
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Programs and flags
|
|
|
|
|
|
|
|
SYS = none
|
|
|
|
|
|
|
|
AS = ../../src/ca65/ca65
|
|
|
|
CC = ../../src/cc65/cc65
|
|
|
|
LD = ../../src/ld65/ld65
|
|
|
|
|
|
|
|
AFLAGS = -t $(SYS) -I../../asminc
|
|
|
|
CFLAGS = -Osir -g -T -t $(SYS) --forget-inc-paths -I . -I ../../include
|
|
|
|
|
2003-02-06 15:35:30 +00:00
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Rules
|
|
|
|
|
2002-12-20 20:59:11 +00:00
|
|
|
%.o: %.c
|
|
|
|
@$(CC) $(CFLAGS) $<
|
|
|
|
@$(AS) -g -o $@ $(AFLAGS) $(*).s
|
|
|
|
|
|
|
|
%.o: %.s
|
|
|
|
@$(AS) -g -o $@ $(AFLAGS) $<
|
|
|
|
|
2003-02-06 15:35:30 +00:00
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Object files
|
|
|
|
|
2006-06-05 16:59:29 +00:00
|
|
|
C_OBJS =
|
2002-12-20 20:59:11 +00:00
|
|
|
|
|
|
|
S_OBJS = joy-kernel.o \
|
|
|
|
joy_read.o \
|
|
|
|
joy_count.o \
|
2006-06-05 16:59:29 +00:00
|
|
|
joy_load.o \
|
2002-12-20 20:59:11 +00:00
|
|
|
joy_unload.o
|
|
|
|
|
2003-02-06 15:35:30 +00:00
|
|
|
#--------------------------------------------------------------------------
|
|
|
|
# Targets
|
|
|
|
|
|
|
|
.PHONY: all clean zap
|
2002-12-20 20:59:11 +00:00
|
|
|
|
|
|
|
all: $(C_OBJS) $(S_OBJS)
|
|
|
|
|
|
|
|
clean:
|
2004-10-26 19:28:26 +00:00
|
|
|
@$(RM) *~ $(C_OBJS:.o=.s) $(C_OBJS) $(S_OBJS)
|
2002-12-20 20:59:11 +00:00
|
|
|
|
2003-02-06 15:35:30 +00:00
|
|
|
zap: clean
|
|
|
|
|
2002-12-20 20:59:11 +00:00
|
|
|
|