diff --git a/bash-4.2-nsec.dif b/bash-4.2-nsec.dif new file mode 100644 index 00000000..f3be2828 --- /dev/null +++ b/bash-4.2-nsec.dif @@ -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); diff --git a/bash.spec b/bash.spec index 8f20d499..dbe197b3 100644 --- a/bash.spec +++ b/bash.spec @@ -73,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 @@ -281,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 @@ -571,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