Change the makefiles so that CFLAGS that are special for the application are

appended after assigning the base value to CFLAGS. This allows to change
CFLAGS on the command line without too much hassle.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4219 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
uz
2009-09-24 15:07:11 +00:00
parent c4d83d4cbf
commit b8e665e837
10 changed files with 66 additions and 26 deletions

View File

@@ -10,12 +10,17 @@ EXE = ar65
# Library dir # Library dir
COMMON = ../common COMMON = ../common
CFLAGS = -g -O2 -Wall -W -std=c89 -I$(COMMON) #
CC = gcc CC = gcc
CFLAGS = -g -O2 -Wall -W -std=c89
CFLAGS += -I$(COMMON)
EBIND = emxbind EBIND = emxbind
LDFLAGS = LDFLAGS =
# -----------------------------------------------------------------------------
# List of all object files
OBJS = add.o \ OBJS = add.o \
del.o \ del.o \
error.o \ error.o \

View File

@@ -13,10 +13,11 @@ COMMON = ../common
# Several search paths. You may redefine these on the command line # Several search paths. You may redefine these on the command line
CA65_INC = \"/usr/lib/cc65/asminc/\" CA65_INC = \"/usr/lib/cc65/asminc/\"
#
CC = gcc
CFLAGS = -g -O2 -Wall -W -std=c89 CFLAGS = -g -O2 -Wall -W -std=c89
CFLAGS += -I$(COMMON) CFLAGS += -I$(COMMON)
CFLAGS += -DCA65_INC=$(CA65_INC) CFLAGS += -DCA65_INC=$(CA65_INC)
CC = gcc
EBIND = emxbind EBIND = emxbind
LDFLAGS = LDFLAGS =

View File

@@ -18,10 +18,12 @@ COMMON = ../common
CC65_INC = \"/usr/lib/cc65/include/\" CC65_INC = \"/usr/lib/cc65/include/\"
# #
CFLAGS = -O2 -g -Wall -W -std=c89 -I$(COMMON) -DCC65_INC=$(CC65_INC) CC = gcc
CC=gcc CFLAGS = -O2 -g -Wall -W -std=c89
EBIND=emxbind CFLAGS += -I$(COMMON)
LDFLAGS=-lm CFLAGS += -DCC65_INC=$(CC65_INC)
EBIND = emxbind
LDFLAGS = -lm
# Determine the svn version number if possible # Determine the svn version number if possible
ifneq "$(shell which svnversion 2>/dev/null)" "" ifneq "$(shell which svnversion 2>/dev/null)" ""

View File

@@ -16,11 +16,13 @@ ifneq ($(Kickstart),)
SPAWN = SPAWN_AMIGA SPAWN = SPAWN_AMIGA
endif endif
#
CC=gcc CC = gcc
CFLAGS = -O2 -g -Wall -W -std=c89 -I$(COMMON) -D$(SPAWN) CFLAGS = -O2 -g -Wall -W -std=c89
EBIND = emxbind CFLAGS += -I$(COMMON)
LDFLAGS= CFLAGS += -D$(SPAWN)
EBIND = emxbind
LDFLAGS =
OBJS = error.o \ OBJS = error.o \
global.o \ global.o \

View File

@@ -10,11 +10,16 @@ EXE = co65
# Library dir # Library dir
COMMON = ../common COMMON = ../common
CFLAGS = -g -O2 -Wall -W -std=c89 -I$(COMMON) #
CC = gcc CC = gcc
CFLAGS = -g -O2 -Wall -W -std=c89
CFLAGS += -I$(COMMON)
EBIND = emxbind EBIND = emxbind
LDFLAGS = LDFLAGS =
# -----------------------------------------------------------------------------
# List of all object files
OBJS = convert.o \ OBJS = convert.o \
error.o \ error.o \
fileio.o \ fileio.o \

View File

@@ -10,10 +10,16 @@ EXE = da65
# Library dir # Library dir
COMMON = ../common COMMON = ../common
CFLAGS = -g -O2 -Wall -W -std=c89 -I$(COMMON) #
CC=gcc CC = gcc
EBIND=emxbind CFLAGS = -g -O2 -Wall -W -std=c89
LDFLAGS= CFLAGS += -I$(COMMON)
EBIND = emxbind
LDFLAGS =
# -----------------------------------------------------------------------------
# List of all object files
OBJS = asminc.o \ OBJS = asminc.o \
attrtab.o \ attrtab.o \

View File

@@ -9,11 +9,17 @@ EXE = grc
COMMON = ../common COMMON = ../common
CFLAGS = -g -O2 -Wall -W -std=c89 -I$(COMMON) #
CC = gcc CC = gcc
CFLAGS = -g -O2 -Wall -W -std=c89
CFLAGS += -I$(COMMON)
LDFLAGS = LDFLAGS =
EBIND = emxbind EBIND = emxbind
# -----------------------------------------------------------------------------
# List of all object files
OBJS = grc.o OBJS = grc.o
LIBS = $(COMMON)/common.a LIBS = $(COMMON)/common.a

View File

@@ -16,11 +16,12 @@ LD65_OBJ = \"/usr/lib/cc65/lib/\"
LD65_CFG = \"/usr/lib/cc65/cfg/\" LD65_CFG = \"/usr/lib/cc65/cfg/\"
# #
CFLAGS = -g -O2 -Wall -W -std=c89 -I$(COMMON) CC = gcc
CFLAGS = -g -O2 -Wall -W -std=c89
CFLAGS += -I$(COMMON)
CFLAGS += -DLD65_LIB=$(LD65_LIB) -DLD65_OBJ=$(LD65_OBJ) -DLD65_CFG=$(LD65_CFG) CFLAGS += -DLD65_LIB=$(LD65_LIB) -DLD65_OBJ=$(LD65_OBJ) -DLD65_CFG=$(LD65_CFG)
CC=gcc EBIND = emxbind
EBIND=emxbind LDFLAGS =
LDFLAGS=
# Perl script for config file conversion # Perl script for config file conversion
CVT=cfg/cvt-cfg.pl CVT=cfg/cvt-cfg.pl

View File

@@ -11,10 +11,16 @@ EXE = od65
# Library dir # Library dir
COMMON = ../common COMMON = ../common
CFLAGS = -O2 -g -Wall -W -std=c89 -I$(COMMON) #
CC=gcc CC = gcc
EBIND=emxbind CFLAGS = -O2 -g -Wall -W -std=c89
LDFLAGS= CFLAGS += -I$(COMMON)
EBIND = emxbind
LDFLAGS =
# -----------------------------------------------------------------------------
# List of all object files
OBJS = dump.o \ OBJS = dump.o \
error.o \ error.o \

View File

@@ -10,11 +10,17 @@ EXE = sim65
# Library dir # Library dir
COMMON = ../common COMMON = ../common
CFLAGS = -g -O2 -Wall -W -std=c89 -I$(COMMON) #
CC = gcc CC = gcc
CFLAGS = -g -O2 -Wall -W -std=c89
CFLAGS += -I$(COMMON)
EBIND = emxbind EBIND = emxbind
LDFLAGS = LDFLAGS =
# -----------------------------------------------------------------------------
# List of all object files
OBJS = addrspace.o \ OBJS = addrspace.o \
callback.o \ callback.o \
cfgdata.o \ cfgdata.o \