-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcommon.mk
45 lines (34 loc) · 781 Bytes
/
common.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# Prefixes
COMPILER_PREFIX = /usr/local/
#COMPILER_PREFIX = $(SDCC_PREFIX)
#ARCH=z180
#ARCH=ez80_z80
ARCH=z80
COMPILER_LIBS = $(COMPILER_PREFIX)/share/sdcc/lib/$(ARCH)/
# Options
QUIET = @
# SDCC commands
CCC = $(COMPILER_PREFIX)/bin/sdcc
CAS = $(COMPILER_PREFIX)/bin/sdasz80
CLD = $(COMPILER_PREFIX)/bin/sdldz80
# Local CC
CC = gcc
# Misc local commands
ECHO = echo
COPY = cp
MOVE = mv
SED = sed
# Project directories
SRC_DIR = src/
CPM_SRC_DIR = $(SRC_DIR)/cpm
SYSLIB_SRC_DIR = $(SRC_DIR)/syslib
HWLIB_SRC_DIR = $(SRC_DIR)/hw
BIN_DIR = bin/
LSRC_DIR = lsrc/
LBIN_DIR = lbin/
ESRC_DIR = esrc/
INCLUDE_DIR = -I$(SRC_DIR)/include -I$(SRC_DIR)
# Compilation / Assembly / Linking flags
CCC_FLAGS = -c -m$(ARCH) -D__SDCC__=1 $(INCLUDE_DIR)
CAS_FLAGS = -plosff
CLD_FLAGS =