-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
62 lines (48 loc) · 1.12 KB
/
Makefile
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
ifeq (,$(wildcard config.mak))
$(error "config.mak is not present, run configure !")
endif
include config.mak
DISTFILE = libdlna-$(VERSION).tar.bz2
PKGCONFIG_DIR = $(libdir)/pkgconfig
PKGCONFIG_FILE = libdlna.pc
EXTRADIST = \
AUTHORS \
ChangeLog \
configure \
COPYING \
README \
SUBDIRS = \
src \
utils \
all: lib utils
lib:
$(MAKE) -C src
utils: lib
$(MAKE) -C utils
clean:
$(MAKE) -C src clean
$(MAKE) -C utils clean
-$(RM) -f IUpnpErrFile.txt IUpnpInfoFile.txt
distclean: clean
-$(RM) -f config.log
-$(RM) -f config.mak
-$(RM) -f $(PKGCONFIG_FILE)
install: install-pkgconfig
$(MAKE) -C src install
install-pkgconfig: $(PKGCONFIG_FILE)
$(INSTALL) -d "$(PKGCONFIG_DIR)"
$(INSTALL) -m 644 $< "$(PKGCONFIG_DIR)"
.PHONY: clean distclean
.PHONY: install install-pkgconfig
dist:
-$(RM) $(DISTFILE)
dist=$(shell pwd)/libdlna-$(VERSION) && \
for subdir in . $(SUBDIRS); do \
mkdir -p "$$dist/$$subdir"; \
$(MAKE) -C $$subdir dist-all DIST="$$dist/$$subdir"; \
done && \
tar cjf $(DISTFILE) libdlna-$(VERSION)
-$(RM) -rf libdlna-$(VERSION)
dist-all:
cp $(EXTRADIST) Makefile $(DIST)
.PHONY: dist dist-all utils