blob: c4609c8481bcff91d49e5a292682f668b02b4029 (
plain)
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
|
include ../mk/build.mk
INCLUDE_PATH = ../include
HEADERS_SUBDIR = xas
CC = $(CROSS)cc
CFLAGS += -I$(INCLUDE_PATH)
LDFLAGS +=
HEADERS = audio.h riff.h mixer.h object.h synth.h vox.h bank.h \
spatial.h seq.h drone.h
OBJS = audio.o riff.o mixer.o object.o synth.o vox.o bank.o \
spatial.o seq.o drone.o
VERSION_MAJOR = 0
VERSION_MINOR = 0.1
VERSION = $(VERSION_MAJOR).$(VERSION_MINOR)
LIBNAME = xas
HEADERS_BUILD = $(addprefix $(INCLUDE_PATH)/$(HEADERS_SUBDIR)/, $(HEADERS))
all: $(STATIC) $(SONAME_FULL) $(SONAME) $(SONAME_SHORT)
$(STATIC): $(OBJS)
$(AR) rc $(STATIC) $(OBJS)
$(RANLIB) $(STATIC)
$(SONAME_FULL): $(OBJS)
$(CC) $(LDFLAGS_SO) -o $(SONAME_FULL) $(OBJS) $(LDFLAGS)
$(SONAME): $(SONAME_FULL)
$(LN) -s $< $@
$(SONAME_SHORT): $(SONAME_FULL)
$(LN) -s $< $@
$(OBJS): %.o: %.c $(HEADERS_BUILD)
$(CC) $(CFLAGS) -c $<
install: $(SONAME_FULL) $(STATIC)
$(INSTALL) -c -m 0644 $(STATIC) $(PREFIX)/lib
$(INSTALL) -c -m 0755 $(SONAME_FULL) $(PREFIX)/lib
$(LN) -s -f $(SONAME_FULL) $(PREFIX)/lib/$(SONAME)
$(LN) -s -f $(SONAME_FULL) $(PREFIX)/lib/$(SONAME_SHORT)
$(INSTALL) -d -m 0755 $(PREFIX)/include/$(HEADERS_SUBDIR)
$(INSTALL) -c -m 0644 $(HEADERS_BUILD) $(PREFIX)/include/$(HEADERS_SUBDIR)
clean:
$(RM) -f $(SONAME_SHORT) $(SONAME) $(SONAME_FULL) $(STATIC) $(OBJS)
|