forked from AmigaLabs/clib4
-
Notifications
You must be signed in to change notification settings - Fork 0
/
libamiga.gmk
executable file
·70 lines (59 loc) · 1.54 KB
/
libamiga.gmk
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
#
# $Id: libamiga.gmk,v 1.1 2006-09-17 17:37:27 clib4devs Exp $
#
OUT_STATIC := $(BUILD_DIR)/obj/libamiga
OUT_SHARED := $(BUILD_DIR)/obj.shared/libamiga
ifeq ($(SHARED),yes)
LIBS += $(OUTPUT_LIB)/libamiga.so
endif
ifeq ($(STATIC),yes)
LIBS += $(OUTPUT_LIB)/libamiga.a
endif
AMIGA_LIB = \
amiga/amiga.lib_rev.o \
amiga/acrypt.o \
amiga/addtof.o \
amiga/argarraydone.o \
amiga/argarrayinit.o \
amiga/argint.o \
amiga/argstring.o \
amiga/beginio.o \
amiga/createextio.o \
amiga/createport.o \
amiga/createstdio.o \
amiga/createtask.o \
amiga/deleteextio.o \
amiga/deleteport.o \
amiga/deletestdio.o \
amiga/deletetask.o \
amiga/dotimer.o \
amiga/fastrand.o \
amiga/freeievents.o \
amiga/hotkey.o \
amiga/invertstring.o \
amiga/newlist.o \
amiga/rangerand.o \
amiga/remtof.o \
amiga/rexxvars.o \
amiga/timedelay.o \
amiga/waitbeam.o
SOURCES_SHARED = $(addprefix $(OUT_SHARED)/, $(AMIGA_LIB))
SOURCES_STATIC = $(addprefix $(OUT_STATIC)/, $(AMIGA_LIB))
# Dependencies to rebuild if the library version changes
$(OUT_STATIC)/%.o : CFLAGS += $(LARGEDATA)
$(OUT_SHARED)/%.o : CFLAGS += $(PIC) $(LARGEDATA)
ifdef SPE
$(OUT_STATIC)/%.o : $(LIB_DIR)/%.c
$(VERBOSE)$(COMPILE_SPE)
$(OUT_SHARED)/%.o : $(LIB_DIR)/%.c
$(VERBOSE)$(COMPILE_SHARED_SPE)
else
$(OUT_STATIC)/%.o : $(LIB_DIR)/%.c
$(VERBOSE)$(COMPILE)
$(OUT_SHARED)/%.o : $(LIB_DIR)/%.c
$(VERBOSE)$(COMPILE_SHARED)
endif
$(OUTPUT_LIB)/libamiga.a : $(SOURCES_STATIC)
$(VERBOSE)$(MAKELIB)
$(OUTPUT_LIB)/libamiga.so : $(OUTPUT_LIB)/libc.so $(SOURCES_SHARED)
$(VERBOSE)$(MAKESHARED)