From d69aef07c4606e66b2b5c6bc4a2a115c43ec58c7 Mon Sep 17 00:00:00 2001 From: Jasmin Jessich Date: Wed, 17 May 2017 01:41:24 +0200 Subject: Makefile enhancements - Speedup make by use of ":=" instead of "=". - Build "*.po" files only if a source file has been changed. - Make some targets PHONY. - Change subdir handling. - Build "*.po" and "*.mo" files only if it is required. - Install "*.mo" files and plugin "*.so" file only if they have been changed. --- javascript/Makefile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'javascript') diff --git a/javascript/Makefile b/javascript/Makefile index bca2426..08f0ad7 100644 --- a/javascript/Makefile +++ b/javascript/Makefile @@ -1,14 +1,15 @@ ### The official name of this plugin. -PLUGIN = live +PLUGIN := live ### Additional options to silence TNTNET warnings -TNTFLAGS ?= -Wno-overloaded-virtual -Wno-unused-function +TNTFLAGS ?= -Wno-overloaded-virtual -Wno-unused-function ### Includes and Defines (add further entries here): INCLUDES += -I$(VDRDIR)/include -I.. ### The object files (add further files here): -OBJS = treeview.o +OBJS := treeview.o +SRCS := $(patsubst %.o,%.cpp,$(OBJS)) ### The main target: all: libjavascript.a @@ -25,7 +26,7 @@ libjavascript.a: $(OBJS) $(AR) r $@ $^ clean: - @rm -f *~ *.o core* libjavascript.a $(OBJS:%.o=%.cpp) + @rm -f *~ *.o core* libjavascript.a $(SRCS) dist: clean @echo "Nothing to do for distribution here ..." -- cgit v1.2.3