Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:ALP:Workbench:1.0
rpm
enable-postin-scripts-error.diff
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File enable-postin-scripts-error.diff of Package rpm
--- lib/rpmscript.c +++ lib/rpmscript.c @@ -390,7 +390,7 @@ rpmRC rpmScriptRun(rpmScript script, int if (script == NULL) return RPMRC_OK; ARGV_t args = NULL; - rpmlogLvl lvl = (script->flags & RPMSCRIPT_FLAG_CRITICAL) ? + rpmlogLvl lvl = (rpmScriptFlags(script) & RPMSCRIPT_FLAG_CRITICAL) ? RPMLOG_ERR : RPMLOG_WARNING; rpmRC rc; int script_type = RPMSCRIPTLET_FORK | RPMSCRIPTLET_EXEC; @@ -637,5 +637,8 @@ rpmscriptTypes rpmScriptType(rpmScript s rpmscriptFlags rpmScriptFlags(rpmScript script) { - return (script != NULL) ? script->flags : 0; + rpmscriptFlags flags = (script != NULL) ? script->flags : 0; + if (script && script->tag == RPMTAG_POSTIN && rpmExpandNumeric("%{_fail_on_postinstall_errors}")) + flags |= RPMSCRIPT_FLAG_CRITICAL; + return flags; } --- macros.in +++ macros.in @@ -1293,5 +1293,10 @@ end %{expand:%__scm_setup_%{__scm} %{!-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 #*/
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor