Michael Schröder 2016-04-21 13:24:43 +00:00 committed by Git OBS Bridge
parent ee30576c40
commit 3a3fbf43f6
7 changed files with 69 additions and 40 deletions

View File

@ -0,0 +1,27 @@
--- ./lib/psm.c.orig 2016-04-21 13:22:27.901033751 +0000
+++ ./lib/psm.c 2016-04-21 13:23:45.324742853 +0000
@@ -285,7 +285,9 @@ static rpmRC runScript(rpmts ts, rpmte t
int warn_only = (stag != RPMTAG_PREIN &&
stag != RPMTAG_PREUN &&
stag != RPMTAG_PRETRANS &&
- stag != RPMTAG_VERIFYSCRIPT);
+ stag != RPMTAG_VERIFYSCRIPT &&
+ !(stag == RPMTAG_POSTIN &&
+ rpmExpandNumeric("%{_fail_on_postinstall_errors}")));
sfd = rpmtsNotify(ts, te, RPMCALLBACK_SCRIPT_START, stag, 0);
if (sfd == NULL)
--- ./macros.in.orig 2016-04-21 13:21:58.933142657 +0000
+++ ./macros.in 2016-04-21 13:22:27.902033748 +0000
@@ -1327,6 +1327,11 @@ end}
%{-S:%{expand:%__scm_setup_%{-S*} %{!-v:-q}}}\
%{!-N:%autopatch %{-v} %{-p:-p%{-p*}}}
+# Should errors in %post scriptlet be propagated as errors?
+#
+# Note: set to 1 for legacy compatibility.
+%_fail_on_postinstall_errors 0
+
# \endverbatim
#*/

View File

@ -287,7 +287,7 @@
#------------------------------------------------------------------------------
# arch macro for all supported Sparc processors
@@ -1127,3 +1313,26 @@ end}
@@ -1127,3 +1313,24 @@ end}
# \endverbatim
#*/
@ -306,8 +306,6 @@
+%{nil}
+
+%service_add() %{fillup_and_insserv %{1}}
+%service_del_preun() %{stop_on_removal %{1}}
+%service_del_postun() %{restart_on_update %{1}}
+
+%user_group_add() \
+/usr/sbin/groupadd -r %{1} 2>/dev/null || :\

16
normalize_blocksize.diff Normal file
View File

@ -0,0 +1,16 @@
--- ./lib/transaction.c.orig 2016-04-21 12:21:53.649740302 +0000
+++ ./lib/transaction.c 2016-04-21 12:28:00.821356311 +0000
@@ -134,6 +134,13 @@ static rpmDiskSpaceInfo rpmtsCreateDSI(c
dsi->iavail = !(sfb.f_ffree == 0 && sfb.f_files == 0)
? sfb.f_ffree : -1;
+ /* normalize block size to 4096 bytes if it is too big. */
+ if (dsi->bsize > 4096) {
+ uint64_t old_size = dsi->bavail * dsi->bsize;
+ dsi->bsize = 4096; /* Assume 4k block size */
+ dsi->bavail = old_size / dsi->bsize;
+ }
+
/* Find mount point belonging to this device number */
resolved_path = realpath(dirName, mntPoint);
if (!resolved_path) {

View File

@ -1,7 +1,5 @@
Index: rpm-4.12.0.1/luaext/lposix.c
===================================================================
--- rpm-4.12.0.1.orig/luaext/lposix.c
+++ rpm-4.12.0.1/luaext/lposix.c
--- luaext/lposix.c
+++ luaext/lposix.c
@@ -361,22 +361,35 @@ static int Pfork(lua_State *L) /** for
static int Pwait(lua_State *L) /** wait([pid]) */

View File

@ -21,36 +21,9 @@
/usr/lib/rpm/brp-suse \
%{nil}
# macro: %restart_on_update()
# Used to restart a service in postun section, if we are
# not running from YaST2 in instsys on update.
%restart_on_update() \
test -n "$FIRST_ARG" || FIRST_ARG=$1 \
if test "$FIRST_ARG" -ge 1 ; then \
test -f /etc/sysconfig/services && . /etc/sysconfig/services \
if test "$YAST_IS_RUNNING" != "instsys" -a "$DISABLE_RESTART_ON_UPDATE" != yes ; then \
test -x /bin/systemctl && /bin/systemctl daemon-reload >/dev/null 2>&1 || : \
for service in %{?*} ; do \
test -x /bin/systemctl && /bin/systemctl try-restart $service >/dev/null 2>&1 || : \
done \
fi \
fi \
%nil
%restart_on_update() %{service_del_postun %{?*}}
%stop_on_removal() %{service_del_preun %{?*}}
# macro: %stop_on_removal()
# Used to stop a service in preun section, if we are
# not running from YaST2 in instsys on removal of this package.
%stop_on_removal() \
test -n "$FIRST_ARG" || FIRST_ARG=$1 \
if test "$FIRST_ARG" = "0" ; then \
test -f /etc/sysconfig/services && . /etc/sysconfig/services \
if test "$YAST_IS_RUNNING" != "instsys" -a "$DISABLE_STOP_ON_REMOVAL" != yes ; then \
for service in %{?*} ; do \
test -x /bin/systemctl && /bin/systemctl stop $service >/dev/null 2>&1 || : \
done \
fi \
fi \
%nil
# macro: %configure_kernel_source
#
#

View File

@ -1,3 +1,21 @@
-------------------------------------------------------------------
Thu Apr 21 15:08:22 CEST 2016 - mls@suse.de
- tweak rpm-4.12.0.1-lua-5.3.patch so that it does not need
the -p1 option
- add option to make postinstall scriptlet errors fatal
[bnc#967728]
new patch: enable-postin-scripts-error.diff
- rework nfs-blocksize-free.patch to always normalize big
blocksizes to 4096 bytes
[bnc#894610] [bnc#829717] [bnc#965322]
removed patch: nfs-blocksize-free.patch
new patch: normalize_blocksize.diff
- drop service_del_preun, service_del_postun macros, they are
provided by the systemd package
- change restart_on_update and stop_on_removal macros to use
service_del_preun and service_del_postun
-------------------------------------------------------------------
Fri Jan 15 19:20:15 UTC 2016 - stefan.bruens@rwth-aachen.de

View File

@ -133,7 +133,8 @@ Patch94: checksepwarn.diff
Patch95: fixsizeforbigendian.diff
Patch96: modalias-no-kgraft.diff
Patch97: rpm-4.12.0.1-lua-5.3.patch
Patch98: nfs-blocksize-free.patch
Patch98: normalize_blocksize.diff
Patch99: enable-postin-scripts-error.diff
Patch6464: auto-config-update-aarch64-ppc64le.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
#
@ -227,9 +228,7 @@ rm -f rpmdb/db.h
%patch -P 60 -P 61 -P 65 -P 66 -P 67 -P 68 -P 69
%patch -P 70 -P 71 -P 73 -P 74 -P 75 -P 76 -P 77 -P 78 -P 79
%patch -P 85
%patch -P 92 -P 93 -P 94 -P 95 -P 96
%patch97 -p1
%patch98 -p1
%patch -P 92 -P 93 -P 94 -P 95 -P 96 -P 97 -P 98 -P 99
%ifarch aarch64 ppc64le
%patch6464