From bc1f676317656a0f0b00d9c147c79d2248e61edb Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Wed, 25 Nov 2020 11:59:20 +0100 Subject: Makefile: change order of compiler parameters --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index b0124fa..f5cff76 100644 --- a/Makefile +++ b/Makefile @@ -33,7 +33,7 @@ VERSION := 0.8.5 all: mpd-notification README.html mpd-notification: mpd-notification.c mpd-notification.h config.h version.h - $(CC) $(CFLAGS) $(LDFLAGS) -o mpd-notification mpd-notification.c + $(CC) mpd-notification.c $(CFLAGS) $(LDFLAGS) -o mpd-notification config.h: $(CP) config.def.h config.h -- cgit v1.2.3 From a068a2decf5494b8766ec0b0dd52e99e82482e26 Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Fri, 1 Jan 2021 22:23:15 +0100 Subject: Makefile: allow to override CFLAGS... ... without loosing CFLAGS required for linked libraries. Closes #28 --- Makefile | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index f5cff76..842da60 100644 --- a/Makefile +++ b/Makefile @@ -8,21 +8,21 @@ CP := cp RM := rm # flags -CFLAGS += -std=c11 -O2 -fPIC -Wall -Werror +CFLAGS_EXTRA += -std=c11 -O2 -fPIC -Wall -Werror ifneq ($(wildcard /usr/include/iniparser),) -CFLAGS += -I/usr/include/iniparser +CFLAGS_EXTRA += -I/usr/include/iniparser endif -CFLAGS += -liniparser -CFLAGS_SYSTEMD := $(shell pkg-config --cflags --libs libsystemd 2>/dev/null) +CFLAGS_EXTRA += -liniparser +CFLAGS_SYSTEMD := $(shell pkg-config --cflags --libs libsystemd 2>/dev/null) ifneq ($(CFLAGS_SYSTEMD),) -CFLAGS += -DHAVE_SYSTEMD $(CFLAGS_SYSTEMD) +CFLAGS_EXTRA += -DHAVE_SYSTEMD $(CFLAGS_SYSTEMD) endif -CFLAGS += $(shell pkg-config --cflags --libs libmpdclient) -CFLAGS += $(shell pkg-config --cflags --libs libnotify) -CFLAGS_LIBAV := $(shell pkg-config --cflags --libs libavformat libavutil 2>/dev/null) +CFLAGS_EXTRA += $(shell pkg-config --cflags --libs libmpdclient) +CFLAGS_EXTRA += $(shell pkg-config --cflags --libs libnotify) +CFLAGS_LIBAV := $(shell pkg-config --cflags --libs libavformat libavutil 2>/dev/null) ifneq ($(CFLAGS_LIBAV),) -CFLAGS += -DHAVE_LIBAV $(CFLAGS_LIBAV) -CFLAGS += -lmagic +CFLAGS_EXTRA += -DHAVE_LIBAV $(CFLAGS_LIBAV) +CFLAGS_EXTRA += -lmagic endif LDFLAGS += -Wl,-z,now -Wl,-z,relro -pie @@ -33,7 +33,7 @@ VERSION := 0.8.5 all: mpd-notification README.html mpd-notification: mpd-notification.c mpd-notification.h config.h version.h - $(CC) mpd-notification.c $(CFLAGS) $(LDFLAGS) -o mpd-notification + $(CC) mpd-notification.c $(CFLAGS) $(CFLAGS_EXTRA) $(LDFLAGS) -o mpd-notification config.h: $(CP) config.def.h config.h -- cgit v1.2.3 From 3a472bba0c177a2fa5ebc5dc53cc6c52e94d472e Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Fri, 1 Jan 2021 22:41:29 +0100 Subject: prepare version 0.8.6 --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 842da60..becba93 100644 --- a/Makefile +++ b/Makefile @@ -28,7 +28,7 @@ LDFLAGS += -Wl,-z,now -Wl,-z,relro -pie # this is just a fallback in case you do not use git but downloaded # a release tarball... -VERSION := 0.8.5 +VERSION := 0.8.6 all: mpd-notification README.html -- cgit v1.2.3