Accepting request 108164 from Base:System

- Add small patch for be able to use nanoseconds in comparision
  of time stamps of files (bnc#750640)

- Reenable patch for bnc#725657 with latest change from latest
  git repository of the patch.

OBS-URL: https://build.opensuse.org/request/show/108164
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/bash?expand=0&rev=92
This commit is contained in:
Stephan Kulow 2012-03-07 19:08:45 +00:00 committed by Git OBS Bridge
commit 777dc3cc7d
4 changed files with 45 additions and 8 deletions

20
bash-4.2-nsec.dif Normal file
View File

@ -0,0 +1,20 @@
--- test.c
+++ test.c 2012-03-06 11:14:00.149934027 +0000
@@ -309,8 +309,17 @@ filecomp (s, t, op)
switch (op)
{
+#if defined(_BSD_SOURCE) || defined(_SVID_SOURCE) || (defined(_XOPEN_SOURCE) && ((_XOPEN_SOURCE - 0) >= 700)) || (defined(_POSIX_C_SOURCE) && ((_POSIX_C_SOURCE - 0) >= 200809L))
+# define st_mtimcmp(t1, t2, CMP) \
+ (((t1).st_mtim.tv_sec == (t2).st_mtim.tv_sec) ? \
+ ((t1).st_mtim.tv_nsec CMP (t2).st_mtim.tv_nsec) : \
+ ((t1).st_mtim.tv_sec CMP (t2).st_mtim.tv_sec))
+ case OT: return (r1 < r2 || (r2 == 0 && st_mtimcmp(st1, st2, <)));
+ case NT: return (r1 > r2 || (r1 == 0 && st_mtimcmp(st1, st2, >)));
+#else
case OT: return (r1 < r2 || (r2 == 0 && st1.st_mtime < st2.st_mtime));
case NT: return (r1 > r2 || (r1 == 0 && st1.st_mtime > st2.st_mtime));
+#endif
case EF: return (same_file (s, t, &st1, &st2));
}
return (FALSE);

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:8901a11f0cea89d82de52b9aef89f31dafb1fb563a65259d3a1007a465047ca7
size 15223
oid sha256:cbbe11b6ddda4ec7c439ef7fa9322e20257b3d9be93db1f75a8035e23b0c3306
size 16070

View File

@ -1,3 +1,15 @@
-------------------------------------------------------------------
Tue Mar 6 12:15:18 UTC 2012 - werner@suse.de
- Add small patch for be able to use nanoseconds in comparision
of time stamps of files (bnc#750640)
-------------------------------------------------------------------
Tue Mar 6 09:33:30 UTC 2012 - werner@suse.de
- Reenable patch for bnc#725657 with latest change from latest
git repository of the patch.
-------------------------------------------------------------------
Tue Dec 20 20:01:48 UTC 2011 - coolo@suse.com

View File

@ -40,6 +40,7 @@ Summary: The GNU Bourne-Again Shell
License: GPL-2.0+
Group: System/Shells
Url: http://www.gnu.org/software/bash/bash.html
# Git: http://git.savannah.gnu.org/cgit/bash.git
Source0: ftp://ftp.gnu.org/gnu/bash/bash-%{bash_vers}.tar.gz
Source1: ftp://ftp.gnu.org/gnu/readline/readline-%{rl_vers}.tar.gz
Source2: bash-%{bash_vers}-patches.tar.bz2
@ -72,6 +73,7 @@ Patch14: bash-4.2-sigrestart.patch
Patch15: bash-3.2-longjmp.dif
Patch16: bash-4.0-setlocale.dif
Patch17: bash-4.0-headers.dif
Patch18: bash-4.2-nsec.dif
Patch20: readline-%{rl_vers}.dif
Patch21: readline-4.3-input.dif
Patch22: readline-6.1-wrap.patch
@ -255,11 +257,12 @@ as well as programming with the interface of the readline library.
%prep
%setup -q -n bash-%{bash_vers}%{extend} -b1 -b2 -b3
for p in ../bash-%{bash_vers}-patches/*; do
test -e $p || break
test "${p##*/}" = "bash-4.2-pwd.patch" && continue
echo Patch $p
patch -s -p0 < $p
for patch in ../bash-%{bash_vers}-patches/*; do
level=-p1
test -e $patch || break
[[ $(head -n 1 $patch) =~ From ]] || level=-p0
echo Patch $patch
patch -s $level < $patch
done
unset p
%patch1 -p0 -b .manual
@ -279,6 +282,7 @@ unset p
%patch15 -p0 -b .longjmp
%patch16 -p0 -b .setlocale
%patch17 -p0 -b .headers
%patch18 -p0 -b .nsec
%patch21 -p0 -b .zerotty
%patch22 -p0 -b .wrap
%patch23 -p0 -b .conf
@ -569,8 +573,9 @@ EOF
%install_info_delete --info-dir=%{_infodir} %{_infodir}/readline.info.gz
%clean
LD_LIBRARY_PATH=%{buildroot}/%{_lib} \
ldd -u -r %{buildroot}/bin/bash || true
ldd -u -r %{buildroot}%{_libdir}/libreadline.so || true
ldd -u -r %{buildroot}/%{_lib}/libreadline.so.* || true
%{?buildroot: %{__rm} -rf %{buildroot}}
%files