mirror of
https://github.com/sbopkg/sbopkg
synced 2024-12-27 09:58:28 +01:00
tweak update code to remove EXTRA variables; add OO.o hack; add debug output when sbopkg thinks there is a newer version installed than in repo
This commit is contained in:
parent
5786a8cefb
commit
0e6c1c9f43
1 changed files with 9 additions and 8 deletions
|
@ -201,10 +201,7 @@ potential updates..." >> $UPDATELIST
|
|||
NAME=$(expr $INDEX - 3)
|
||||
NAME="$(echo $STRING | cut -f 1-$NAME -d -)"
|
||||
VER=$(expr $INDEX - 2)
|
||||
#VER="$(echo $STRING | cut -f $VER -d - | sed -e 's/_.*$//')"
|
||||
VER="$(echo $STRING | cut -f $VER -d -)"
|
||||
#EXTRA=$(expr $INDEX - 2)
|
||||
#EXTRA="$(echo $STRING | cut -f $EXTRA -d _)"
|
||||
ARCH=$(expr $INDEX - 1)
|
||||
ARCH="$(echo $STRING | cut -f $ARCH -d -)"
|
||||
BUILD="$(echo $STRING | cut -f $INDEX -d -)"
|
||||
|
@ -215,22 +212,26 @@ potential updates..." >> $UPDATELIST
|
|||
if [ -n "$NEWINFO" ]; then
|
||||
. $NEWINFO
|
||||
NEWARCH=$(egrep -m1 "^ARCH" $NEWSB | sed -e 's/[ #}\t].*$//;s/^.*[=-]//;s/\"//g')
|
||||
NEWSRCVER=$(egrep -m1 "^SRCVER" $NEWSB | sed -e 's/[ #}\t].*$//;s/^.*[=-]//;s/\"//g')
|
||||
#NEWARCH=$(egrep -m1 "^ARCH" $NEWSB | sed -e 's/^.*[=-]//;s/\"//;s/[ #}\t].*$//g')
|
||||
NEWSRCVER=$(egrep -m1 "^SRCVER" $NEWSB | sed -e 's/[ #}\t].*$//;s/^.*[=-]/_/;s/\"//g')
|
||||
# Ugly hack for openoffice.org
|
||||
if [ $PRGNAM = "openoffice.org" ]; then
|
||||
NEWSRCVER=$(egrep -m1 "^OOLANG" $NEWSB | sed -e 's/[ #}\t].*$//;s/^.*://;s/-/_/g')
|
||||
fi
|
||||
NEWBUILD=$(egrep -m1 "^BUILD" $NEWSB | sed -e 's/^.*[=-]//;s/\"//;s/[ #}\t].*$//g')
|
||||
if [[ $VERSION-$NEWARCH-$NEWBUILD > $VER-$ARCH-$BUILD ]]; then
|
||||
if [[ $VERSION$NEWSRCVER-$NEWARCH-$NEWBUILD > $VER-$ARCH-$BUILD ]]; then
|
||||
echo $NAME: >> $UPDATELIST
|
||||
echo " POTENTIAL UPDATE" >> $UPDATELIST
|
||||
echo " Installed version: " $CURPKG >> $UPDATELIST
|
||||
echo " Repo version: " $PRGNAM-$VERSION-$NEWARCH-$NEWBUILD >> $UPDATELIST
|
||||
elif [[ $VERSION-$NEWARCH-$NEWBUILD < $VER-$ARCH-$BUILD ]]; then
|
||||
elif [[ $VERSION$NEWSRCVER-$NEWARCH-$NEWBUILD < $VER-$ARCH-$BUILD ]]; then
|
||||
if [ "$UPDATE_DEBUG" = 1 ]; then
|
||||
echo $NAME: >> $UPDATELIST
|
||||
echo " INSTALLED PACKAGE IS NEWER THAN REPO" >> $UPDATELIST
|
||||
echo " Installed version: " $CURPKG >> $UPDATELIST
|
||||
echo " Repo version: " $PRGNAM-$VERSION-$NEWARCH-$NEWBUILD >> $UPDATELIST
|
||||
echo " Debug: " $VERSION$NEWSRCVER-$NEWARCH-$NEWBUILD >> $UPDATELIST
|
||||
fi
|
||||
elif [[ $VERSION-$NEWARCH-$NEWBUILD = $VER-$ARCH-$BUILD ]]; then
|
||||
elif [[ $VERSION$NEWSRCVER-$NEWARCH-$NEWBUILD = $VER-$ARCH-$BUILD ]]; then
|
||||
if [ "$UPDATE_DEBUG" = 1 ]; then
|
||||
echo $NAME: >> $UPDATELIST
|
||||
echo " No update." >> $UPDATELIST
|
||||
|
|
Loading…
Reference in a new issue