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
|
# $Header: Exp $
include $(PS2SDK)/Defs.make
PS2_EXTRA = /home/tony/GSOC/ps2/sdk-extra
PS2_EXTRA_INCS = /zlib/include /libmad/ee/include /SjPcm/ee/src /tremor
PS2_EXTRA_LIBS = /zlib/lib /libmad/ee/lib /SjPcm/ee/lib /tremor/tremor
# Set to 1 to enable, 0 to disable dynamic modules
DYNAMIC_MODULES = 1
# Set to 1 to enable, 0 to disable more detailed printing of gcc commands
VERBOSE_BUILD=0
# Test for dynamic plugins
ifeq ($(DYNAMIC_MODULES),1)
ENABLED = DYNAMIC_PLUGIN
DEFINES = -DDYNAMIC_MODULES
PRE_OBJS_FLAGS = -Wl,--whole-archive
POST_OBJS_FLAGS = -Wl,--no-whole-archive
else
ENABLED = STATIC_PLUGIN
endif
#control build
DISABLE_SCALERS = true
DISABLE_HQ_SCALERS = true
ENABLE_SCUMM = $(ENABLED)
ENABLE_SCUMM_7_8 = $(ENABLED)
ENABLE_HE = $(ENABLED)
ENABLE_AGI = $(ENABLED)
ENABLE_AGOS = $(ENABLED)
ENABLE_AGOS2 = $(ENABLED)
ENABLE_CINE = $(ENABLED)
ENABLE_CRUISE = $(ENABLED)
ENABLE_DRACI = $(ENABLED)
ENABLE_DRASCULA = $(ENABLED)
ENABLE_GOB = $(ENABLED)
ENABLE_GROOVIE = $(ENABLED)
# ENABLE_GROOVIE2 = $(ENABLED)
ENABLE_IHNM = $(ENABLED)
ENABLE_KYRA = $(ENABLED)
# ENABLE_LOL = $(ENABLED)
ENABLE_LURE = $(ENABLED)
# ENABLE_M4 = $(ENABLED)
ENABLE_MADE = $(ENABLED)
ENABLE_PARALLACTION = $(ENABLED)
ENABLE_QUEEN = $(ENABLED)
ENABLE_SAGA = $(ENABLED)
ENABLE_SAGA2 = $(ENABLED)
ENABLE_SCI = $(ENABLED)
# ENABLE_SCI32 = $(ENABLED)
ENABLE_SKY = $(ENABLED)
ENABLE_SWORD1 = $(ENABLED)
ENABLE_SWORD2 = $(ENABLED)
ENABLE_TEENAGENT = $(ENABLED)
ENABLE_TINSEL = $(ENABLED)
ENABLE_TOUCHE = $(ENABLED)
ENABLE_TUCKER = $(ENABLED)
HAVE_GCC3 = true
CC = ee-gcc
CXX = ee-g++
AS = ee-gcc
LD = ee-gcc
AR = ee-ar cru
RANLIB = ee-ranlib
STRIP = ee-strip
MKDIR = mkdir -p
RM = rm -f
RM_REC = rm -rf
MODULE_DIRS = ./
srcdir = ../../..
VPATH = $(srcdir)
INCDIR = ../../../
DEPDIR = .deps
TARGET = elf/scummvm.elf
DEFINES += -DUSE_VORBIS -DUSE_TREMOR -DUSE_MAD -DUSE_ZLIB -DFORCE_RTL -DDISABLE_SAVEGAME_SORTING -D_EE -D__PLAYSTATION2__ -G2 -O2 -Wall -Wno-multichar -fno-rtti -fno-exceptions -DNO_ADAPTOR
INCLUDES = $(addprefix -I$(PS2_EXTRA),$(PS2_EXTRA_INCS))
INCLUDES += -I $(PS2SDK)/ee/include -I $(PS2SDK)/common/include -I ./common -I . -I $(srcdir) -I $(srcdir)/engines
CXX_UPDATE_DEP_FLAG = -Wp,-MMD,"$(*D)/$(DEPDIR)/$(*F).d",-MQ,"$@",-MP
# Variables for dynamic plugin building
PLUGIN_PREFIX =
PLUGIN_SUFFIX = .plg
PLUGIN_EXTRA_DEPS = $(srcdir)/backends/plugins/plugin.syms elf/scummvm.elf
PLUGIN_LDFLAGS += -mno-crt0 $(PS2SDK)/ee/startup/crt0.o
PLUGIN_LDFLAGS += -nostartfiles -Wl,-q,--just-symbols,elf/scummvm.elf,-T$(srcdir)/backends/plugins/ps2/plugin.ld,--retain-symbols-file,$(srcdir)/backends/plugins/plugin.syms -lstdc++ -lc
LDFLAGS = -mno-crt0 $(PS2SDK)/ee/startup/crt0.o -T $(srcdir)/backends/plugins/ps2/main_prog.ld
LDFLAGS += -L $(PS2SDK)/ee/lib -L .
LDFLAGS += $(addprefix -L$(PS2_EXTRA),$(PS2_EXTRA_LIBS))
LDFLAGS += -lmc -lpad -lmouse -lhdd -lpoweroff -lsjpcm -lmad -ltremor -lz -lm -lc -lfileXio -lkernel -lstdc++
OBJS := $(srcdir)/backends/platform/ps2/DmaPipe.o \
$(srcdir)/backends/platform/ps2/Gs2dScreen.o \
$(srcdir)/backends/platform/ps2/irxboot.o \
$(srcdir)/backends/platform/ps2/ps2input.o \
$(srcdir)/backends/platform/ps2/ps2pad.o \
$(srcdir)/backends/platform/ps2/savefilemgr.o \
$(srcdir)/backends/platform/ps2/fileio.o \
$(srcdir)/backends/platform/ps2/asyncfio.o \
$(srcdir)/backends/platform/ps2/icon.o \
$(srcdir)/backends/platform/ps2/cd.o \
$(srcdir)/backends/platform/ps2/eecodyvdfs.o \
$(srcdir)/backends/platform/ps2/rpckbd.o \
$(srcdir)/backends/platform/ps2/systemps2.o \
$(srcdir)/backends/platform/ps2/ps2mutex.o \
$(srcdir)/backends/platform/ps2/ps2time.o \
$(srcdir)/backends/plugins/elf-loader.o \
$(srcdir)/backends/plugins/mips-relocs.o \
$(srcdir)/backends/plugins/shorts-segment-manager.o \
$(srcdir)/backends/platform/ps2/ps2debug.o
include $(srcdir)/Makefile.common
all: $(TARGET)
$(TARGET): $(OBJS)
$(LD) $(PRE_OBJS_FLAGS) $(OBJS) $(POST_OBJS_FLAGS) $(LDFLAGS) -o $@
|