[package] update sudo to 1.7.2p2 (#6413)
[openwrt/svn-archive/archive.git] / admin / sudo / Makefile
1 #
2 # Copyright (C) 2009 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6
7 include $(TOPDIR)/rules.mk
8
9 PKG_NAME:=sudo
10 PKG_VERSION:=1.7.2p2
11 PKG_RELEASE:=1
12
13 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
14 PKG_SOURCE_URL:=http://www.sudo.ws/sudo/dist/
15 PKG_MD5SUM:=2a19cf1ab4afc94fe19d0d0899d4cd45
16
17 PKG_INSTALL:=1
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/sudo
22 SECTION:= admin
23 CATEGORY:=Administration
24 TITLE:=delegate authority to run commands
25 URL:=http://www.sudo.ws/
26 endef
27
28 define Package/sudo/description
29 Sudo (su "do") allows a system administrator to delegate authority to give
30 certain users (or groups of users) the ability to run some (or all) commands
31 as root or another user while providing an audit trail of the commands and
32 their arguments.
33 endef
34
35 CONFIGURE_ARGS+= \
36 --without-pam \
37 --disable-pam-session \
38 --with-editor=/bin/vi \
39
40 CONFIGURE_VARS+= \
41 sudo_cv_uid_t_len=10 \
42 sudo_cv_func_unsetenv_void=no \
43
44 define Package/sudo/conffiles
45 /etc/sudoers
46 endef
47
48 define Package/sudo/install
49 $(INSTALL_DIR) $(1)/usr/bin
50 $(CP) $(PKG_INSTALL_DIR)/usr/bin/sudo $(1)/usr/bin/
51 chmod 4755 $(1)/usr/bin/sudo
52 $(INSTALL_DIR) $(1)/usr/sbin
53 $(CP) $(PKG_INSTALL_DIR)/usr/sbin/visudo $(1)/usr/sbin/
54 $(INSTALL_DIR) $(1)/etc
55 $(CP) $(PKG_INSTALL_DIR)/etc/sudoers $(1)/etc/
56 chmod 0440 $(1)/etc/sudoers
57 $(INSTALL_DIR) $(1)/usr/lib
58 $(CP) $(PKG_INSTALL_DIR)/usr/lib/sudo_noexec.so $(1)/usr/lib/
59 endef
60
61 $(eval $(call BuildPackage,sudo))