2 # Makefile for cross-compiler version of CC65.
7 # ------------------------------------------------------------------------------
9 # The executable to build
15 # The compiler library search path. Default is "/usr/lib/cc65/include/" if
17 #CDEFS=-DCC65_INC=\"/usr/lib/cc65/include/\"
20 CFLAGS = -O2 -g -Wall -W -I$(COMMON) $(CDEFS)
25 # ------------------------------------------------------------------------------
26 # Object files and libraries to link
93 LIBS = $(COMMON)/common.a
96 # ------------------------------------------------------------------------------
99 # Main target - must be first
101 ifeq (.depend,$(wildcard .depend))
106 @$(MAKE) -f make/gcc.mak all
109 $(EXE): $(OBJS) $(LIBS)
110 $(CC) $(LDFLAGS) -o $(EXE) $(CFLAGS) $(OBJS) $(LIBS)
111 @if [ $(OS2_SHELL) ] ; then $(EBIND) $(EXE) ; fi
117 $(RM) *.o $(EXE) .depend
119 # ------------------------------------------------------------------------------
120 # Make the dependencies
123 depend dep: $(OBJS:.o=.c)
124 @echo "Creating dependency information"
125 $(CC) -I$(COMMON) -MM $^ > .depend