summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorChocobo12018-05-12 14:39:08 +0800
committerChocobo12018-05-12 15:18:15 +0800
commit112c0f6c21605001debb8ffe87ab024b747ac369 (patch)
tree64afea537bfc71888b8a5c1dc97c89de37456520
downloadaur-112c0f6c21605001debb8ffe87ab024b747ac369.tar.gz
newpkg: sudo-hg r11370.d568dc923c7d-1
-rw-r--r--.SRCINFO24
-rw-r--r--PKGBUILD68
2 files changed, 92 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..3b992c0f941
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,24 @@
+pkgbase = sudo-hg
+ pkgdesc = Run commands as root or another user
+ pkgver = r11370.d568dc923c7d
+ pkgrel = 1
+ url = https://www.sudo.ws/sudo.html
+ arch = i686
+ arch = x86_64
+ license = custom
+ makedepends = mercurial
+ depends = glibc
+ depends = libgcrypt
+ depends = libldap
+ depends = pam
+ provides = sudo
+ conflicts = sudo
+ backup = etc/sudoers
+ backup = etc/pam.d/sudo
+ source = hg+https://www.sudo.ws/repos/sudo/
+ source = sudo.pam::https://git.archlinux.org/svntogit/packages.git/plain/trunk/sudo.pam?h=packages/sudo
+ sha256sums = SKIP
+ sha256sums = SKIP
+
+pkgname = sudo-hg
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..e3b08140cc0
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,68 @@
+# Maintainer: Chocobo1 <chocobo1 AT archlinux DOT net>
+
+pkgname=sudo-hg
+pkgver=r11370.d568dc923c7d
+pkgrel=1
+pkgdesc="Run commands as root or another user"
+arch=('i686' 'x86_64')
+url="https://www.sudo.ws/sudo.html"
+license=('custom')
+depends=('glibc' 'libgcrypt' 'libldap' 'pam')
+makedepends=('mercurial')
+provides=('sudo')
+conflicts=('sudo')
+backup=('etc/sudoers' 'etc/pam.d/sudo')
+source=("hg+https://www.sudo.ws/repos/sudo/"
+ "sudo.pam::https://git.archlinux.org/svntogit/packages.git/plain/trunk/sudo.pam?h=packages/sudo")
+sha256sums=('SKIP'
+ 'SKIP')
+
+
+pkgver() {
+ cd "sudo"
+
+ printf "r%s.%s" "$(hg identify -n)" "$(hg identify -i)"
+}
+
+build() {
+ cd "sudo"
+
+ ./autogen.sh
+ ./configure \
+ --prefix="/usr" \
+ --sbindir="/usr/bin" \
+ --libexecdir="/usr/lib" \
+ --with-rundir="/run/sudo" \
+ --with-vardir="/var/db/sudo" \
+ --enable-gcrypt \
+ --with-pam \
+ --enable-tmpfiles.d \
+ --with-sssd \
+ --with-ldap \
+ --with-ldap-conf-file="/etc/openldap/ldap.conf" \
+ --with-env-editor \
+ --with-passprompt="[sudo] password for %p: " \
+ --with-all-insults
+ make
+}
+
+check() {
+ cd "sudo"
+
+ make check
+}
+
+package() {
+ cd "sudo"
+
+ make DESTDIR="$pkgdir" install
+ install -Dm644 "doc/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+
+ install -Dm644 "$srcdir/sudo.pam" "$pkgdir/etc/pam.d/sudo"
+
+ # Remove sudoers.dist; not needed since pacman manages updates to sudoers
+ rm "$pkgdir/etc/sudoers.dist"
+
+ # Remove /run/sudo directory; we create it using systemd-tmpfiles
+ rm -r "$pkgdir/run"
+}