aboutsummaryrefslogtreecommitdiff
blob: 6930a0c64c7e4a4e61c4c4e068c982160c2fa569 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# $Id: $

SHELL = /bin/bash

SUBDIRS = etc usr vdrplugin-rebuild

SUBDIRS +=  usr/lib/systemd/system var/vdr/tmp etc/systemd/system/vdr.service.d

all:

VERSION := $(shell grep '^Version' README | awk '{ print $$2 }')
TMPDIR = /tmp
ARCHIVE = gentoo-vdr-scripts-$(VERSION)
PACKAGE = $(ARCHIVE).tar.bz2
GITREF ?= HEAD

dist:
	@git archive --prefix=$(ARCHIVE)/ $(GITREF) | bzip2 > $(PACKAGE)
	@echo Distribution package created as $(PACKAGE)

install:
	@for DIR in $(SUBDIRS); do \
		$(MAKE) -C $$DIR install; \
	done
	@install -m 0755 -o vdr -g vdr -d $(DESTDIR)/var/vdr/{shutdown-data,merged-config-files}

snapshot:
	git archive HEAD | bzip2 gentoo-vdr-scripts-snapshot.tar.bz2
	scp gentoo-vdr-scripts-snapshot.tar.bz2 dev.gentoo.org:public_html/distfiles/gentoo-vdr-scripts-snapshot.tar.bz2
	rm gentoo-vdr-scripts-snapshot.tar.bz2

.PHONY: all compile install snapshot