diff options
Diffstat (limited to 'makefile')
-rw-r--r-- | makefile | 22 |
1 files changed, 16 insertions, 6 deletions
@@ -1,16 +1,26 @@ -LDLIBS = -lasound -CFLAGS = -g -Wall +.PHONY: clean +BACKENDS = artnet.so midi.so osc.so +OBJS = config.o backend.o plugin.o +PLUGINDIR = "\"./\"" -BACKENDS = artnet.o midi.o osc.o -OBJS = config.o backend.o $(BACKENDS) +LDLIBS = -lasound -ldl +CFLAGS ?= -g -Wall -midimonster: midimonster.h $(OBJS) +midimonster: CFLAGS += -rdynamic -DPLUGINS=$(PLUGINDIR) +%.so: CFLAGS += -fPIC +%.so: LDFLAGS += -shared + +%.so :: %.c %.h + $(CC) $(CFLAGS) $< -o $@ $(LDFLAGS) -all: midimonster +all: midimonster $(BACKENDS) + +midimonster: midimonster.h $(OBJS) clean: $(RM) midimonster $(RM) $(OBJS) + $(RM) $(BACKENDS) run: valgrind --leak-check=full --show-leak-kinds=all ./midimonster |