-
Notifications
You must be signed in to change notification settings - Fork 3
/
MakefilePS2.txt
136 lines (117 loc) · 7.7 KB
/
MakefilePS2.txt
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
DIR_COMMON = ./common
DIR_PLATFORM = $(DIR_COMMON)/WindowsAPI
DIR_HPS1X64 = ./hps1x64/src
DIR_HPS2X64 = ./hps2x64/src
INC_COMMON = -I$(DIR_COMMON) -I$(DIR_COMMON)/StringUtilities -I$(DIR_COMMON)/breakpoint/src -I$(DIR_COMMON)/debug/src -I$(DIR_COMMON)/DiskImage/cd/src -I$(DIR_COMMON)/x64Encoder/src/ -I$(DIR_COMMON)/config/src/
INC_PLATFORM = -I$(DIR_HPS2X64)/hps2x64/src/ -I$(DIR_PLATFORM)/GUIHandler/src/ -I$(DIR_PLATFORM)/WinFile/src/ -I$(DIR_PLATFORM)/DebugValueList/src/ -I$(DIR_PLATFORM)/DisassemblyViewer/src/ -I$(DIR_PLATFORM)/InputBox/src/ -I$(DIR_PLATFORM)/DebugMemoryViewer/src/ -I$(DIR_PLATFORM)/BreakpointWindow/src/ -I$(DIR_PLATFORM)/Joystick/src/
DIR_PS1 = $(DIR_HPS1X64)
DIR_PS1_R3000A = $(DIR_PS1)/r3000a/src
DIR_PS1_CD = $(DIR_PS1)/cd/src
DIR_PS1_GPU = $(DIR_PS1)/gpu/src
DIR_PS1_DMA = $(DIR_PS1)/dma/src
DIR_PS1_INTC = $(DIR_PS1)/intc/src
DIR_PS1_MDEC = $(DIR_PS1)/mdec/src
DIR_PS1_SPU = $(DIR_PS1)/spu/src
DIR_PS1_SIO = $(DIR_PS1)/sio/src
DIR_PS1_PIO = $(DIR_PS1)/pio/src
DIR_PS1_TIMER = $(DIR_PS1)/timer/src
DIR_PS1_CDVD = $(DIR_PS1)/cdvd/src
DIR_PS1_SPU2 = $(DIR_PS1)/spu/src/spu2
DIR_PS1_USB = $(DIR_PS1)/usb/src
DIR_PS1_BUS = $(DIR_PS1)/databus/src
DIR_PS1_SYSTEM = $(DIR_PS1)/system/src
INC_PS1_R3000A = -I$(DIR_PS1_R3000A) -I$(DIR_PS1_R3000A)/execute -I$(DIR_PS1_R3000A)/lookup -I$(DIR_PS1_R3000A)/print -I$(DIR_PS1_R3000A)/COP2 -I$(DIR_PS1_R3000A)/recompile -I$(DIR_PS1_R3000A)/cache
INC_PS1_CD = -I$(DIR_PS1_CD)
INC_PS1_GPU = -I$(DIR_PS1_GPU)
INC_PS1_DMA = -I$(DIR_PS1_DMA)
INC_PS1_INTC = -I$(DIR_PS1_INTC)
INC_PS1_MDEC = -I$(DIR_PS1_MDEC)
INC_PS1_SPU = -I$(DIR_PS1_SPU)
INC_PS1_SIO = -I$(DIR_PS1_SIO)
INC_PS1_PIO = -I$(DIR_PS1_PIO)
INC_PS1_TIMER = -I$(DIR_PS1_TIMER)
INC_PS1_CDVD = -I$(DIR_PS1_CDVD)
INC_PS1_SPU2 = -I$(DIR_PS1_SPU2)
INC_PS1_USB = -I$(DIR_PS1_USB)
INC_PS1_BUS = -I$(DIR_PS1_BUS)
INC_PS1_SYSTEM = -I$(DIR_PS1_SYSTEM)
INC_PS1 = $(INC_PS1_R3000A) $(INC_PS1_CD) $(INC_PS1_GPU) $(INC_PS1_DMA) $(INC_PS1_INTC) $(INC_PS1_MDEC) $(INC_PS1_SPU) $(INC_PS1_SIO) $(INC_PS1_PIO) $(INC_PS1_TIMER) $(INC_PS1_CDVD) $(INC_PS1_SPU2) $(INC_PS1_USB) $(INC_PS1_BUS) $(INC_PS1_SYSTEM)
DIR_PS2 = $(DIR_HPS2X64)
DIR_PS2_R5900 = $(DIR_PS2)/r5900/src
DIR_PS2_GPU = $(DIR_PS2)/gpu/src
DIR_PS2_TIMER = $(DIR_PS2)/timer/src
DIR_PS2_SIO = $(DIR_PS2)/sio/src
DIR_PS2_INTC = $(DIR_PS2)/intc/src
DIR_PS2_DMA = $(DIR_PS2)/dma/src
DIR_PS2_SIF = $(DIR_PS2)/sif/src
DIR_PS2_VU = $(DIR_PS2)/vu/src
DIR_PS2_IPU = $(DIR_PS2)/ipu/src
DIR_PS2_BUS = $(DIR_PS2)/databus/src
DIR_PS2_SYSTEM = $(DIR_PS2)/system/src
INC_PS2_R5900 = -I$(DIR_PS2_R5900) -I$(DIR_PS2_R5900)/execute -I$(DIR_PS2_R5900)/lookup -I$(DIR_PS2_R5900)/print -I$(DIR_PS2_R5900)/recompile -I$(DIR_PS2_R5900)/cache
INC_PS2_GPU = -I$(DIR_PS2_GPU)
INC_PS2_TIMER = -I$(DIR_PS2_TIMER)
INC_PS2_SIO = -I$(DIR_PS2_SIO)
INC_PS2_INTC = -I$(DIR_PS2_INTC)
INC_PS2_DMA = -I$(DIR_PS2_DMA)
INC_PS2_SIF = -I$(DIR_PS2_SIF)
INC_PS2_VU = -I$(DIR_PS2_VU) -I$(DIR_PS2_VU)/execute -I$(DIR_PS2_VU)/lookup -I$(DIR_PS2_VU)/print -I$(DIR_PS2_VU)/recompile
INC_PS2_IPU = -I$(DIR_PS2_IPU) -I$(DIR_PS2_IPU)/mpeg2lib
INC_PS2_BUS = -I$(DIR_PS2_BUS)
INC_PS2_SYSTEM = -I$(DIR_PS2_SYSTEM)
INC_PS2 = $(INC_PS2_R5900) $(INC_PS2_GPU) $(INC_PS2_TIMER) $(INC_PS2_SIO) $(INC_PS2_INTC) $(INC_PS2_DMA) $(INC_PS2_SIF) $(INC_PS2_VU) $(INC_PS2_IPU) $(INC_PS2_BUS) $(INC_PS2_SYSTEM)
SRC_PLATFORM = $(wildcard $(DIR_HPS2X64)/hps2x64/src/*.cpp) $(wildcard $(DIR_PLATFORM)/GUIHandler/src/*.cpp) $(wildcard $(DIR_PLATFORM)/WinFile/src/*.cpp) $(wildcard $(DIR_PLATFORM)/DisassemblyViewer/src/*.cpp) $(wildcard $(DIR_PLATFORM)/InputBox/src/*.cpp) $(wildcard $(DIR_PLATFORM)/DebugMemoryViewer/src/*.cpp) $(wildcard $(DIR_PLATFORM)/BreakpointWindow/src/*.cpp) $(wildcard $(DIR_PLATFORM)/Joystick/src/*.cpp)
SRC_COMMON = $(wildcard $(DIR_COMMON)/StringUtilities/*.cpp) $(wildcard $(DIR_COMMON)/breakpoint/src/*.cpp) $(wildcard $(DIR_COMMON)/debug/src/*.cpp) $(wildcard $(DIR_COMMON)/DiskImage/cd/src/*.cpp) $(wildcard $(DIR_COMMON)/x64Encoder/src/*.cpp) $(wildcard $(DIR_COMMON)/config/src/*.cpp)
SRC_PS1_R3000A = $(wildcard $(DIR_PS1_R3000A)/*.cpp) $(wildcard $(DIR_PS1_R3000A)/execute/*.cpp) $(wildcard $(DIR_PS1_R3000A)/lookup/*.cpp) $(wildcard $(DIR_PS1_R3000A)/print/*.cpp) $(wildcard $(DIR_PS1_R3000A)/COP2/*.cpp) $(wildcard $(DIR_PS1_R3000A)/recompile/*.cpp)
SRC_PS1_CD = $(wildcard $(DIR_PS1_CD)/*.cpp)
SRC_PS1_GPU = $(wildcard $(DIR_PS1_GPU)/*.cpp)
SRC_PS1_DMA = $(wildcard $(DIR_PS1_DMA)/*.cpp)
SRC_PS1_INTC = $(wildcard $(DIR_PS1_INTC)/*.cpp)
SRC_PS1_MDEC = $(wildcard $(DIR_PS1_MDEC)/*.cpp)
SRC_PS1_SPU = $(wildcard $(DIR_PS1_SPU)/*.cpp)
SRC_PS1_SIO = $(wildcard $(DIR_PS1_SIO)/*.cpp)
SRC_PS1_PIO = $(wildcard $(DIR_PS1_PIO)/*.cpp)
SRC_PS1_TIMER = $(wildcard $(DIR_PS1_TIMER)/*.cpp)
SRC_PS1_CDVD = $(wildcard $(DIR_PS1_CDVD)/*.cpp)
SRC_PS1_SPU2 = $(wildcard $(DIR_PS1_SPU2)/*.cpp)
SRC_PS1_USB = $(wildcard $(DIR_PS1_USB)/*.cpp)
SRC_PS1_BUS = $(wildcard $(DIR_PS1_BUS)/*.cpp)
SRC_PS1_SYSTEM = $(wildcard $(DIR_PS1_SYSTEM)/*.cpp)
SRC_PS1 = $(SRC_PS1_R3000A) $(SRC_PS1_CD) $(SRC_PS1_GPU) $(SRC_PS1_DMA) $(SRC_PS1_INTC) $(SRC_PS1_MDEC) $(SRC_PS1_SPU) $(SRC_PS1_SIO) $(SRC_PS1_PIO) $(SRC_PS1_TIMER) $(SRC_PS1_CDVD) $(SRC_PS1_SPU2) $(SRC_PS1_USB) $(SRC_PS1_BUS) $(SRC_PS1_SYSTEM)
SRC_PS2_R5900 = $(wildcard $(DIR_PS2_R5900)/*.cpp) $(wildcard $(DIR_PS2_R5900)/execute/*.cpp) $(wildcard $(DIR_PS2_R5900)/lookup/*.cpp) $(wildcard $(DIR_PS2_R5900)/print/*.cpp) $(wildcard $(DIR_PS2_R5900)/recompile/*.cpp)
SRC_PS2_GPU = $(wildcard $(DIR_PS2_GPU)/*.cpp)
SRC_PS2_TIMER = $(wildcard $(DIR_PS2_TIMER)/*.cpp)
SRC_PS2_SIO = $(wildcard $(DIR_PS2_SIO)/*.cpp)
SRC_PS2_INTC = $(wildcard $(DIR_PS2_INTC)/*.cpp)
SRC_PS2_DMA = $(wildcard $(DIR_PS2_DMA)/*.cpp)
SRC_PS2_SIF = $(wildcard $(DIR_PS2_SIF)/*.cpp)
SRC_PS2_VU = $(wildcard $(DIR_PS2_VU)/*.cpp) $(wildcard $(DIR_PS2_VU)/execute/*.cpp) $(wildcard $(DIR_PS2_VU)/lookup/*.cpp) $(wildcard $(DIR_PS2_VU)/print/*.cpp) $(wildcard $(DIR_PS2_VU)/recompile/*.cpp)
SRC_PS2_IPU = $(wildcard $(DIR_PS2_IPU)/*.cpp)
SRC_PS2_BUS = $(wildcard $(DIR_PS2_BUS)/*.cpp)
SRC_PS2_SYSTEM = $(wildcard $(DIR_PS2_SYSTEM)/*.cpp)
SRC_PS2 = $(SRC_PS2_R5900) $(SRC_PS2_GPU) $(SRC_PS2_TIMER) $(SRC_PS2_SIO) $(SRC_PS2_INTC) $(SRC_PS2_DMA) $(SRC_PS2_SIF) $(SRC_PS2_VU) $(SRC_PS2_IPU) $(SRC_PS2_BUS) $(SRC_PS2_SYSTEM)
SRC_MPEGLIB = $(wildcard $(DIR_PS2_IPU)/mpeg2lib/*.cpp)
SRC_MPEGLIB1 = $(wildcard $(DIR_PS2_IPU)/mpeg2lib/Idct.cpp)
SRC_MPEGLIB2 = $(wildcard $(DIR_PS2_IPU)/mpeg2lib/Mpeg.cpp)
INC = $(INC_PS2) $(INC_COMMON) $(INC_PLATFORM) $(INC_PS1)
SRC = $(SRC_PS2) $(SRC_COMMON) $(SRC_PLATFORM) $(SRC_PS1)
LIBS = -Wl,-subsystem,console -lglew32 -lopengl32 -lglu32 -lgdi32 -lComctl32 -lwinmm -ldinput8 -ldxguid
CFLAGS = -w -Wreturn-type -Wuninitialized -Wmaybe-uninitialized -mwindows -msse4.2 -static -static-libgcc -static-libstdc++ -DGLEW_STATIC -O3 -DENABLE_GUI_DEBUGGER -DPS2_COMPILE -DUSE_PS2_GPU_TEMPLATES
#CFLAGS = -w -mwindows -mavx2 -fpermissive -static-libgcc -static-libstdc++ -O3 -DENABLE_GUI_DEBUGGER -DPS2_COMPILE -DUSE_PS2_GPU_TEMPLATES
#CFLAGS = -w -Wreturn-type -g -mwindows -msse4.2 -static -static-libgcc -static-libstdc++ -DGLEW_STATIC -DENABLE_GUI_DEBUGGER -DPS2_COMPILE -DUSE_PS2_GPU_TEMPLATES
#CFLAGS = -w -mwindows -mavx2 -O3 -fno-tree-vectorize -fpermissive -static-libgcc -static-libstdc++ -DENABLE_GUI_DEBUGGER -DPS2_COMPILE -DUSE_PS2_GPU_TEMPLATES
#CFLAGS2 = -w -mwindows -fpermissive -static -static-libgcc -static-libstdc++ -O2 -DENABLE_GUI_DEBUGGER -DPS2_COMPILE -DUSE_PS2_GPU_TEMPLATES -msse4.1
#-Wuninitialized
#-Wmaybe-uninitialized
#-Wl,--stack,33554432
MPEGOBJ1 = Idct.o
MPEGOBJ2 = Mpeg.o
OBJ = hps2x64
$(OBJ): $(SRC) $(SRC_MPEGLIB1) $(SRC_MPEGLIB2)
g++ $(CFLAGS) $(INC) -o $@ $^ $(LIBS)
#$(OBJ): $(SRC) $(MPEGOBJ1) $(MPEGOBJ2)
# g++ $(CFLAGS) $(INC) -o $@ $^ $(LIBS)
#$(MPEGOBJ1): $(SRC_MPEGLIB1)
# g++ $(CFLAGS2) $(INC) -c $^ $(LIBS)
#$(MPEGOBJ2): $(SRC_MPEGLIB2)
# g++ $(CFLAGS2) $(INC) -c $^ $(LIBS)