|
|
@ -138,13 +138,18 @@ fi
|
|
|
|
PDIR=$(cd ..; pwd)\
|
|
|
|
PDIR=$(cd ..; pwd)\
|
|
|
|
for i in %*; do\
|
|
|
|
for i in %*; do\
|
|
|
|
PROG=%{buildroot}%{_bindir}/$i\
|
|
|
|
PROG=%{buildroot}%{_bindir}/$i\
|
|
|
|
RPATH=$(chrpath $PROG| sed -e "s@^$PROG: RPATH=@@")\
|
|
|
|
if [ -x "$PROG" ]; then\
|
|
|
|
case $RPATH in\
|
|
|
|
RPATH=$(chrpath $PROG| sed -e "s@^$PROG: RPATH=@@")\
|
|
|
|
*$PDIR*)\
|
|
|
|
case $RPATH in\
|
|
|
|
NEWRPATH=$(echo $RPATH | sed -e "s@$PDIR@%{ghclibdir}@g" -e "s@/dist/build@@g")\
|
|
|
|
*$PDIR*)\
|
|
|
|
chrpath -r $NEWRPATH $PROG\
|
|
|
|
NEWRPATH=$(echo $RPATH | sed -e "s@$PDIR@%{ghclibdir}@g" -e "s@/dist/build@@g")\
|
|
|
|
;;\
|
|
|
|
chrpath -r $NEWRPATH $PROG\
|
|
|
|
esac\
|
|
|
|
;;\
|
|
|
|
|
|
|
|
esac\
|
|
|
|
|
|
|
|
else\
|
|
|
|
|
|
|
|
echo "%ghc_fix_dynamic_rpath: no such file $PROG"\
|
|
|
|
|
|
|
|
exit 1\
|
|
|
|
|
|
|
|
fi\
|
|
|
|
done\
|
|
|
|
done\
|
|
|
|
%endif\
|
|
|
|
%endif\
|
|
|
|
%{nil}
|
|
|
|
%{nil}
|
|
|
|