Debian Codegraph @

GNUmakefile

raw ◀ ▶
2 Debian patches touch this file
1 PLUGIN_NAME = vocoder
2
3 # These files go into the bundle
4 BUNDLE_FILES = manifest.ttl vocoder.ttl vocoder.so
5
•6 PKG_CONFIG ?= pkg-config
7 CFLAGS += -c -Wall -fPIC -DPIC $(strip $(shell $(PKG_CONFIG) --cflags lv2core))
8
9 GENDEP_SED_EXPR = "s/^\\(.*\\)\\.o *: /$(subst /,\/,$(@:.d=.o)) $(subst /,\/,$@) : /g"
10 GENDEP_C = set -e; $(GCC_PREFIX)gcc -MM $(CFLAGS) $< | sed $(GENDEP_SED_EXPR) > $@; [ -s $@ ] || rm -f $@
11
12 default: $(PLUGIN_NAME).lv2
13
14 %.o:%.c
15 @echo "Compiling $< to $@ ..."
16 @$(CC) $(CFLAGS) $< -o $@
17
18 %.d: %.c
19 @echo "Generating dependency for $< to $@ ..."
20 @$(GENDEP_C)
21
22 vocoder.so: vocoder.o
23 @echo "Creating LV2 shared library $@ ..."
•24 @$(CXX) -shared -fPIC $(LDFLAGS) $< -o $@
25
26 # The main target - the LV2 plugin bundle
27 $(PLUGIN_NAME).lv2: $(BUNDLE_FILES)
28 @echo "Creating LV2 bundle $@ ..."
29 @rm -rf $(PLUGIN_NAME).lv2
30 @mkdir $(PLUGIN_NAME).lv2
31 @cp $(BUNDLE_FILES) $(PLUGIN_NAME).lv2
32
33 clean:
34 rm -rf *.o vocoder.so $(PLUGIN_NAME).lv2
35
36 install: $(PLUGIN_NAME).lv2
37 @./install_lv2.sh $(PLUGIN_NAME).lv2