mirror of
https://github.com/Stichting-MINIX-Research-Foundation/pkgsrc-ng.git
synced 2025-09-08 03:44:13 -04:00
80 lines
5.1 KiB
Plaintext
80 lines
5.1 KiB
Plaintext
$NetBSD: patch-aa,v 1.30 2013/03/01 14:24:58 kim Exp $
|
|
|
|
* Fix libtools's link option.
|
|
* Prevent to install sudoers files and directory.
|
|
* Use standard instal(8) option instead of shell wrapper.
|
|
* Don't setuid here.
|
|
|
|
--- Makefile.in.orig 2013-01-15 19:59:25.000000000 +0000
|
|
+++ Makefile.in 2013-03-01 13:46:11.000000000 +0000
|
|
@@ -250,7 +250,7 @@
|
|
$(LIBTOOL) --mode=compile $(CC) -c $(CPPFLAGS) $(CFLAGS) $(DEFS) $(OPTIONS) $(srcdir)/sudo_noexec.c
|
|
|
|
libsudo_noexec.la: sudo_noexec.lo
|
|
- $(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -o $@ sudo_noexec.lo -avoid-version -rpath $(noexecdir)
|
|
+ $(LIBTOOL) --mode=link $(CC) -module $(LDFLAGS) -o $@ sudo_noexec.lo -avoid-version -rpath $(noexecdir)
|
|
|
|
GENERATED = gram.h gram.c toke.c def_data.c def_data.h getdate.c
|
|
|
|
@@ -686,43 +686,43 @@
|
|
./visudo -c -f $(DESTDIR)$(sudoersdir)/sudoers; \
|
|
fi
|
|
|
|
-install: pre-install install-dirs install-binaries @INSTALL_NOEXEC@ install-sudoers install-doc
|
|
+install: install-binaries @INSTALL_NOEXEC@ install-doc
|
|
|
|
install-dirs:
|
|
$(SHELL) $(srcdir)/mkinstalldirs $(DESTDIR)$(sudodir) \
|
|
$(DESTDIR)$(visudodir) $(DESTDIR)$(noexecdir) \
|
|
- $(DESTDIR)$(sudoersdir) $(DESTDIR)$(docdir) \
|
|
+ $(DESTDIR)$(sudoersdir) \
|
|
$(DESTDIR)$(mandirsu) $(DESTDIR)$(mandirform) \
|
|
`echo $(DESTDIR)$(timedir)|sed 's,/[^/]*$$,,'`
|
|
- $(INSTALL) -d -O $(install_uid) -G $(install_gid) -m 0700 $(DESTDIR)$(timedir)
|
|
+ $(INSTALL) -d -m 0700 $(DESTDIR)$(timedir)
|
|
|
|
install-binaries: install-dirs $(PROGS)
|
|
if [ X"$$SUDO_PREINSTALL_CMD" != X"" ]; then exec $$SUDO_PREINSTALL_CMD sudo; fi
|
|
- $(INSTALL) -b~ -O $(install_uid) -G $(install_gid) -M 04755 sudo $(DESTDIR)$(sudodir)/sudo
|
|
+ $(INSTALL) sudo $(DESTDIR)$(sudodir)/sudo
|
|
rm -f $(DESTDIR)$(sudodir)/sudoedit
|
|
ln -s sudo $(DESTDIR)$(sudodir)/sudoedit
|
|
- if [ -f sudoreplay ]; then $(INSTALL) -b~ -O $(install_uid) -G $(install_gid) -m 0755 sudoreplay $(DESTDIR)$(sudodir)/sudoreplay; fi
|
|
- $(INSTALL) -b~ -O $(install_uid) -G $(install_gid) -m 0755 visudo $(DESTDIR)$(visudodir)/visudo
|
|
- if [ -f sesh ]; then $(INSTALL) -b~ -O $(install_uid) -G $(install_gid) -m 0755 sesh $(DESTDIR)$(libexecdir)/sesh; fi
|
|
+ if [ -f sudoreplay ]; then $(INSTALL) sudoreplay $(DESTDIR)$(sudodir)/sudoreplay; fi
|
|
+ $(INSTALL) visudo $(DESTDIR)$(visudodir)/visudo
|
|
+ if [ -f sesh ]; then $(INSTALL) sesh $(DESTDIR)$(libexecdir)/sesh; fi
|
|
|
|
install-noexec: install-dirs libsudo_noexec.la
|
|
- if [ -f .libs/lib$(noexecfile) ]; then $(INSTALL) -b~ -O $(install_uid) -G $(install_gid) -m $(shlib_mode) .libs/lib$(noexecfile) $(DESTDIR)$(noexecdir)/$(noexecfile); fi
|
|
+ if [ -f .libs/lib$(noexecfile) ]; then $(INSTALL) -m $(shlib_mode) .libs/lib$(noexecfile) $(DESTDIR)$(noexecdir)/$(noexecfile); fi
|
|
|
|
install-sudoers: install-dirs
|
|
- $(INSTALL) -d -O $(sudoers_uid) -G $(sudoers_gid) -m 0750 \
|
|
+ $(INSTALL) -d -m 0750 \
|
|
$(DESTDIR)$(sudoersdir)/sudoers.d
|
|
test -f $(DESTDIR)$(sudoersdir)/sudoers || \
|
|
- $(INSTALL) -O $(sudoers_uid) -G $(sudoers_gid) -m $(sudoers_mode) \
|
|
+ $(INSTALL) -m $(sudoers_mode) \
|
|
sudoers $(DESTDIR)$(sudoersdir)/sudoers
|
|
|
|
install-doc: install-dirs ChangeLog
|
|
- (cd $(srcdir) && for f in ChangeLog HISTORY LICENSE NEWS README TROUBLESHOOTING UPGRADE sample.*; do $(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 $$f $(DESTDIR)$(docdir); done)
|
|
- @LDAP@(cd $(srcdir) && for f in README.LDAP schema.* sudoers2ldif; do $(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 $$f $(DESTDIR)$(docdir); done)
|
|
- $(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 @mansrcdir@/sudo.$(mantype) $(DESTDIR)$(mandirsu)/sudo.$(mansectsu)
|
|
- @REPLAY@$(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 @mansrcdir@/sudoreplay.$(mantype) $(DESTDIR)$(mandirsu)/sudoreplay.$(mansectsu)
|
|
- $(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 @mansrcdir@/visudo.$(mantype) $(DESTDIR)$(mandirsu)/visudo.$(mansectsu)
|
|
- $(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 @mansrcdir@/sudoers.$(mantype) $(DESTDIR)$(mandirform)/sudoers.$(mansectform)
|
|
- @LDAP@$(INSTALL) -O $(install_uid) -G $(install_gid) -m 0644 @mansrcdir@/sudoers.ldap.$(mantype) $(DESTDIR)$(mandirform)/sudoers.ldap.$(mansectform)
|
|
+ (cd $(srcdir) && for f in ChangeLog HISTORY LICENSE NEWS README TROUBLESHOOTING UPGRADE sample.*; do $(INSTALL) -m 0644 $$f $(DESTDIR)$(docdir); done)
|
|
+ @LDAP@(cd $(srcdir) && for f in README.LDAP schema.* sudoers2ldif; do $(INSTALL) -m 0644 $$f $(DESTDIR)$(docdir); done)
|
|
+ $(INSTALL) -m 0644 @mansrcdir@/sudo.$(mantype) $(DESTDIR)$(mandirsu)/sudo.$(mansectsu)
|
|
+ @REPLAY@$(INSTALL) -m 0644 @mansrcdir@/sudoreplay.$(mantype) $(DESTDIR)$(mandirsu)/sudoreplay.$(mansectsu)
|
|
+ $(INSTALL) -m 0644 @mansrcdir@/visudo.$(mantype) $(DESTDIR)$(mandirsu)/visudo.$(mansectsu)
|
|
+ $(INSTALL) -m 0644 @mansrcdir@/sudoers.$(mantype) $(DESTDIR)$(mandirform)/sudoers.$(mansectform)
|
|
+ @LDAP@$(INSTALL) -m 0644 @mansrcdir@/sudoers.ldap.$(mantype) $(DESTDIR)$(mandirform)/sudoers.ldap.$(mansectform)
|
|
@if test -n "$(MANCOMPRESS)"; then \
|
|
for f in $(mandirsu)/sudo.$(mansectsu) $(mandirsu)/sudoreplay.$(mansectsu) $(mandirsu)/visudo.$(mansectsu) $(mandirform)/sudoers.$(mansectform) $(mandirform)/sudoers.ldap.$(mansectform); do \
|
|
if test -f $(DESTDIR)$$f; then \
|