forked from MrBollie/bbfpromix
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
66 lines (45 loc) · 1.95 KB
/
Copy pathMakefile
File metadata and controls
66 lines (45 loc) · 1.95 KB
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
#!/usr/bin/make -f
CFLAGS ?= `pkg-config alsa gtk+-3.0 --cflags`
LDFLAGS ?= `pkg-config alsa gtk+-3.0 --libs`
include Makefile.mk
# --------------------------------------------------------------
PREFIX ?= /usr/local
DESTDIR ?=
BUILDDIR ?= build
# --------------------------------------------------------------
# Default target is to build all plugins
all: bbfpromix
# --------------------------------------------------------------
# bolliedelay build rules
bbfpromix: $(BUILDDIR) $(BUILDDIR)/bbfpromix $(BUILDDIR)/bbfpromix.desktop
$(BUILDDIR)/channel.o: src/channel.c
$(CC) $^ $(BUILD_C_FLAGS) $(LINK_FLAGS) -lm -o $@ -c
$(BUILDDIR)/settings.o: src/settings.c
$(CC) $^ $(BUILD_C_FLAGS) $(LINK_FLAGS) -lm -o $@ -c
$(BUILDDIR)/main.o: src/main.c
$(CC) $^ $(BUILD_C_FLAGS) $(LINK_FLAGS) -lm -o $@ -c
$(BUILDDIR)/bbfpromix: $(BUILDDIR)/channel.o $(BUILDDIR)/settings.o $(BUILDDIR)/main.o
$(CC) $^ $(BUILD_C_FLAGS) $(LINK_FLAGS) -lm $(SHARED) -o $@
$(BUILDDIR)/bbfpromix.desktop: misc/bbfpromix.desktop
cp $< $@
$(BUILDDIR):
mkdir -p $(BUILDDIR)
# --------------------------------------------------------------
clean:
rm -f $(BUILDDIR)/*.o $(BUILDDIR)/bbfpromix*
# --------------------------------------------------------------
install: bbfpromix
echo "Install"
install -d $(DESTDIR)$(PREFIX)/bin
install -d $(DESTDIR)$(PREFIX)/share/applications
install -d $(DESTDIR)$(PREFIX)/share/icons
install -m 755 $(BUILDDIR)/bbfpromix $(DESTDIR)$(PREFIX)/bin/bbfpromix
install -m 644 ./misc/bbfpromix.svg $(DESTDIR)$(PREFIX)/share/icons/bbfpromix.svg
install -m 644 $(BUILDDIR)/bbfpromix.desktop $(DESTDIR)$(PREFIX)/share/applications/bbfpromix.desktop
# --------------------------------------------------------------
uninstall:
echo "Uninstall"
rm -f $(DESTDIR)$(PREFIX)/bin/bbfpromix
rm -f $(DESTDIR)$(PREFIX)/share/icons/bbfpromix.svg
rm -f $(DESTDIR)$(PREFIX)/share/applications/bbfpromix.desktop
# --------------------------------------------------------------