From 0e72a3efdb8fe18e58f6c574f544efead95ec662 Mon Sep 17 00:00:00 2001 From: makefu Date: Thu, 4 Aug 2011 00:36:12 +0200 Subject: streams/* updated Makefile/stream now in file Makefile: now creates symlinks to the krebs folder stream.db: streams are stored in a file --- streams/Makefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'streams/Makefile') diff --git a/streams/Makefile b/streams/Makefile index 9f3076c0..dcf1ca45 100644 --- a/streams/Makefile +++ b/streams/Makefile @@ -1,10 +1,13 @@ -INITD = /etc/init.d/ +#INITD = /etc/init.d/ +INITD = /etc/rc.d/ streams = groove deepmix radiotux +CURRDIR = ${PWD} .PHONY: all .PHONY: $(streams) all: $(streams) - update-rc.d groove defaults + @update-rc.d groove defaults 2>/dev/null || echo "** put groove daemon in DAEMONS in /etc/rc.conf" + $(streams): - cp $@ $(INITD)$@ + ln -n -s -f $$PWD/stream-starter $(INITD)$@ -- cgit v1.2.3 From 0ea4ef3b5b5bfde00abbe00eec4b05473cf7f36d Mon Sep 17 00:00:00 2001 From: makefu Date: Thu, 4 Aug 2011 01:11:10 +0200 Subject: streams/Makefile patched to be less stupid Makefile now has logic to find scripts to be installled and will not overwrite evevery script in your initd. --- streams/Makefile | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'streams/Makefile') diff --git a/streams/Makefile b/streams/Makefile index dcf1ca45..0922e38f 100644 --- a/streams/Makefile +++ b/streams/Makefile @@ -1,13 +1,11 @@ -#INITD = /etc/init.d/ -INITD = /etc/rc.d/ -streams = groove deepmix radiotux +INITD = $(shell test -e /etc/rc.d/ && echo /etc/rc.d/ || echo /etc/init.d/) +streams = $(shell cut -d\ -f2 stream.db) CURRDIR = ${PWD} -.PHONY: all -.PHONY: $(streams) +.PHONY: all $(streams) all: $(streams) @update-rc.d groove defaults 2>/dev/null || echo "** put groove daemon in DAEMONS in /etc/rc.conf" - $(streams): - ln -n -s -f $$PWD/stream-starter $(INITD)$@ + @test -L $(INITD)$@ || test ! -e $(INITD)$@ && \ + ln -n -s -f $$PWD/stream-starter $(INITD)$@ && echo "writing $@ to $(INITD)" -- cgit v1.2.3