In /etc/rpm/macros.d/alternatives, there is a macro: %update_alternatives() [ -x /usr/sbin/alternatives-update ] && /usr/sbin/alternatives-update %* ||: %nil Using this macro in package scripts (in my case, %triggerun) results in an 'unexpected EOF' script error during package installation. A manual expansion of the macro, without the trailing %nil, is workable.
я специально делал это как функцию, были какие-то на это причины. у меня конструкция, указанная ниже, работает. %triggerpostun -- %name, %name < 1:1.4-alt6.p5 %update_alternatives