version 1.1.1.2, 2012/05/29 12:26:48
|
version 1.1.1.5, 2014/06/15 16:12:53
|
Line 1
|
Line 1
|
# |
# |
# Copyright (c) 2010-2011 Todd C. Miller <Todd.Miller@courtesan.com> | # Copyright (c) 2010-2014 Todd C. Miller <Todd.Miller@courtesan.com> |
# |
# |
# Permission to use, copy, modify, and distribute this software for any |
# Permission to use, copy, modify, and distribute this software for any |
# purpose with or without fee is hereby granted, provided that the above |
# purpose with or without fee is hereby granted, provided that the above |
Line 33 localedir = @localedir@
|
Line 33 localedir = @localedir@
|
localstatedir = @localstatedir@ |
localstatedir = @localstatedir@ |
docdir = @docdir@ |
docdir = @docdir@ |
mandir = @mandir@ |
mandir = @mandir@ |
timedir = @timedir@ | rundir = @rundir@ |
| vardir = @vardir@ |
|
|
# User and group ids the installed files should be "owned" by |
# User and group ids the installed files should be "owned" by |
install_uid = 0 |
install_uid = 0 |
Line 44 sudoersdir = $(sysconfdir)
|
Line 45 sudoersdir = $(sysconfdir)
|
sudoers_uid = @SUDOERS_UID@ |
sudoers_uid = @SUDOERS_UID@ |
sudoers_gid = @SUDOERS_GID@ |
sudoers_gid = @SUDOERS_GID@ |
sudoers_mode = @SUDOERS_MODE@ |
sudoers_mode = @SUDOERS_MODE@ |
|
shlib_mode = @SHLIB_MODE@ |
|
|
SUBDIRS = compat common @ZLIB_SRC@ plugins/sudoers src include doc | SUBDIRS = compat common @ZLIB_SRC@ plugins/group_file plugins/sudoers \ |
| plugins/system_group src include doc |
|
|
SAMPLES = plugins/sample plugins/sample_group plugins/system_group | SAMPLES = plugins/sample |
|
|
VERSION = @PACKAGE_VERSION@ |
VERSION = @PACKAGE_VERSION@ |
PACKAGE_TARNAME = @PACKAGE_TARNAME@ |
PACKAGE_TARNAME = @PACKAGE_TARNAME@ |
Line 64 ECHO_C = @ECHO_C@
|
Line 67 ECHO_C = @ECHO_C@
|
# Message catalog support |
# Message catalog support |
NLS = @SUDO_NLS@ |
NLS = @SUDO_NLS@ |
POTFILES = src/po/sudo.pot plugins/sudoers/po/sudoers.pot |
POTFILES = src/po/sudo.pot plugins/sudoers/po/sudoers.pot |
|
LOCALEDIR_SUFFIX = @LOCALEDIR_SUFFIX@ |
MSGFMT = msgfmt |
MSGFMT = msgfmt |
MSGMERGE = msgmerge |
MSGMERGE = msgmerge |
XGETTEXT = xgettext |
XGETTEXT = xgettext |
XGETTEXT_OPTS = -F -k_ -kN_ --copyright-holder="Todd C. Miller" \ | XGETTEXT_OPTS = -F -k_ -kN_ -kU_ --copyright-holder="Todd C. Miller" \ |
"--msgid-bugs-address=http://www.sudo.ws/bugs" \ |
"--msgid-bugs-address=http://www.sudo.ws/bugs" \ |
--package-name=@PACKAGE_NAME@ --package-version=$(VERSION) \ |
--package-name=@PACKAGE_NAME@ --package-version=$(VERSION) \ |
--flag warning:1:c-format --flag warningx:1:c-format \ |
--flag warning:1:c-format --flag warningx:1:c-format \ |
--flag error:2:c-format --flag errorx:2:c-format \ | --flag fatal:1:c-format --flag fatalx:1:c-format \ |
--flag easprintf:3:c-format --flag lbuf_append:2:c-format \ |
--flag easprintf:3:c-format --flag lbuf_append:2:c-format \ |
--flag lbuf_append_quoted:3:c-format --foreign-user |
--flag lbuf_append_quoted:3:c-format --foreign-user |
|
|
|
# Default cppcheck options when run from the top-level Makefile |
|
CPPCHECK_OPTS = -q --force --enable=warning,performance,portability --suppress=constStatement --error-exitcode=1 --inline-suppr -U__cplusplus -UQUAD_MAX -UQUAD_MIN -UUQUAD_MAX -U_POSIX_HOST_NAME_MAX -U_POSIX_PATH_MAX |
|
|
all: config.status |
all: config.status |
for d in $(SUBDIRS) $(SAMPLES); \ | for d in $(SUBDIRS); do \ |
do (cd $$d && exec $(MAKE) $@) && continue; \ | (cd $$d && exec $(MAKE) $@) && continue; \ |
exit $$?; \ |
exit $$?; \ |
done |
done |
|
|
check pre-install: config.status |
check pre-install: config.status |
for d in $(SUBDIRS); \ | for d in $(SUBDIRS); do \ |
do (cd $$d && exec $(MAKE) $@) && continue; \ | (cd $$d && exec $(MAKE) $@) && continue; \ |
exit $$?; \ |
exit $$?; \ |
done |
done |
|
|
|
cppcheck: config.status |
|
rval=0; \ |
|
for d in $(SUBDIRS); do \ |
|
echo checking $$d; \ |
|
(cd $$d && exec $(MAKE) CPPCHECK_OPTS="$(CPPCHECK_OPTS)" $@) || rval=`expr $$rval + $$?`; \ |
|
done; \ |
|
exit $$rval |
|
|
install-dirs install-binaries install-includes install-plugin: config.status pre-install |
install-dirs install-binaries install-includes install-plugin: config.status pre-install |
for d in $(SUBDIRS); \ | for d in $(SUBDIRS); do \ |
do (cd $$d && exec $(MAKE) $@) && continue; \ | (cd $$d && exec $(MAKE) $@) && continue; \ |
exit $$?; \ |
exit $$?; \ |
done |
done |
|
|
install-doc: config.status ChangeLog |
install-doc: config.status ChangeLog |
for d in $(SUBDIRS); \ | for d in $(SUBDIRS); do \ |
do (cd $$d && exec $(MAKE) $@) && continue; \ | (cd $$d && exec $(MAKE) $@) && continue; \ |
exit $$?; \ |
exit $$?; \ |
done |
done |
|
|
install: config.status ChangeLog pre-install install-nls |
install: config.status ChangeLog pre-install install-nls |
for d in $(SUBDIRS); \ | for d in $(SUBDIRS); do \ |
do (cd $$d && exec $(MAKE) $@) && continue; \ | (cd $$d && exec $(MAKE) $@) && continue; \ |
exit $$?; \ |
exit $$?; \ |
done |
done |
|
|
uninstall: uninstall-nls |
uninstall: uninstall-nls |
for d in $(SUBDIRS); \ | for d in $(SUBDIRS); do \ |
do (cd $$d && exec $(MAKE) $@) && continue; \ | (cd $$d && exec $(MAKE) $@) && continue; \ |
exit $$?; \ |
exit $$?; \ |
done |
done |
|
|
Line 117 uninstall-nls:
|
Line 132 uninstall-nls:
|
rm -f $(DESTDIR)$(localedir)/*/LC_MESSAGES/$$domain.mo; \ |
rm -f $(DESTDIR)$(localedir)/*/LC_MESSAGES/$$domain.mo; \ |
done |
done |
|
|
autoconf: | siglist.c signame.c: |
autoconf -I m4 | |
| |
siglist.c: | |
(cd compat && exec $(MAKE) $@) |
(cd compat && exec $(MAKE) $@) |
|
|
depend: siglist.c | depend: siglist.c signame.c |
@if test "$(srcdir)" != "."; then \ |
@if test "$(srcdir)" != "."; then \ |
echo "make depend only supported in the source directory"; \ |
echo "make depend only supported in the source directory"; \ |
exit 1; \ |
exit 1; \ |
fi; \ |
fi; \ |
$(srcdir)/mkdep.pl $(srcdir)/common/Makefile.in \ |
$(srcdir)/mkdep.pl $(srcdir)/common/Makefile.in \ |
$(srcdir)/compat/Makefile.in $(srcdir)/plugins/sample/Makefile.in \ |
$(srcdir)/compat/Makefile.in $(srcdir)/plugins/sample/Makefile.in \ |
$(srcdir)/plugins/sample_group/Makefile.in \ | $(srcdir)/plugins/group_file/Makefile.in \ |
$(srcdir)/plugins/sudoers/Makefile.in \ |
$(srcdir)/plugins/sudoers/Makefile.in \ |
$(srcdir)/plugins/system_group/Makefile.in \ |
$(srcdir)/plugins/system_group/Makefile.in \ |
$(srcdir)/src/Makefile.in $(srcdir)/zlib/Makefile.in; \ |
$(srcdir)/src/Makefile.in $(srcdir)/zlib/Makefile.in; \ |
./config.status --file $(srcdir)/common/Makefile \ |
./config.status --file $(srcdir)/common/Makefile \ |
--file $(srcdir)/compat/Makefile \ |
--file $(srcdir)/compat/Makefile \ |
--file $(srcdir)/plugins/sample/Makefile \ |
--file $(srcdir)/plugins/sample/Makefile \ |
--file $(srcdir)/plugins/sample_group/Makefile \ | --file $(srcdir)/plugins/group_file/Makefile \ |
--file $(srcdir)/plugins/sudoers/Makefile \ |
--file $(srcdir)/plugins/sudoers/Makefile \ |
--file $(srcdir)/plugins/system_group/Makefile \ |
--file $(srcdir)/plugins/system_group/Makefile \ |
--file $(srcdir)/src/Makefile --file $(srcdir)/zlib/Makefile |
--file $(srcdir)/src/Makefile --file $(srcdir)/zlib/Makefile |
Line 176 update-pot:
|
Line 188 update-pot:
|
echo "Updating $$pot"; \ |
echo "Updating $$pot"; \ |
domain=`basename $$pot .pot`; \ |
domain=`basename $$pot .pot`; \ |
case "$$domain" in \ |
case "$$domain" in \ |
sudo) cfiles="src/*c common/*c compat/*c";; \ | sudo) tmpfiles=; cfiles="src/*c common/*c compat/*c";; \ |
sudoers) cfiles="plugins/sudoers/*.c plugins/sudoers/auth/*.c";; \ | sudoers) \ |
| echo "syntax error" > confstr.sh; \ |
| sed -n -e 's/^badpass_message="/gettext "/p' \ |
| -e 's/^passprompt="/gettext "/p' \ |
| -e 's/^mailsub="/gettext "/p' configure.ac \ |
| >> confstr.sh; \ |
| tmpfiles=confstr.sh; \ |
| cfiles="plugins/sudoers/*.c plugins/sudoers/auth/*.c";; \ |
*) echo unknown domain $$domain; continue;; \ |
*) echo unknown domain $$domain; continue;; \ |
esac; \ |
esac; \ |
$(XGETTEXT) $(XGETTEXT_OPTS) -d$$domain $$cfiles -o $$pot.tmp; \ | $(XGETTEXT) $(XGETTEXT_OPTS) -d$$domain $$cfiles $$tmpfiles -o $$pot.tmp; \ |
| test -n "$$tmpfiles" && rm -f $$tmpfiles; \ |
if diff -I'^.POT-Creation-Date' -I'^.Project-Id-Version' -I'^#' $$pot.tmp $$pot >/dev/null; then \ |
if diff -I'^.POT-Creation-Date' -I'^.Project-Id-Version' -I'^#' $$pot.tmp $$pot >/dev/null; then \ |
rm -f $$pot.tmp; \ |
rm -f $$pot.tmp; \ |
else \ |
else \ |
mv -f $$pot.tmp $$pot; \ | printf '/^#$$/+1,$$d\nw\nq\n' | ed - $$pot; \ |
| sed '1,/^#$$/d' $$pot.tmp >> $$pot; \ |
| rm -f $$pot.tmp; \ |
fi; \ |
fi; \ |
done; \ |
done; \ |
fi |
fi |
Line 236 install-nls:
|
Line 258 install-nls:
|
test -s $$podir/$$lang.mo || continue; \ |
test -s $$podir/$$lang.mo || continue; \ |
echo $(ECHO_N) " $$lang$(ECHO_C)"; \ |
echo $(ECHO_N) " $$lang$(ECHO_C)"; \ |
$(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES; \ |
$(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; \ | if test -n "$(LOCALEDIR_SUFFIX)"; then \ |
| if test ! -d $(DESTDIR)$(localedir)/$$lang$(LOCALEDIR_SUFFIX); then \ |
| ln -s $$lang $(DESTDIR)$(localedir)/$$lang$(LOCALEDIR_SUFFIX); \ |
| fi; \ |
| fi; \ |
| $(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 $$podir/$$lang.mo $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$$domain.mo; \ |
done; \ |
done; \ |
echo ""; \ |
echo ""; \ |
done; \ |
done; \ |
Line 244 install-nls:
|
Line 271 install-nls:
|
|
|
check-dist: update-pot compile-po |
check-dist: update-pot compile-po |
@if [ -d .hg ]; then \ |
@if [ -d .hg ]; then \ |
if hg stat -am | grep '\.[mp]ot*$$'; then \ | if test `hg stat -am | wc -l` -ne 0; then \ |
echo "Uncommitted message catalog changes" 1>&2; \ | echo "Uncommitted changes" 1>&2; \ |
false; \ | hg stat -am 1>&2; \ |
| exit 1; \ |
fi; \ |
fi; \ |
fi |
fi |
|
|
dist: check-dist ChangeLog $(srcdir)/MANIFEST | dist: check-dist force-dist |
| |
| force-dist: ChangeLog $(srcdir)/MANIFEST |
pax -w -x ustar -s '/^/$(PACKAGE_TARNAME)-$(VERSION)\//' \ |
pax -w -x ustar -s '/^/$(PACKAGE_TARNAME)-$(VERSION)\//' \ |
-f ../$(PACKAGE_TARNAME)-$(VERSION).tar \ |
-f ../$(PACKAGE_TARNAME)-$(VERSION).tar \ |
`sed 's/[ ].*//' $(srcdir)/MANIFEST` |
`sed 's/[ ].*//' $(srcdir)/MANIFEST` |
Line 267 package: sudo.pp
|
Line 297 package: sudo.pp
|
sbindir=$(sbindir) \ |
sbindir=$(sbindir) \ |
libexecdir=$(libexecdir) \ |
libexecdir=$(libexecdir) \ |
includedir=$(includedir) \ |
includedir=$(includedir) \ |
timedir=$(timedir) \ | vardir=$(vardir) \ |
| rundir=$(rundir) \ |
mandir=$(mandir) \ |
mandir=$(mandir) \ |
localedir=$(localedir) \ |
localedir=$(localedir) \ |
docdir=$(docdir) \ |
docdir=$(docdir) \ |
Line 276 package: sudo.pp
|
Line 307 package: sudo.pp
|
sudoers_uid=$(sudoers_uid) \ |
sudoers_uid=$(sudoers_uid) \ |
sudoers_gid=$(sudoers_gid) \ |
sudoers_gid=$(sudoers_gid) \ |
sudoers_mode=$(sudoers_mode) \ |
sudoers_mode=$(sudoers_mode) \ |
|
shlib_mode=$(shlib_mode) \ |
version=$(VERSION) $(PPVARS) |
version=$(VERSION) $(PPVARS) |
|
|
clean: config.status |
clean: config.status |
Line 298 clobber: distclean
|
Line 330 clobber: distclean
|
|
|
realclean: distclean |
realclean: distclean |
|
|
.PHONY: ChangeLog | me: |
| |
| a: |
| |
| sandwich: |
| @if test -n "$$SUDO_USER"; then \ |
| echo "Okay."; \ |
| else \ |
| echo "What? Make it yourself!"; \ |
| fi |
| |
| .PHONY: ChangeLog me a sandwhich |