-
Notifications
You must be signed in to change notification settings - Fork 2
/
makefile_amiga
73 lines (55 loc) · 1.22 KB
/
makefile_amiga
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
#
# Makefile for libikbd.a and associated test program
#
TOOLCHAIN_PREFIX=/opt/m68k-amigaos/bin/m68k-amigaos-
CC=$(TOOLCHAIN_PREFIX)gcc
AR=$(TOOLCHAIN_PREFIX)ar
ASM=/opt/m68k-amigaos/bin/vasmm68k_mot
UNAME := $(shell uname)
ifeq ($(UNAME),Linux)
PREFIX=m68k-amigaos
else
PREFIX=/opt/m68k-amigaos/bin/m68k-amigaos
endif
CFLAGS=-m68000\
-msoft-float\
-fomit-frame-pointer \
-fbbb=- \
-std=gnu99\
-DAMIGA \
-s \
-noixemul
#-O2\
#-mtune=68020-60
#
#-Wall\
#-mshort\
#-nostdlib
# -std=c99\
# -std=nix20
# -std=gnu99\
ASMFLAGS= -Fhunk\
-quiet\
-esc\
-DINTERLACE=0
ASFLAGS=$(CFLAGS)
ICARUS=icarus
APP=$(ICARUS).exe
LIB=ace/build/libace.a
all: $(LIB) $(APP)
INC = -Iace/include
OBJECTS=src/music_ptr_linkable.o
$(APP): src/main.c depend
$(ASM) $(ASMFLAGS) src/ptplayer.asm -o src/music_ptr_linkable.o -I/usr/local/amiga/os-include
$(CC) $(CFLAGS) src/main.c $(OBJECTS) $(INC) $(LIB) -o $(APP)
/opt/m68k-amigaos/bin/m68k-amigaos-strip $(APP)
#/opt/m68k-amigaos/bin/vlink $(OBJECTS) $(APP) -o icarus.exe
$(LIB):
$(CC) $(INC) $(LIB)
.PHONY clean:
- rm -rf *.o depend $(APP)
depend: $(CSOURCES) src/main.c
$(CC) $(CFLAGS) $(INC) -M $(CSOURCES) src/main.c > depend
ifneq (clean,$(MAKECMDGOALS))
-include depend
endif