diff --git a/fix-timestampdir.patch b/fix-timestampdir.patch new file mode 100644 index 0000000000000000000000000000000000000000..69cdb339d2e438af35ca4c5b1df9a0941d54d139 --- /dev/null +++ b/fix-timestampdir.patch @@ -0,0 +1,39 @@ +From 07946d8b9dd6b56772c873722d122b74ab8d959a Mon Sep 17 00:00:00 2001 +From: weidong +Date: Tue, 19 Jan 2021 10:57:38 +0800 +Subject: [PATCH] Fix timestampdir + +--- + configure | 2 +- + m4/sudo.m4 | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/configure b/configure +index 2ef7f19..cbbde58 100755 +--- a/configure ++++ b/configure +@@ -26658,7 +26658,7 @@ EOF + $as_echo_n "checking for sudo run dir location... " >&6; } + if test -n "$with_rundir"; then + rundir="$with_rundir" +-elif test "$runstatedir" != '${localstatedir}/run'; then ++elif test -n "$runstatedir" && test "$runstatedir" != '${localstatedir}/run'; then + rundir="$runstatedir/sudo" + else + # No --with-rundir or --runstatedir specified +diff --git a/m4/sudo.m4 b/m4/sudo.m4 +index a5a972b..b3a40b2 100644 +--- a/m4/sudo.m4 ++++ b/m4/sudo.m4 +@@ -120,7 +120,7 @@ dnl + AC_DEFUN([SUDO_RUNDIR], [AC_MSG_CHECKING(for sudo run dir location) + if test -n "$with_rundir"; then + rundir="$with_rundir" +-elif test "$runstatedir" != '${localstatedir}/run'; then ++elif test -n "$runstatedir" && test "$runstatedir" != '${localstatedir}/run'; then + rundir="$runstatedir/sudo" + else + # No --with-rundir or --runstatedir specified +-- +2.27.0 + diff --git a/sudo.spec b/sudo.spec index 62db6a02edb5ccb51f51351ef360bb935194b282..9423eae164a941dd045612926e555eda52729ea4 100644 --- a/sudo.spec +++ b/sudo.spec @@ -1,6 +1,6 @@ Name: sudo Version: 1.9.2 -Release: 1 +Release: 2 Summary: Allows restricted root access for specified users License: ISC URL: http://www.courtesan.com/sudo/ @@ -10,6 +10,8 @@ Source1: sudoers Source2: sudo Source3: sudo-i +Patch0: fix-timestampdir.patch + Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: pam Recommends: vim-minimal @@ -35,7 +37,7 @@ plugins that use %{name}. %package_help %prep -%autosetup -n %{name}-%{version} -S git +%autosetup -n %{name}-%{version} -S git -p1 %build autoreconf -I m4 -fv --install @@ -149,6 +151,9 @@ install -p -c -m 0644 %{SOURCE3} $RPM_BUILD_ROOT/etc/pam.d/sudo-i %exclude %{_pkgdocdir}/ChangeLog %changelog +* Tue Jan 19 2021 weidong - 1.9.2-2 +- Fix timestampdir error + * Thu Aug 27 2020 wangchen - 1.9.2-1 - Type:enhancement - ID:NA