mirror of
https://gitlab.com/mateslackbuilds/msb.git
synced 2024-12-27 09:58:14 +01:00
Update Build Deps Script
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackware-id.org>
This commit is contained in:
parent
94a1f34d87
commit
9808266e0d
1 changed files with 9 additions and 6 deletions
|
@ -67,14 +67,17 @@ for dir in \
|
|||
deps/liboobs \
|
||||
; do
|
||||
# Get the package name
|
||||
package=$(echo $dir | cut -f2- -d /)
|
||||
|
||||
package=$(echo $dir | cut -f2- -d /)
|
||||
|
||||
# Change to package directory
|
||||
cd $MSBROOT/$dir || exit 1
|
||||
cd $MSBROOT/$dir || exit 1
|
||||
|
||||
# Get the version
|
||||
version=$(cat ${package}.SlackBuild | grep "VERSION:" | cut -d "-" -f2 | rev | cut -c 2- | rev)
|
||||
|
||||
# Get the build
|
||||
build=$(cat ${package}.SlackBuild | grep "BUILD:" | cut -d "-" -f2 | rev | cut -c 2- | rev)
|
||||
|
||||
# Check for duplicate sources
|
||||
sourcefile="$(ls -l $MSBROOT/$dir/${package}-*.tar.?z* | wc -l)"
|
||||
if [ $sourcefile -gt 1 ]; then
|
||||
|
@ -83,11 +86,11 @@ for dir in \
|
|||
echo "Please delete sources other than ${package}-$version to avoid problems"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
||||
# The real build starts here
|
||||
sh ${package}.SlackBuild || exit 1
|
||||
if [ "$INST" = "1" ]; then
|
||||
PACKAGE="${package}-$version-*.txz"
|
||||
PACKAGE="${package}-$version-*-${build}*.txz"
|
||||
if [ -f $TMP/$PACKAGE ]; then
|
||||
upgradepkg --install-new --reinstall $TMP/$PACKAGE
|
||||
else
|
||||
|
@ -95,7 +98,7 @@ for dir in \
|
|||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
# back to original directory
|
||||
cd $MSBROOT
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue