Improving scriptlet related rpm plugin hooks.
authorElena Reshetova <elena.reshetova@intel.com>
Thu, 22 Nov 2012 18:49:27 +0000 (20:49 +0200)
committerAnas Nashif <anas.nashif@intel.com>
Sun, 3 Feb 2013 00:44:45 +0000 (16:44 -0800)
commit78b3ad646be7c502f0e9b7d1b76de76ba50601ca
treebaed6eccbcffabf34788215da13f264a57e73d48
parentdca7f1cdfdcdee92e0c4e835e40472f59660d2b4
Improving scriptlet related rpm plugin hooks.

Three new hooks added:
PLUGINHOOK_SCRIPTLET_PRE_FUNC
Called before scriptlet execution
PLUGINHOOK_SCRIPTLET_FORK_POST_FUNC
Called after fork() but before scriptlet execution
PLUGINHOOK_SCRIPTLET_POST_FUNC
Called after scriptlet execution

Currently pre and post hooks are called for externals and internal lua scripts.
post hook is called even if scriptlet execution has failed and
the return code is given as an argument.

fork_post hook is only called for external scriptlets,
because for internal scriptlets no fork() is currently performed.

Signed-off-by: Panu Matilainen <pmatilai@redhat.com>
lib/rpmplugins.c
lib/rpmplugins.h
lib/rpmscript.c
plugins/plugin.h