File: Makefile.in

package info (click to toggle)
sudo 1.8.5p2-1+nmu3+deb7u1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 12,556 kB
  • sloc: ansic: 39,731; sh: 16,999; makefile: 1,974; yacc: 1,471; lex: 1,037; perl: 436
file content (301 lines) | stat: -rw-r--r-- 8,870 bytes parent folder | download
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
#
# Copyright (c) 2010-2011 Todd C. Miller <Todd.Miller@courtesan.com>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#

srcdir = @srcdir@
devdir = @devdir@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@

# Installation paths for package building
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
sbindir = @sbindir@
sysconfdir = @sysconfdir@
libexecdir = @libexecdir@
includedir = @includedir@
datarootdir = @datarootdir@
localedir = @localedir@
localstatedir = @localstatedir@
docdir = @docdir@
mandir = @mandir@
timedir = @timedir@

# User and group ids the installed files should be "owned" by
install_uid = 0
install_gid = 0

# sudoers owner and mode for package building
sudoersdir = $(sysconfdir)
sudoers_uid = @SUDOERS_UID@
sudoers_gid = @SUDOERS_GID@
sudoers_mode = @SUDOERS_MODE@

SUBDIRS = compat common @ZLIB_SRC@ plugins/sudoers src include doc

SAMPLES = plugins/sample plugins/sample_group plugins/system_group

VERSION = @PACKAGE_VERSION@
PACKAGE_TARNAME = @PACKAGE_TARNAME@

LIBTOOL_DEPS = @LIBTOOL_DEPS@

SHELL = @SHELL@

INSTALL = $(SHELL) $(top_srcdir)/install-sh -c

ECHO_N = @ECHO_N@
ECHO_C = @ECHO_C@

# Message catalog support
NLS = @SUDO_NLS@
POTFILES = src/po/sudo.pot plugins/sudoers/po/sudoers.pot
MSGFMT = msgfmt
MSGMERGE = msgmerge
XGETTEXT = xgettext
XGETTEXT_OPTS = -F -k_ -kN_ --copyright-holder="Todd C. Miller" \
		"--msgid-bugs-address=http://www.sudo.ws/bugs" \
		--package-name=@PACKAGE_NAME@ --package-version=$(VERSION) \
		--flag warning:1:c-format --flag warningx:1:c-format \
		--flag error:2:c-format --flag errorx:2:c-format \
		--flag easprintf:3:c-format --flag lbuf_append:2:c-format \
		--flag lbuf_append_quoted:3:c-format --foreign-user

all: config.status
	for d in $(SUBDIRS) $(SAMPLES); \
	    do (cd $$d && exec $(MAKE) $@) && continue; \
	    exit $$?; \
	done

check pre-install: config.status
	for d in $(SUBDIRS); \
	    do (cd $$d && exec $(MAKE) $@) && continue; \
	    exit $$?; \
	done

install-dirs install-binaries install-includes install-plugin: config.status pre-install
	for d in $(SUBDIRS); \
	    do (cd $$d && exec $(MAKE) $@) && continue; \
	    exit $$?; \
	done

install-doc: config.status ChangeLog
	for d in $(SUBDIRS); \
	    do (cd $$d && exec $(MAKE) $@) && continue; \
	    exit $$?; \
	done

install: config.status ChangeLog pre-install install-nls
	for d in $(SUBDIRS); \
	    do (cd $$d && exec $(MAKE) $@) && continue; \
	    exit $$?; \
	done

uninstall: uninstall-nls
	for d in $(SUBDIRS); \
	    do (cd $$d && exec $(MAKE) $@) && continue; \
	    exit $$?; \
	done

uninstall-nls:
	for pot in $(POTFILES); do \
	    domain=`basename $$pot .pot`; \
	    rm -f $(DESTDIR)$(localedir)/*/LC_MESSAGES/$$domain.mo; \
	done

autoconf:
	autoconf -I m4

siglist.c:
	(cd compat && exec $(MAKE) $@)

depend: siglist.c
	@if test "$(srcdir)" != "."; then \
	    echo "make depend only supported in the source directory"; \
	    exit 1; \
	fi; \
	$(srcdir)/mkdep.pl $(srcdir)/common/Makefile.in \
	    $(srcdir)/compat/Makefile.in $(srcdir)/plugins/sample/Makefile.in \
	    $(srcdir)/plugins/sample_group/Makefile.in \
	    $(srcdir)/plugins/sudoers/Makefile.in \
	    $(srcdir)/plugins/system_group/Makefile.in \
	    $(srcdir)/src/Makefile.in $(srcdir)/zlib/Makefile.in; \
	./config.status --file $(srcdir)/common/Makefile \
	    --file $(srcdir)/compat/Makefile \
	    --file $(srcdir)/plugins/sample/Makefile \
	    --file $(srcdir)/plugins/sample_group/Makefile \
	    --file $(srcdir)/plugins/sudoers/Makefile \
	    --file $(srcdir)/plugins/system_group/Makefile \
	    --file $(srcdir)/src/Makefile --file $(srcdir)/zlib/Makefile

ChangeLog:
	if test -d $(srcdir)/.hg && cd $(srcdir); then \
	    if hg log --style=changelog -b default > $@.tmp; then \
		mv -f $@.tmp $@; \
	    else \
		rm -f $@.tmp; \
	    fi; \
	fi

config.status:
	@if [ ! -s config.status ]; then \
		echo "Please run configure first"; \
		exit 1; \
	fi

libtool: $(LIBTOOL_DEPS)
	$(SHELL) ./config.status --recheck

Makefile: $(srcdir)/Makefile.in
	./config.status --file Makefile

sync-po: rsync-po compile-po

rsync-po:
	rsync -Lrtvz  translationproject.org::tp/latest/sudo/ src/po/
	rsync -Lrtvz  translationproject.org::tp/latest/sudoers/ plugins/sudoers/po/

update-pot:
	@if $(XGETTEXT) --help >/dev/null 2>&1; then \
	    cd $(top_srcdir); \
	    for pot in $(POTFILES); do \
		echo "Updating $$pot"; \
		domain=`basename $$pot .pot`; \
		case "$$domain" in \
		    sudo) cfiles="src/*c common/*c compat/*c";; \
		    sudoers) cfiles="plugins/sudoers/*.c plugins/sudoers/auth/*.c";; \
		    *) echo unknown domain $$domain; continue;; \
		esac; \
		$(XGETTEXT) $(XGETTEXT_OPTS) -d$$domain $$cfiles -o $$pot.tmp; \
		if diff -I'^.POT-Creation-Date' -I'^.Project-Id-Version' -I'^#' $$pot.tmp $$pot >/dev/null; then \
		    rm -f $$pot.tmp; \
		else \
		    mv -f $$pot.tmp $$pot; \
		fi; \
	    done; \
	fi

update-po: update-pot
	@if $(MSGFMT) --help >/dev/null 2>&1; then \
	    cd $(top_srcdir); \
	    for pot in $(POTFILES); do \
		podir=`dirname $$pot`; \
		for po in $$podir/*.po; do \
		    echo $(ECHO_N) "Updating $$po$(ECHO_C)"; \
		    $(MSGMERGE) --update $$po $$pot; \
		    $(MSGFMT) --output /dev/null --check-format $$po || exit 1; \
		done; \
	    done; \
	fi

compile-po:
	@if $(MSGFMT) --help >/dev/null 2>&1; then \
	    cd $(top_srcdir); \
	    rm -f Makefile.$$$$; \
	    POFILES=""; \
	    for pot in $(POTFILES); do \
		podir=`dirname $$pot`; \
		for po in $$podir/*.po; do \
		    POFILES="$$POFILES $$po"; \
		done; \
	    done; \
	    echo "all: `echo $$POFILES | sed 's/\.po/.mo/g'`" >> Makefile.$$$$; \
	    echo "" >> Makefile.$$$$; \
	    for po in $$POFILES; do \
		mo=`echo $$po | sed 's/po$$/mo/'`; \
		echo "$$mo: $$po" >> Makefile.$$$$; \
		echo "	$(MSGFMT) --statistics -c -o $$mo $$po" >> Makefile.$$$$; \
	    done; \
	    make -f Makefile.$$$$; \
	    rm -f Makefile.$$$$; \
	fi

install-nls:
	@if test "$(NLS)" = "enabled"; then \
	    cd $(top_srcdir); \
	    for pot in $(POTFILES); do \
		podir=`dirname $$pot`; \
		domain=`basename $$pot .pot`; \
		SUDO_LINGUAS=$${LINGUAS-"`echo $$podir/*.mo|sed 's:'$$podir'/\([^ ]*\).mo:\1:g'`"}; \
		echo $(ECHO_N) "Installing $$domain message catalogs:$(ECHO_C)"; \
		for lang in $$SUDO_LINGUAS; do \
		    test -s $$podir/$$lang.mo || continue; \
		    echo $(ECHO_N) " $$lang$(ECHO_C)"; \
		    $(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES; \
		    $(INSTALL) -O $(install_uid) -G $(install_gid) -m 0444 $$podir/$$lang.mo $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$$domain.mo; \
		done; \
		echo ""; \
	    done; \
	fi

check-dist: update-pot compile-po
	@if [ -d .hg ]; then \
	    if hg stat -am | grep '\.[mp]ot*$$'; then \
		echo "Uncommitted message catalog changes" 1>&2; \
		false; \
	    fi; \
	fi

dist: check-dist ChangeLog $(srcdir)/MANIFEST
	pax -w -x ustar -s '/^/$(PACKAGE_TARNAME)-$(VERSION)\//' \
	    -f ../$(PACKAGE_TARNAME)-$(VERSION).tar \
	    `sed 's/[ 	].*//' $(srcdir)/MANIFEST`
	gzip -9f ../$(PACKAGE_TARNAME)-$(VERSION).tar
	ls -l ../$(PACKAGE_TARNAME)-$(VERSION).tar.gz

package: sudo.pp
	DESTDIR=`cd $(top_builddir) && pwd`/destdir; rm -rf $$DESTDIR; \
	$(MAKE) install DESTDIR=$$DESTDIR && \
	$(SHELL) $(srcdir)/pp $(PPFLAGS) \
	    --destdir=$$DESTDIR \
	    $(srcdir)/sudo.pp \
	    bindir=$(bindir) \
	    sbindir=$(sbindir) \
	    libexecdir=$(libexecdir) \
	    includedir=$(includedir) \
	    timedir=$(timedir) \
	    mandir=$(mandir) \
	    localedir=$(localedir) \
	    docdir=$(docdir) \
	    sysconfdir=$(sysconfdir) \
	    sudoersdir=$(sudoersdir) \
	    sudoers_uid=$(sudoers_uid) \
	    sudoers_gid=$(sudoers_gid) \
	    sudoers_mode=$(sudoers_mode) \
	    version=$(VERSION) $(PPVARS)

clean: config.status
	for d in $(SUBDIRS) $(SAMPLES); do \
	    (cd $$d && exec $(MAKE) $@); \
	done

mostlyclean: clean

distclean: config.status
	for d in $(SUBDIRS) $(SAMPLES); do \
	    (cd $$d && exec $(MAKE) $@); \
	done
	-rm -rf Makefile pathnames.h config.h config.status config.cache \
		config.log libtool stamp-* autom4te.cache

cleandir: distclean

clobber: distclean

realclean: distclean

.PHONY: ChangeLog