Pagina 1 di 1

KSensors package

Inviato: lun 14 mag 2007, 9:39
da Trotto@81
Mi sono accorto della mancanza di questo package nei repository di slacky e mi sono apprestato a scrivere un semplice slackbuild per pacchettizzarlo. Il pacchetto richiede lm_sensors e un kernel con i driver i2c compilati come moduli.

Codice: Seleziona tutto

#!/bin/bash
# Semplice Slackbuild basato su Salckware 11.0
# http://ksensors.sourceforge.net

CWD=`pwd`
if [ "$TMP" = "" ]; then
	TMP=/tmp
fi

PKG=$TMP/package-ksensors	
NAME=ksensors
VERSION=0.7.3
ARCH=i486
BUILD=1at

if [ ! -d $TMP ]; then
	mkdir -p $TMP
fi

if [ ! -d $PKG ]; then 
	mkdir -p $PKG
fi

cd $TMP
tar xvzf $CWD/$NAME-$VERSION.tar.gz
cd $NAME-$VERSION
./configure --prefix=`kde-config --prefix`

make
make install DESTDIR=$PKG
mkdir -p $PKG/usr/doc/$NAME-$VERSION
cp -a AUTHORS COPYING ChangeLog Doxyfile FAQ INSTALL NEWS README TODO $PKG/usr/doc/$NAME-$VERSION


( 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
)

mkdir $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
chown -R root:root $PKG
chmod 644 $PKG/usr/doc/$NAME-$VERSION/*

cd $PKG
makepkg -l y -c n $NAME-$VERSION-$ARCH-$BUILD.tgz

mv $NAME-$VERSION-$ARCH-$BUILD.tgz $CWD

if [ "$1" = "--cleanup" ]; then 
	rm -rf $TMP/$NAME-$VERSION
	rm -rf $PKG
fi
e lo slack-desc:

Codice: Seleziona tutto

# 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----------------------------------------------------|
ksensors: ksensors 0.7.3
ksensors:
ksensors: KSensors is a nice lm-sensors frontend for the K Desktop Environment.
ksensors:
ksensors:
ksensors:
ksensors:
ksensors:
ksensors:
ksensors:
ksensors: Pacchetto creato da Trotto@81.

Inviato: lun 14 mag 2007, 9:53
da submax82
non รจ per fare polemica ... ma invialo via mail qui packages@slacky.it, come scritto su slacky :roll:

ottimo lavoro ;)

Inviato: lun 14 mag 2007, 10:08
da Trotto@81
scusatemi non ci avevo fatto caso.