Commit da8389d8 authored by Vitaly Lipatov's avatar Vitaly Lipatov

epm repack.d/common.sh: add support for some source /opt/dir in move_to_opt

parent 0b4c6697
......@@ -252,6 +252,7 @@ move_to_opt()
from="/usr/share/$PRODUCTCUR"
[ -d "$BUILDROOT$from" ] || from="/usr/share/$PRODUCT"
[ -d "$BUILDROOT$from" ] || from="/usr/lib/$PRODUCT"
[ -d "$BUILDROOT$from" ] || from="/$(echo opt/*)"
sdir="$BUILDROOT$from"
elif has_space "$1" ; then
sdir="$BUILDROOT$1"
......@@ -270,6 +271,9 @@ move_to_opt()
[ -n "$rdir" ] || return 1 #fatal "Can't resolve $from in $BUILDROOT"
[ -d "$BUILDROOT$rdir" ] || return 1 #fatal "Can't resolve $from in $BUILDROOT"
# already there
[ "$rdir" = "$PRODUCTDIR" ] && return
[ -d "$BUILDROOT$PRODUCTDIR/" ] && return 1
mkdir -p "$BUILDROOT$(dirname "$PRODUCTDIR")/"
mv "$BUILDROOT$rdir" "$BUILDROOT$PRODUCTDIR/"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment