renamed local variable directive to rpmDirective as directive seems to
be a reserved word in some contexts