aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--trunk/conf/repos.conf27
-rw-r--r--trunk/conf/simplepkg.conf2
-rw-r--r--trunk/lib/common.sh118
-rw-r--r--trunk/src/createpkg26
-rwxr-xr-xtrunk/src/rebuildpkg7
-rwxr-xr-xtrunk/src/simplaret29
-rwxr-xr-xtrunk/src/simpletrack6
-rwxr-xr-xtrunk/src/templatepkg2
-rwxr-xr-xtrunk/utils/add-slack-required2
-rwxr-xr-xtrunk/utils/repos6
-rwxr-xr-xtrunk/utils/searchpkg4
11 files changed, 168 insertions, 61 deletions
diff --git a/trunk/conf/repos.conf b/trunk/conf/repos.conf
index c8ec161..c1ebb7b 100644
--- a/trunk/conf/repos.conf
+++ b/trunk/conf/repos.conf
@@ -6,9 +6,9 @@
# local integration: the following lines makes packages created with
# createpkg automatic available to simplaret
ROOT-i486="local%file:///var/simplepkg/repos/slackware"
-ROOT-x86_64="local%file:///var/simplepkg/repos/slamd64"
-ROOT-powerpc="local%file:///var/simplepkg/repos/slackintosh"
+ROOT-x86_64="local%file:///var/simplepkg/repos/slackware64"
ROOT-s390="local%file:///var/simplepkg/repos/slack390"
+ROOT-powerpc="local%file:///var/simplepkg/repos/slackintosh"
# slackware root repositories
ROOT-i486="sarava%http://slack.sarava.org/packages/slackware/"
@@ -22,18 +22,23 @@ ROOT-powerpc="workaround%http://slackintosh.workaround.ch/pub/slackintosh/"
# s390 root definitions
ROOT-s390="ibiblio%http://distro.ibiblio.org/pub/linux/distributions/slack390/"
-# slamd64 root repositories
-#ROOT-x86_64="sarava%http://slack.sarava.org/packages/slamd64/"
-ROOT-x86_64="slackadelic%http://mirror1.slackadelic.com/slamd64/"
-ROOT-x86_64="heanet%http://ftp.heanet.ie/pub/slamd64/"
+# slackware64 root repositories
+ROOT-x86_64="sarava%http://slack.sarava.org/packages/slackware/"
+ROOT-x86_64="tds%http://slackware.mirrors.tds.net/pub/slackware/"
+ROOT-x86_64="easynews%http://slackware.mirrors.easynews.com/linux/slackware/"
+ROOT-x86_64="gwdg%http://ftp.gwdg.de/pub/linux/slackware/"
+
+# If you want to use Slamd instead of Slackware64, please uncoment the next
+# definition and make sure to comment out all other x86_64 definitions
+#ROOT-x86_64="slackadelic%http://mirror1.slackadelic.com/slamd64/"
+#ROOT-x86_64="heanet%http://ftp.heanet.ie/pub/slamd64/"
-# If you want to use Bluewhite64 instead of Slamd64, please uncoment the
-# next line and make sure to comment out all other slamd64 repository definitions
+# If you want to use Bluewhite instead of Slackware64, please uncoment the next
+# definition and make sure to comment out all other x86_64 definitions
#ROOT-x86_64="bluewhite64%http://mirror.inode.at/data/bluewhite64/"
-# If you want to use Sflack instead of Slamd64 or Bluewhite64, please uncoment
-# the next line and make sure to comment out all other slamd64 and Bluewhite64
-# repository definitions
+# If you want to use Sflack instead of Slackware64, please uncoment the next
+# definition and make sure to comment out all other x86_64 definitions
#ROOT-x86_64="bluewhite64%http://webftp.slackarea.net/pub/sflack/"
# noarch
diff --git a/trunk/conf/simplepkg.conf b/trunk/conf/simplepkg.conf
index d5fc1b7..26c6657 100644
--- a/trunk/conf/simplepkg.conf
+++ b/trunk/conf/simplepkg.conf
@@ -16,7 +16,7 @@
# Default version: set this option if you dont want simplepkg
# to use the value from /etc/slackware-version
-# DEFAULT_VERSION="12.2"
+# DEFAULT_VERSION="13.0"
# Temporary folder
TMP="/tmp/simplepkg"
diff --git a/trunk/lib/common.sh b/trunk/lib/common.sh
index 0f2edcd..2453099 100644
--- a/trunk/lib/common.sh
+++ b/trunk/lib/common.sh
@@ -29,13 +29,98 @@ SIMPLARET="simplaret"
# pkgtool functions
# -----------------------------------------------
+function pkg_ext {
+
+ # list all possible package extensions
+ echo .tgz .tbz .tlz .txz
+
+}
+
+function pkg_ext_grep {
+
+ # list all possible package extensions
+ # grep extended regexp version
+
+ local period
+
+ if [ "$1" == "." ]; then
+ $period="."
+ fi
+
+ for ext in `pkg_ext`; do
+ exts="$exts|$period$ext"
+ done
+ echo $exts
+
+}
+
+function pkg_ext_sed {
+
+ # list all possible package extensions
+ # sed regexp version
+
+ local period
+
+ if [ "$1" == "." ]; then
+ $period="."
+ fi
+
+ exts="\("
+ for ext in `pkg_ext`; do
+ exts="$exts\|$period$ext"
+ done
+ exts="\)"
+ echo $exts
+
+}
+
+function pkg_ext_find {
+
+ # list all possible package extensions
+ # find expr version
+
+ local match
+
+ if [ ! -z "$1" ]; then
+ match="$1"
+ else
+ match="*"
+ fi
+
+ exts="("
+ for ext in `pkg_ext`; do
+ exts="$exts -or -name $match.$ext"
+ done
+ exts=")"
+ echo $exts
+
+}
+
+function strip_basename {
+
+ file="$1"
+ shift
+ for ext in $*; do
+ file="`basename $file $ext`"
+ done
+ echo $file
+
+}
+
+function strip_pkg_ext {
+
+ strip_basename $1 `pkg_ext`
+
+}
+
function package_name {
# get the package name
# in some places (like in /var/log/packages), the package name is appended with
- # an -upgrade information that should be striped
- basename $1 .tgz | sed -e 's/-upgraded-[0-9]*-[0-9]*-[0-9]*,[0-9]*:[0-9]*:[0-9]*$//' \
- -e 's/-[^-]*-[^-]*-[^-]*$//'
+ # an -upgraded information that should be striped
+ strip_pkg_ext $1 | \
+ sed -e 's/-upgraded-[0-9]*-[0-9]*-[0-9]*,[0-9]*:[0-9]*:[0-9]*$//' \
+ -e 's/-[^-]*-[^-]*-[^-]*$//'
}
@@ -57,7 +142,7 @@ function package_arch {
# get ARCH from a package name
local file pack arch
- basename $1 | sed -e 's/.*\-\(.*\)\-.*.tgz$/\1/' -e 's/_slamd64$//g' -e 's/_sflack$//g'
+ basename $1 | sed -e "s/.*\-\(.*\)\-.*.$(pkg_ext_sed)$/\1/" -e 's/_slamd64$//g' -e 's/_sflack$//g'
}
@@ -65,7 +150,14 @@ function package_build {
# get BUILD from a package name
local file pack build
- basename $1 | sed -e 's/.*\-.*\-\(.*\).tgz$/\1/'
+ basename $1 | sed -e "s/.*\-.*\-\(.*\).$(pkg_ext_sed)$/\1/"
+
+}
+
+function package_ext {
+
+ # get EXT from a package name
+ echo $1 | sed -e "s/.*$(pkg_ext_sed)$/\1/"
}
@@ -1150,7 +1242,7 @@ function gen_filelist {
# generate FILELIST.TXT
# usage: gen_filelist
- find . -type f -name '*.tgz' -follow -print | sort | tr '\n' '\0' | \
+ find . -type f $(pkg_ext_find) -follow -print | sort | tr '\n' '\0' | \
xargs -0r ls -ldL --time-style=long-iso > FILELIST.TXT
echo "Created new FILELIST.TXT"
@@ -1172,7 +1264,7 @@ function gen_patches_filelist {
cd $folder
- find . -type f -name '*.tgz' -follow -print | sort | tr '\n' '\0' | \
+ find . -type f $(pkg_ext_find) -follow -print | sort | tr '\n' '\0' | \
xargs -0r ls -ldL --time-style=long-iso > FILE_LIST
svn_add FILE_LIST
@@ -1238,7 +1330,7 @@ function gen_md5_checksums {
echo 'MD5 digest for files in this directory.' > CHECKSUMS.md5
echo '' >> CHECKSUMS.md5
- find . -type f -name '*.tgz' -exec md5sum {} \; >> CHECKSUMS.md5
+ find . -type f $(pkg_ext_find) -exec md5sum {} \; >> CHECKSUMS.md5
cat CHECKSUMS.md5 | gzip -9 -c - > CHECKSUMS.md5.gz
svn_add CHECKSUMS.md5
@@ -1304,18 +1396,18 @@ function gen_meta {
file="$1"
fi
- if [ "`echo $file | grep -E '(.*{1,})\-(.*[\.\-].*[\.\-].*).tgz[ ]{0,}$'`" == "" ]; then
+ if [ "`echo $file | grep -E "(.*{1,})\-(.*[\.\-].*[\.\-].*).$(pkg_ext_grep)[ ]{0,}$"`" == "" ]; then
return
fi
- NAME=$(echo $file | sed -re "s/(.*\/)(.*.tgz)$/\2/")
- LOCATION=$(echo $file | sed -re "s/(.*)\/(.*.tgz)$/\1/")
+ NAME=$(echo $file | sed -re "s/(.*\/)(.*.$(pkg_ext_sed))$/\2/")
+ LOCATION=$(echo $file | sed -re "s/(.*)\/(.*.$(pkg_ext_sed))$/\1/")
SIZE=$( expr `gunzip -l $file | tail -n 1 | awk '{ print $1 }'` / 1024 )
USIZE=$( expr `gunzip -l $file | tail -n 1 | awk '{ print $2 }'` / 1024 )
REQUIRED=$(tar xzfO $file install/slack-required 2>/dev/null | grep -v -e "^#" | xargs -r -iZ echo -n "Z," | sed -e "s/,$//")
CONFLICTS=$(tar xzfO $file install/slack-conflicts 2>/dev/null | grep -v -e "^#" | xargs -r -iZ echo -n "Z," | sed -e "s/,$//")
SUGGESTS=$(tar xzfO $file install/slack-suggests 2>/dev/null | grep -v -e "^#" | xargs -r )
- METAFILE=${NAME%tgz}meta
+ METAFILE="$(strip_pkg_exp $NAME).meta"
echo "PACKAGE NAME: $NAME" > $LOCATION/$METAFILE
@@ -1336,7 +1428,7 @@ function gen_meta {
echo "" >> $LOCATION/$METAFILE
echo "Created metafile for `basename $file`"
- ( cd `dirname $file` && svn_add `basename $file .tgz`.meta )
+ ( cd `dirname $file` && svn_add `strip_pkg_exp $file`.meta )
}
diff --git a/trunk/src/createpkg b/trunk/src/createpkg
index 579f2c8..65af714 100644
--- a/trunk/src/createpkg
+++ b/trunk/src/createpkg
@@ -426,13 +426,14 @@ function remove_old_package_data {
cd $makepkg_repos
# Using -mindepth 2 so it doesn't delete the new PACKAGE
- for file in `find . -mindepth 2 -name "$PACKAGE-*-*-*.tgz" -o -name "$PACKAGE-*-*-*.meta" -o -name "$PACKAGE-*-*-*.tgz.asc"`; do
+ for file in `find . -mindepth 2 $(pkg_ext_find $PACKAGE-*-*-*) -o -name "$PACKAGE-*-*-*.meta" -o -name "$PACKAGE-*-*-*.*.asc"`; do
candidate="`echo $file | sed -e 's/\.meta$/\.tgz/'`" # otherwise PACKAGE info functions can fail
candidate="`echo $candidate | sed -e 's/\.asc$//'`" # otherwise PACKAGE info functions can fail
# Just delete packages with different arch, version, build number or folder
if [ "`package_version $candidate`" != "$PACKAGE_VERSION" ] || \
[ "`package_arch $candidate`" != "$PACKAGE_ARCH" ] || \
[ "`package_build $candidate`" != "$PACKAGE_BUILD" ] || \
+ [ "`package_ext $candidate`" != "$PACKAGE_EXT" ] || \
[ "`dirname $candidate | sed -e 's/^\.\///'`" != "`dirname $SUBFOLDER/$PKG_NAME | sed -e 's/^\.\///'`" ]; then
svn_del $file
fi
@@ -450,9 +451,9 @@ function remove_old_package_data {
else
# Using -mindepth 2 so it doesn't delete the new package
- find $makepkg_repos -mindepth 2 -name "$PACKAGE-*-*-*.tgz" -exec rm {} 2>/dev/null \;
+ find $makepkg_repos -mindepth 2 $(package_ext_find $PACKAGE-*-*-*) -exec rm {} 2>/dev/null \;
find $makepkg_repos -mindepth 2 -name "$PACKAGE-*-*-*.meta" -exec rm {} 2>/dev/null \;
- find $makepkg_repos -mindepth 2 -name "$PACKAGE-*-*-*.tgz.asc" -exec rm {} 2>/dev/null \;
+ find $makepkg_repos -mindepth 2 -name "$PACKAGE-*-*-*.*.asc" -exec rm {} 2>/dev/null \;
find $makepkg_repos -name "$PACKAGE.slack-required" -exec rm {} 2>/dev/null \;
fi
fi
@@ -485,7 +486,7 @@ function update_metadata {
found_patch="no"
- for file in `find patches/ -name "$PACKAGE-*-*-*.tgz"`; do
+ for file in `find patches/ $(package_ext_find $PACKAGE-*-*-*)`; do
found_patch="yes"
update_md5_checksum $makepkg_repos/patches patches/$SUBFOLDER/$PKG_NAME
done
@@ -512,7 +513,7 @@ function list_packages {
for repository in $repositories; do
echo "Packages from $repository..."
- find $repository -name '*.tgz'
+ find $repository $(package_ext_find)
done
}
@@ -538,9 +539,9 @@ function remove_package {
cd $repository
- for file in `find . -name "$package-*-*-*.tgz" -o -name "$package-*-*-*.meta" -o -name "$package-*-*-*.tgz.asc"`; do
+ for file in `find . $(package_ext_find $package-*-*-*) -o -name "$package-*-*-*.meta" -o -name "$package-*-*-*.*.asc"`; do
svn_del $file
- if [ -e "CHECKSUMS.md5" ] && echo $file | grep -q -e ".tgz$"; then
+ if [ -e "CHECKSUMS.md5" ] && echo $file | grep -q -E -e "$(pkg_ext_grep)$"; then
# remove md5 information
sed -i "/ \.*\/*$(regexp_slash $file)$/d" CHECKSUMS.md5
cat CHECKSUMS.md5 | gzip -9 -c - > CHECKSUMS.md5.gz
@@ -579,7 +580,7 @@ function sign_package {
cd $repository
- for file in `find . -name "$package-*-*-*.tgz"`; do
+ for file in `find . $(pkg_ext_find $package-*-*-*)`; do
echo "Signing package..."
@@ -748,11 +749,12 @@ function create_package {
fi
# Get package name, arch, version and build number
- PKG_NAME="`ls -1 -c $PACKAGES_DIR/$PACKAGE-*-*-*.tgz | head -n 1 | xargs basename`"
+ PKG_NAME="`ls -1 -c $PACKAGES_DIR/$PACKAGE-*-*-*.* | grep -E -e "$(pkg_ext_grep)$" | head -n 1 | xargs basename`"
PACKAGE_NAME="`package_name $PKG_NAME`"
PACKAGE_VERSION="`package_version $PKG_NAME`"
PACKAGE_ARCH="`package_arch $PKG_NAME`"
PACKAGE_BUILD="`package_build $PKG_NAME`"
+ PACKAGE_EXT="`package_ext $PKG_NAME`"
# Update package author
if [ ! -z "$CREATEPKG_AUTHOR" ]; then
@@ -761,8 +763,8 @@ function create_package {
echo "Changing package build author..."
BUILD_NUMBER="`echo $PACKAGE_BUILD | sed -e "s/$AUTHOR$//"`"
NEW_BUILD="$BUILD_NUMBER""$CREATEPKG_AUTHOR"
- mv $PACKAGES_DIR/$PKG_NAME $PACKAGES_DIR/$PACKAGE_NAME-$PACKAGE_VERSION-$PACKAGE_ARCH-$NEW_BUILD.tgz
- PKG_NAME="$PACKAGE_NAME-$PACKAGE_VERSION-$PACKAGE_ARCH-$NEW_BUILD.tgz"
+ mv $PACKAGES_DIR/$PKG_NAME $PACKAGES_DIR/$PACKAGE_NAME-$PACKAGE_VERSION-$PACKAGE_ARCH-$NEW_BUILD.$PACKAGE_EXT
+ PKG_NAME="$PACKAGE_NAME-$PACKAGE_VERSION-$PACKAGE_ARCH-$NEW_BUILD.$PACKAGE_EXT"
PACKAGE_BUILD="$NEW_BUILD"
AUTHOR="$CREATEPKG_AUTHOR"
echo "New package name is $PKG_NAME."
@@ -849,7 +851,7 @@ function create_package {
create_repo_folder $NOARCH_DIR
remove_old_package_data $NOARCH_DIR
svn_copy $NEW_REPOS/$PKG_NAME $NOARCH_DIR/$SUBFOLDER/
- svn_copy $NEW_REPOS/`basename $PKG_NAME .tgz`.meta $NOARCH_DIR/$SUBFOLDER/
+ svn_copy $NEW_REPOS/`strip_pkg_ext $PKG_NAME`.meta $NOARCH_DIR/$SUBFOLDER/
svn_copy $NEW_REPOS/`basename $PKG_NAME`.asc $NOARCH_DIR/$SUBFOLDER/
svn_copy $NEW_REPOS/$PACKAGE.slack-required $NOARCH_DIR/$SUBFOLDER/
update_metadata $NOARCH_DIR
diff --git a/trunk/src/rebuildpkg b/trunk/src/rebuildpkg
index 6d3d10c..65315ad 100755
--- a/trunk/src/rebuildpkg
+++ b/trunk/src/rebuildpkg
@@ -18,7 +18,6 @@
#
COMMON="/usr/libexec/simplepkg/common.sh"
-TMP="/tmp"
function usage {
echo "usage: ROOT=/otherroot `basename $0` <package-name>"
@@ -82,6 +81,6 @@ if [ -f "$ROOT/var/log/scripts/$package_name" ]; then
cp $ROOT/var/log/scripts/$package_name $TMP/package-$pack/install/doinst.sh
fi
-makepkg $package_name.tgz
-mv $package_name.tgz $TMP/
-echo "done: package rebuilt and stored at $TMP/$package_name.tgz"
+makepkg $package_name.$MKBUILD_COMPRESS
+mv $package_name.$MKBUILD_COMPRESS $TMP/
+echo "done: package rebuilt and stored at $TMP/$package_name.$MKBUILD_COMPRESS"
diff --git a/trunk/src/simplaret b/trunk/src/simplaret
index 04281f2..b981867 100755
--- a/trunk/src/simplaret
+++ b/trunk/src/simplaret
@@ -240,7 +240,11 @@ function simplaret_repository_url {
if [ "$repos_type" == "root" ]; then
simplaret_set_arch
- repository_url="$repository_url/`basename $repository_url`-$VERSION/"
+ distro="`basename $repository_url`"
+ if [ "$ARCH" == "x86_64" && "$distro" == "slackware" ]; then
+ distro="slackware64"
+ fi
+ repository_url="$repository_url/$distro-$VERSION/"
fi
}
@@ -294,9 +298,9 @@ function simplaret_find_package {
# usage: simplaret_find_package <package-name|-all> <repository-folder>
if [ "$1" == "-all" ]; then
- grep -e ".tgz$" $2/`simplaret_filelist` | awk '{ print $8 }'
+ grep -E -e "$(pkg_ext_grep .)$" $2/`simplaret_filelist` | awk '{ print $8 }'
else
- grep $1 $2/`simplaret_filelist` | awk '{ print $8 }' | grep -e ".tgz$"
+ grep $1 $2/`simplaret_filelist` | awk '{ print $8 }' | grep -E -e "$(pkg_ext_grep .)$"
fi
}
@@ -465,7 +469,7 @@ function simplaret_purge {
simplaret_set_storage_folder
for file in `find $storage/ $mtime 2> /dev/null`; do
- for extension in tgz asc meta txt slack-required; do
+ for extension in `pkg_ext` asc meta txt slack-required; do
if echo $file | grep -qe ".$extension$"; then
rm $file
fi
@@ -495,6 +499,7 @@ function simplaret_search_and_delete {
# searching by full package filename
name_version="`package_version $1`"
name_build="`package_build $1`"
+ name_ext="`package_ext $1`"
# search wheter the package filename is in the repositories
if [ "`simplaret_search $1 | grep $1 | wc -l`" == "0" ]; then
@@ -502,14 +507,16 @@ function simplaret_search_and_delete {
return 1
fi
- for file in `find $2/ -name $name*tgz 2> /dev/null`; do
+ for file in `find $2/ $(pkg_ext_find $name*) 2> /dev/null`; do
candidate="`basename $file`"
version="`package_version $candidate`"
build="`package_build $candidate`"
+ ext="`package_ext $candidate`"
if [ "`package_name $candidate`" == "$name" ]; then
if [ "$name_version" == "$version" ] && \
- [ "$name_build" == "$build" ]; then
+ [ "$name_build" == "$build" ] && \
+ [ "$name_ext" == "$ext" ]; then
LAST_DOWNLOADED_PACKAGE="$file"
if [ "$3" != "--silent" ]; then
echo Package $candidate already downloaded
@@ -521,7 +528,7 @@ function simplaret_search_and_delete {
return 1
else
place="`dirname $file`"
- basename="`basename $file tgz`"
+ basename="`strip_pkg_ext $file`"
rm -f $file
rm -f $place/$candidate.slack-required
rm -f $file.asc $place/$basename.meta $place/$basename.txt
@@ -533,17 +540,19 @@ function simplaret_search_and_delete {
else
- for file in `find $2/ -name $name*tgz 2> /dev/null`; do
+ for file in `find $2/ $(pkg_ext_find $name*) 2> /dev/null`; do
candidate="`basename $file`"
version="`package_version $candidate`"
build="`package_build $candidate`"
+ ext="`package_ext $candidate`"
if [ "`package_name $candidate`" == "$name" ]; then
# check if has the same version and build number, otherwise erase the old one
for result in `simplaret_search $(package_name $candidate) --basename-only`; do
if [ "`package_name $candidate`" == "`package_name $result`" ]; then
if [ "$version" == "`package_version $result`" ] && \
- [ "$build" == "`package_build $result`" ]; then
+ [ "$build" == "`package_build $result`" ] && \
+ [ "$ext" == "`package_ext $result`" ]; then
LAST_DOWNLOADED_PACKAGE="$file"
if [ "$3" != "--silent" ]; then
echo Package $candidate already downloaded
@@ -555,7 +564,7 @@ function simplaret_search_and_delete {
return 1
else
place="`dirname $file`"
- basename="`basename $file tgz`"
+ basename="`strip_pkg_ext $file`"
rm -f $file
rm -f $place/$candidate.slack-required
rm -f $file.asc $place/$basename.meta $place/$basename.txt
diff --git a/trunk/src/simpletrack b/trunk/src/simpletrack
index c643a89..31b7225 100755
--- a/trunk/src/simpletrack
+++ b/trunk/src/simpletrack
@@ -21,19 +21,19 @@ BASENAME="`basename $0`"
function slacktrack {
- $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.tgz" "./$2"
+ $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.$MKBUILD_COMPRESS" "./$2"
}
function slacktrack-real {
- $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.tgz" "./$2"
+ $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.$MKBUILD_COMPRESS" "./$2"
}
function altertrack {
- $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.tgz" "./$2"
+ $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.$MKBUILD_COMPRESS" "./$2"
}
diff --git a/trunk/src/templatepkg b/trunk/src/templatepkg
index 2d1ada2..c107bd8 100755
--- a/trunk/src/templatepkg
+++ b/trunk/src/templatepkg
@@ -884,7 +884,7 @@ function package_template {
cd $TMP/templatepkg
- makepkg -c n -l y $TMP/template-$template-$version-noarch-$build.tgz
+ makepkg -c n -l y $TMP/template-$template-$version-noarch-$build.$MKBUILD_COMPRESS
cd $TMP
rm -rf templatepkg
diff --git a/trunk/utils/add-slack-required b/trunk/utils/add-slack-required
index 67804d0..c1e25ca 100755
--- a/trunk/utils/add-slack-required
+++ b/trunk/utils/add-slack-required
@@ -51,7 +51,7 @@ function search_and_copy_slackbuild {
}
-for package in `find $repository/ -name *tgz`; do
+for package in `find $repository/ $(pkg_ext_find)`; do
pack="`package_name $package`"
for build_script in `find $slackbuild/ -name $pack.SlackBuild`; do
diff --git a/trunk/utils/repos b/trunk/utils/repos
index e4a17ee..57ecdff 100755
--- a/trunk/utils/repos
+++ b/trunk/utils/repos
@@ -30,7 +30,7 @@ function usage {
function do_all {
- for pkg in `find . -type f -name '*.tgz' -print`; do
+ for pkg in `find . -type f $(pkg_ext_find) -print`; do
gen_meta $pkg
done
$0 PACKAGESTXT
@@ -55,8 +55,8 @@ case "$1" in
do_all
;;
new)
- for pkg in `find . -type f -name '*.tgz' -print`; do
- if [ ! -f ${pkg%tgz}meta ]; then
+ for pkg in `find . -type f $(pkg_ext_find) -print`; do
+ if [ ! -f $(strip_pkg_ext $pkg).meta ]; then
gen_meta $pkg
fi
done
diff --git a/trunk/utils/searchpkg b/trunk/utils/searchpkg
index cc5a827..1986e00 100755
--- a/trunk/utils/searchpkg
+++ b/trunk/utils/searchpkg
@@ -30,7 +30,7 @@ FILELIST="$1/FILELIST.TXT"
PACKAGE_FIELD="8"
if [ -z "$2" ]; then
- grep .tgz $FILELIST
+ grep -E -e "$(pkg_ext_grep)" $FILELIST
else
- grep -e "$2" $FILELIST | grep tgz | awk "{ print \$$PACKAGE_FIELD }"
+ grep -e "$2" $FILELIST | grep -E -e "$(pkg_ext_grep)" | awk "{ print \$$PACKAGE_FIELD }"
fi