diff options
Diffstat (limited to 'rpm')
-rw-r--r-- | rpm | 22 |
1 files changed, 22 insertions, 0 deletions
@@ -0,0 +1,22 @@ +#!/bin/sh + +rpm --showrc | grep macrofiles | sed 's/$/:\.\/rpmmacros/' > rpmrc +echo %_sourcedir $PWD/SOURCES > rpmmacros +echo %_rpmdir $PWD/RPMS >> rpmmacros +echo %_srcrpmdir $PWD/SRPMS >> rpmmacros +echo >> rpmmacros + +if test -f $HOME/.rpmrc; then + mv $HOME/.rpmrc $HOME/.rpmrcsave + cat $HOME/.rpmrcsave ./rpmrc > $HOME/.rpmrc +else + cat ./rpmrc > $HOME/.rpmrc +fi + +rpm $@ + +if test -f $HOME/.rpmrcsave; then + mv $HOME/.rpmrcsave $HOME/.rpmrc +else + rm $HOME/.rpmrc +fi |