File: Makefile

package info (click to toggle)
dnsmasq 2.35-1%2Betch4
  • links: PTS
  • area: main
  • in suites: etch
  • size: 1,292 kB
  • ctags: 833
  • sloc: ansic: 10,148; perl: 643; sh: 420; makefile: 108
file content (44 lines) | stat: -rw-r--r-- 1,096 bytes parent folder | download | duplicates (2)
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
PREFIX?=/usr/local
BINDIR = ${PREFIX}/sbin
MANDIR = ${PREFIX}/share/man
LOCALEDIR = ${PREFIX}/share/locale

SRC = src
PO = po
MAN = man

CFLAGS?= -O2

all :   dnsmasq

dnsmasq :
	$(MAKE) I18N=-DNO_GETTEXT -f ../bld/Makefile -C $(SRC) dnsmasq 

clean :
	rm -f *~ $(SRC)/*.mo contrib/*/*~ */*~ $(SRC)/*.pot 
	rm -f $(SRC)/*.o $(SRC)/dnsmasq.a $(SRC)/dnsmasq core */core

install : all install-common

install-common :
	install -d $(DESTDIR)$(BINDIR) -d $(DESTDIR)$(MANDIR)/man8
	install -m 644 $(MAN)/dnsmasq.8 $(DESTDIR)$(MANDIR)/man8 
	install -m 755 $(SRC)/dnsmasq $(DESTDIR)$(BINDIR)

all-i18n :
	$(MAKE) I18N=-DLOCALEDIR='\"$(LOCALEDIR)\"' -f ../bld/Makefile -C $(SRC) dnsmasq
	cd $(PO); for f in *.po; do \
		$(MAKE) -f ../bld/Makefile -C ../$(SRC) $${f%.po}.mo; \
	done

install-i18n : all-i18n install-common
	cd $(SRC); ../bld/install-mo $(DESTDIR)$(LOCALEDIR)
	cd $(MAN); ../bld/install-man $(DESTDIR)$(MANDIR)

merge :
	$(MAKE) I18N=-DLOCALEDIR='\"$(LOCALEDIR)\"' -f ../bld/Makefile -C $(SRC) dnsmasq.pot
	cd $(PO); for f in *.po; do \
		msgmerge -U $$f ../$(SRC)/dnsmasq.pot; \
	done