forked from AloUltraExt/sm64ex-alo
-
Notifications
You must be signed in to change notification settings - Fork 2
/
defines.mk
208 lines (173 loc) · 4.53 KB
/
defines.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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
# --------------------------------------
# General Defines
# --------------------------------------
# Build debug version (1 simple debug compile, 2 max debug compile)
DEBUG ?= 0
# Enable extended options menu by default
EXT_OPTIONS_MENU ?= 1
# Enable debug options menu (Enabled if DEBUG is not 0)
EXT_DEBUG_MENU ?= 0
# Enable better camera (Puppycam 2)
BETTERCAMERA ?= 1
# Enable cheats
CHEATS_ACTIONS ?= 1
# Enable rumble functions (Originally in Shindou)
RUMBLE_FEEDBACK ?= 1
# Disable no drawing distance by default
NODRAWINGDISTANCE ?= 0
# Enable Goddard (Mario Face)
GODDARD_MFACE ?= 1
# Kaze MOP Objects Port, disabled by default
PORT_MOP_OBJS ?= 0
# Enable level vanilla checks
VANILLA_CHECKS ?= 1
# Enable extended bounds
EXTENDED_BOUNDS ?= 0
# Enable Mouse support
MOUSE_ACTIONS ?= 1
# Accept RM2C level folder output
RM2C ?= 0
# --------------------------------------
# General QoL Defines (see include/qol_defines.h)
# --------------------------------------
# Quality of life fixes
QOL_FIXES ?= 1
# Quality of life features
QOL_FEATURES ?= 1
# Quality of life redone files
QOL_REDONE ?= 1
# --------------------------------------
# Port Only Defines
# --------------------------------------
# Enable 60 fps interpolation
HIGH_FPS_PC ?= 0
# Disable text-based save-files by default
TEXTSAVES ?= 0
# Load resources from external files
EXTERNAL_DATA ?= 0
# Enable Discord Rich Presence
DISCORDRPC ?= 0
# Enable Command Line Options
COMMAND_LINE_OPTIONS ?= 1
# --------------------------------------
# Custom Defines
# --------------------------------------
CUSTOM_C_DEFINES :=
ifeq ($(TARGET_N64),0)
# Check for PC Port Defines
ifeq ($(PC_PORT_DEFINES),1)
CUSTOM_C_DEFINES += -DNO_SEGMENTED_MEMORY -DWIDESCREEN -DUSE_SYSTEM_MALLOC
endif
# Use Console exclusive defines
ifeq ($(TARGET_PORT_CONSOLE),1)
CUSTOM_C_DEFINES += -DTARGET_PORT_CONSOLE
endif
# Check for 60 fps interpolation
ifeq ($(HIGH_FPS_PC),1)
CUSTOM_C_DEFINES += -DHIGH_FPS_PC
endif
# Check for text save format
ifeq ($(TEXTSAVES),1)
CUSTOM_C_DEFINES += -DTEXTSAVES
endif
# Check for external data
ifeq ($(EXTERNAL_DATA),1)
CUSTOM_C_DEFINES += -DEXTERNAL_DATA
ifeq ($(TARGET_N64),1)
$(error External data is not usable on N64)
endif
endif
ifeq ($(WINDOW_API),SDL2)
# Check for touch controls
ifeq ($(TOUCH_CONTROLS),1)
CUSTOM_C_DEFINES += -DTOUCH_CONTROLS
endif
endif
# Use PC-only exclusive defines
ifeq ($(TARGET_PORT_CONSOLE),0)
# Check for Mouse Option
ifeq ($(MOUSE_ACTIONS),1)
CUSTOM_C_DEFINES += -DMOUSE_ACTIONS
endif
# Check for Discord Rich Presence option
ifeq ($(DISCORDRPC),1)
CUSTOM_C_DEFINES += -DDISCORDRPC
endif
# Check for Command Line Options
ifeq ($(COMMAND_LINE_OPTIONS),1)
CUSTOM_C_DEFINES += -DCOMMAND_LINE_OPTIONS
endif
endif # !TARGET_PORT_CONSOLE
endif # !TARGET_N64
# Check for Debug option
ifneq ($(DEBUG),0)
ifeq ($(DEBUG),1)
COMPILER_OPT := debug
endif
ifeq ($(DEBUG),2)
COMPILER_OPT := debugmax
endif
CUSTOM_C_DEFINES += -DDEBUG
EXT_DEBUG_MENU := 1
endif
# Check for Debug Menu option
ifeq ($(EXT_DEBUG_MENU),1)
CUSTOM_C_DEFINES += -DEXT_DEBUG_MENU
EXT_OPTIONS_MENU := 1
endif
# Check for Puppycam option
ifeq ($(BETTERCAMERA),1)
CUSTOM_C_DEFINES += -DBETTERCAMERA
EXT_OPTIONS_MENU := 1
endif
# Check for Cheats option
ifeq ($(CHEATS_ACTIONS),1)
CUSTOM_C_DEFINES += -DCHEATS_ACTIONS
EXT_OPTIONS_MENU := 1
endif
# Check for extended options menu option
ifeq ($(EXT_OPTIONS_MENU),1)
CUSTOM_C_DEFINES += -DEXT_OPTIONS_MENU
endif
# Check for Rumble option
ifeq ($(TARGET_N3DS)$(TARGET_WII_U),00)
ifeq ($(RUMBLE_FEEDBACK),1)
CUSTOM_C_DEFINES += -DRUMBLE_FEEDBACK
endif
endif
# Check for no drawing distance option
ifeq ($(NODRAWINGDISTANCE),1)
CUSTOM_C_DEFINES += -DNODRAWINGDISTANCE
endif
# Check for Goddard option
ifeq ($(GODDARD_MFACE),1)
CUSTOM_C_DEFINES += -DGODDARD_MFACE
endif
# Check for MOP option
ifeq ($(PORT_MOP_OBJS),1)
CUSTOM_C_DEFINES += -DPORT_MOP_OBJS
endif
# Check for Vanilla checks
ifeq ($(VANILLA_CHECKS),1)
CUSTOM_C_DEFINES += -DVANILLA_CHECKS
endif
# Check for Extended bounds
ifneq ($(EXTENDED_BOUNDS),0)
CUSTOM_C_DEFINES += -DEXTENDED_BOUNDS=$(EXTENDED_BOUNDS) -DCOLLISION_FIXES
endif
# Add RM2C to flags, add var for internal name
ifeq ($(RM2C),1)
CUSTOM_C_DEFINES += -DRM2C
endif
# Check for QoL fixes option
ifeq ($(QOL_FIXES),1)
CUSTOM_C_DEFINES += -DQOL_FIXES
endif
# Check for QoL features option
ifeq ($(QOL_FEATURES),1)
CUSTOM_C_DEFINES += -DQOL_FEATURES
endif
# Check for QoL features option
ifeq ($(QOL_REDONE),1)
CUSTOM_C_DEFINES += -DQOL_REDONE
endif