From 42273a1b62d9653bbbeaff5c7646117d8b55d78a Mon Sep 17 00:00:00 2001 From: cbdev Date: Thu, 1 Mar 2018 17:51:48 +0100 Subject: Rename makefile --- Makefile | 36 ++++++++++++++++++++++++++++++++++++ makefile | 36 ------------------------------------ 2 files changed, 36 insertions(+), 36 deletions(-) create mode 100644 Makefile delete mode 100644 makefile diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..5f403ac --- /dev/null +++ b/Makefile @@ -0,0 +1,36 @@ +.PHONY: all clean run sanitize +BACKENDS = artnet.so midi.so osc.so loopback.so evdev.so sacn.so +OBJS = config.o backend.o plugin.o +PLUGINDIR = "\"./\"" + +CFLAGS ?= -g -Wall +#CFLAGS += -DDEBUG +%.so: CFLAGS += -fPIC +%.so: LDFLAGS += -shared + +midimonster: LDLIBS = -ldl +midimonster: CFLAGS += -DPLUGINS=$(PLUGINDIR) +midimonster: LDFLAGS += -Wl,-export-dynamic +midi.so: LDLIBS = -lasound +evdev.so: CFLAGS += $(shell pkg-config --cflags libevdev) +evdev.so: LDLIBS = $(shell pkg-config --libs libevdev) + + +%.so :: %.c %.h + $(CC) $(CFLAGS) $(LDLIBS) $< -o $@ $(LDFLAGS) + +all: midimonster $(BACKENDS) + +midimonster: midimonster.c $(OBJS) + +clean: + $(RM) midimonster + $(RM) $(OBJS) + $(RM) $(BACKENDS) + +run: + valgrind --leak-check=full --show-leak-kinds=all ./midimonster + +sanitize: CC = clang +sanitize: CFLAGS = -g -Wall -Wpedantic -fsanitize=address -fsanitize=undefined -fno-omit-frame-pointer +sanitize: midimonster $(BACKENDS) diff --git a/makefile b/makefile deleted file mode 100644 index 5f403ac..0000000 --- a/makefile +++ /dev/null @@ -1,36 +0,0 @@ -.PHONY: all clean run sanitize -BACKENDS = artnet.so midi.so osc.so loopback.so evdev.so sacn.so -OBJS = config.o backend.o plugin.o -PLUGINDIR = "\"./\"" - -CFLAGS ?= -g -Wall -#CFLAGS += -DDEBUG -%.so: CFLAGS += -fPIC -%.so: LDFLAGS += -shared - -midimonster: LDLIBS = -ldl -midimonster: CFLAGS += -DPLUGINS=$(PLUGINDIR) -midimonster: LDFLAGS += -Wl,-export-dynamic -midi.so: LDLIBS = -lasound -evdev.so: CFLAGS += $(shell pkg-config --cflags libevdev) -evdev.so: LDLIBS = $(shell pkg-config --libs libevdev) - - -%.so :: %.c %.h - $(CC) $(CFLAGS) $(LDLIBS) $< -o $@ $(LDFLAGS) - -all: midimonster $(BACKENDS) - -midimonster: midimonster.c $(OBJS) - -clean: - $(RM) midimonster - $(RM) $(OBJS) - $(RM) $(BACKENDS) - -run: - valgrind --leak-check=full --show-leak-kinds=all ./midimonster - -sanitize: CC = clang -sanitize: CFLAGS = -g -Wall -Wpedantic -fsanitize=address -fsanitize=undefined -fno-omit-frame-pointer -sanitize: midimonster $(BACKENDS) -- cgit v1.2.3