diff options
author | rhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4> | 2006-08-08 02:33:04 +0000 |
---|---|---|
committer | rhatto <rhatto@370017ae-e619-0410-ac65-c121f96126d4> | 2006-08-08 02:33:04 +0000 |
commit | 8933e2e0b1810533e14b14ea59a86e0a4ee5384c (patch) | |
tree | 683664118b9eb8b585b5ac8b3e39438572741325 /icecast | |
parent | 5be0a3f22cfb55960e398b41abbc8c78e43ee956 (diff) | |
download | slackbuilds-8933e2e0b1810533e14b14ea59a86e0a4ee5384c.tar.gz slackbuilds-8933e2e0b1810533e14b14ea59a86e0a4ee5384c.tar.bz2 |
icecast update
git-svn-id: svn+slack://slack.fluxo.info/var/svn/slackbuilds@18 370017ae-e619-0410-ac65-c121f96126d4
Diffstat (limited to 'icecast')
-rwxr-xr-x | icecast/icecast.SlackBuild | 57 |
1 files changed, 30 insertions, 27 deletions
diff --git a/icecast/icecast.SlackBuild b/icecast/icecast.SlackBuild index a0159355..6ee099bf 100755 --- a/icecast/icecast.SlackBuild +++ b/icecast/icecast.SlackBuild @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # $Id: icecast.SlackBuild,v 1.4 2006/02/28 15:12:47 root Exp root $ # Copyright (c) 2006 Eric Hameleers <alien@slackware.com> # Distributed under the terms of the GNU General Public License, Version 2 @@ -59,13 +59,6 @@ fi # Set initial variables: CWD="`pwd`" -PRGNAM=icecast -PACKAGE="$PRGNAM" -_VERSION="2.3.1" -_ARCH="i486" -_BUILD="1rha" -_TMP="/tmp" - if [ -f "/etc/slackbuildrc" ]; then source /etc/slackbuildrc fi @@ -74,16 +67,22 @@ if [ -f "~/.slackbuildrc" ]; then source ~/.slackbuildrc fi -if [ -z "$VERSION" ]; then - VERSION="$_VERSION" -fi +PRGNAM=icecast +PACKAGE="$PRGNAM" +#VERSION=${VERSION:=2.3.1} +VERSION=${VERSION:=2.3-kh7} +ARCH=${ARCH:=x86_64} +BUILD=${BUILD:=1rha} +TMP=${TMP:=/tmp} +SRC_DIR=${SRC:=$CWD} +REPOS=${REPOS:=$TMP} -if [ -z "$ARCH" ]; then - ARCH="$_ARCH" +if [ -f "/etc/slackbuildrc" ]; then + source /etc/slackbuildrc fi -if [ -z "$BUILD" ]; then - BUILD="$_BUILD" +if [ -f "~/.slackbuildrc" ]; then + source ~/.slackbuildrc fi if [ "$ARCH" == "x86_64" ]; then @@ -92,21 +91,15 @@ else LIBDIR=/usr/lib fi -if [ -z "$SRC" ]; then - SRC_DIR="$CWD" -else - SRC_DIR="$SRC" -fi - -if [ -z "$TMP" ]; then - TMP="$_TMP" -fi - RTOOL="wget" PACKAGE_EXT="gz" -PKG=$TMP/package-$PRGNAM SRC="$PACKAGE-$VERSION.tar.$PACKAGE_EXT" -URL="http://downloads.xiph.org/releases/$PACKAGE/$SRC" + +if echo $VERSION | grep -q "kh"; then + URL="http://www.mediacast1.com/~karl/$SRC" +else + URL="http://downloads.xiph.org/releases/$PACKAGE/$SRC" +fi if [ "$PACKAGE_EXT" == "bz2" ]; then tarflag="j" @@ -114,10 +107,18 @@ else tarflag="z" fi +SRC_DIR="$SRC_DIR/$PACKAGE" +mkdir -p $SRC_DIR + if [ "$RTOOL" == "wget" ] && [ ! -f "$SRC_DIR/$SRC" ]; then wget "$URL" -O "$SRC_DIR/$SRC" fi +TMP="$TMP/$PACKAGE" +rm -rf $TMP + +PKG=$TMP/package-$PRGNAM + if [ ! -d $TMP/tmp-$PRGNAM ]; then mkdir -p $TMP/tmp-$PRGNAM # location to build the source fi @@ -301,6 +302,8 @@ cd $PKG find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +VERSION="`echo $VERSION | sed -e 's/-/_/g'`" + makepkg --linkadd y --chown n $TMP/$PRGNAM-$VERSION-$ARCH-$BUILD.tgz (cd $TMP && md5sum $PRGNAM-$VERSION-$ARCH-$BUILD.tgz > $PRGNAM-$VERSION-$ARCH-$BUILD.tgz.md5) cat $PKG/install/slack-desc | grep "^${PRGNAM}" > $TMP/$PRGNAM-$VERSION-$ARCH-$BUILD.txt |