forked from multimediamike/dreamroq
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
executable file
·47 lines (36 loc) · 1.4 KB
/
Makefile
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
# Put the filename of the output binary here
TARGET = dreamroq-player.elf
PROJECT_NAME = dreamroq_ph3nom
DIR=$(PWD)
# List all of your C files here, but change the extension to ".o"
OBJS = dreamroq-player.o dreamroqlib.o
#AICA Audio Driver
KOS_CFLAGS += -I. -Ilibdcmc/
OBJS += libdcmc/snddrv.o
#PVR Video Driver
OBJS += libdcmc/pvrdrv.o
all: rm-elf $(TARGET)
include $(KOS_BASE)/Makefile.rules
clean:
-rm -f $(TARGET) $(OBJS)
rm-elf:
-rm -f $(TARGET)
# If you don't need a ROMDISK, then remove "romdisk.o" from the next few
# lines. Also change the -l arguments to include everything you need,
# such as -lmp3, etc.. these will need to go _before_ $(KOS_LIBS)
$(TARGET): $(OBJS)
$(KOS_CC) $(KOS_CFLAGS) $(KOS_LDFLAGS) -o $(TARGET) $(KOS_START) \
$(OBJS) $(OBJEXTRA) $(KOS_LIBS)
run: $(TARGET)
$(KOS_LOADER) $(TARGET)
cd: $(TARGET)
@sh-elf-objcopy -R .stack -O binary $(TARGET) output.bin
@$(KOS_BASE)/utils/scramble/scramble output.bin 1ST_READ.BIN
@mkisofs -C 0,11702 -V Reaperi_Cycle -G $(KOS_BASE)/IP.BIN -r -J -l -m '*.o' -o ../$(PROJECT_NAME).iso $(DIR)
@$(KOS_BASE)/utils/cdi4dc/cdi4dc ../$(PROJECT_NAME).iso ../$(PROJECT_NAME).cdi -d > cdi4dc.log
../redream ../$(PROJECT_NAME).cdi
#sudo arp -s 192.168.0.99 00:d0:f1:03:14:02
#sudo ../dc-tool-ip -t dreamcast -c ./ -x dreamroq-player.elf
dist:
rm -f $(OBJS) romdisk.o romdisk.img
$(KOS_STRIP) $(TARGET)