Moderatore: Staff

. Io ho un file chiamato:essential-amd64-20071007.tar.bz2
#!/bin/sh
# Slackware build script
# Copyright 2010 Savino Liguori aka jimmy_page_89
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
CWD=`pwd`
NAME=mplayer-codecs
ARCH=`uname -m`
PKGTYPE=txz
BUILD=1
TAG=_jim
PKG=/tmp/package-$NAME
TMP=/tmp/build-$NAME
build_32()
{
VERSION=20100303
ALL=http://www.mplayerhq.hu/MPlayer/releases/codecs/all-$VERSION.tar.bz2
if [ ! -e all-$VERSION.tar.bz2 ]; then
wget -c $ALL || exit 1
fi
cd $TMP
mkdir -p $PKG/usr/lib/codecs
tar xvf $CWD/all-$VERSION.tar.bz2
cp -a all-$VERSION/* $PKG/usr/lib/codecs
}
build_64()
{
LIBDIRSUFFIX="64"
ES_NAME=essential-amd64
VERSION=20071007
MP_VERSION=20061022
AMD_COD=http://www.mplayerhq.hu/MPlayer/releases/codecs/$ES_NAME-$VERSION.tar.bz2
MP_COD=http://www.mplayerhq.hu/MPlayer/releases/codecs/$NAME-$MP_VERSION-1.x86_64.rpm
MP_EXTRA=http://www.mplayerhq.hu/MPlayer/releases/codecs/$NAME-extra-$MP_VERSION-1.${ARCH}.rpm
if [ ! -e $ES_NAME-$VERSION.tar.bz2 ]; then
wget -c $AMD_COD || exit 1
fi
if [ ! -e $NAME-$VERSION-1.x86_64.rpm ]; then
wget -c $MP_COD || exit 1
fi
if [ ! -e $NAME-extra-$MP_VERSION-1.x86_64.rpm ]; then
wget -c $MP_EXTRA || exit 1
fi
cd $TMP
mkdir -p $PKG/usr/lib$LIBDIRSUFFIX/codecs
cd $PKG
rpm2cpio < $CWD/$NAME-$MP_VERSION-1.${ARCH}.rpm | cpio -imdv
rpm2cpio < $CWD/$NAME-extra-$MP_VERSION-1.${ARCH}.rpm | cpio -imdv
cd -
tar xf $CWD/$ES_NAME-$VERSION.tar.bz2
cp -a $ES_NAME-$VERSION/* $PKG/usr/lib$LIBDIRSUFFIX/codecs
rm -rf $PKG/usr/share
}
set -e
mkdir -p $TMP $PKG
if [ "$ARCH" = "x86_64" ]; then
build_64
else
build_32
fi
cd $PKG
chown -R root:root .
find . \
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
-exec chmod 755 {} \; -o \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
( cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
)
mkdir -p $PKG/usr/doc/$NAME-$VERSION
mv $PKG/usr/lib$LIBDIRSUFFIX/codecs/README $PKG/usr/doc/$NAME-$VERSION/README
cat $CWD/$NAME.SlackBuild > $PKG/usr/doc/$NAME-$VERSION/$NAME.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
#requiredbuilder -v -y -s $CWD $PKG
makepkg -l y -c n $CWD/$NAME-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE || exit 1
rm -rf $TMP $PKG# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
mplayer-codecs: mplayer-codecs (Codecs for MPlayer)
mplayer-codecs:
mplayer-codecs: This is a repackaging of the codecs distributed by the MPlayer team.
mplayer-codecs:
mplayer-codecs:
mplayer-codecs:
mplayer-codecs:
mplayer-codecs:
mplayer-codecs:
mplayer-codecs:
mplayer-codecs:

jimmy_page_89 ha scritto:...
@spina
posso chiamarlo mplayer-codecs il pacchetto?
perchè lo chiedi a me? Per me lo puoi fare...però se poi qualcuno ti picchia non girare la responsabilità su di me, capito

spina ha scritto:jimmy_page_89 ha scritto:...
@spina
posso chiamarlo mplayer-codecs il pacchetto?perchè lo chiedi a me? Per me lo puoi fare...però se poi qualcuno ti picchia non girare la responsabilità su di me, capito
![]()
Emanuele


jimmy_page_89 ha scritto:posso chiamarlo mplayer-codecs il pacchetto?

Ansa89 ha scritto:Io l'ho sempre visto chiamare "all-_VERSIONE_", oppure "essential-_VERSIONE_" (a seconda che si trattasse del pacchetto con tutti i codec, o solo quelli essenziali).



Ansa89 ha scritto:jimmy_page_89 ha scritto:posso chiamarlo mplayer-codecs il pacchetto?
Io l'ho sempre visto chiamare "all-_VERSIONE_", oppure "essential-_VERSIONE_" (a seconda che si trattasse del pacchetto con tutti i codec, o solo quelli essenziali).
IMHO faresti bene a continuare con questa nomenclatura, poi il packager sei tu e queste scelte dipendono da te.

tasodan ha scritto:A mio parere il pacchetto dovrebbe essere chiamato semplicemente "codecs" e basta, e il nome dice tutto.

tasodan ha scritto:Si ma non è molto indicativo il nome all oppure essential, non ti fa capire cosa stai installando. Nel repository dei sorgenti di mplayer hanno messo questi nomi perchè tanto si trova nella sottocartella /codecs, quindi è abbastanza intuitivo.
A mio parere il pacchetto dovrebbe essere chiamato semplicemente "codecs" e basta, e il nome dice tutto.

Visitano il forum: Nessuno e 2 ospiti