PulseAudio su slackware

Postate qui se avete consigli per migliorare i pacchetti disponibili in questo sito o se avete problemi con installazione, funzionamento o altro.

Moderatore: Staff

Regole del forum
1) Citare in modo preciso il nome del pacchetto.
2) Specificare se discussione/suggerimento o richiesta d'aiuto.
3) Leggere attentamente le risposte ricevute
4) Scrivere i messaggi con il colore di default, evitare altri colori.
5) Scrivere in Italiano o in Inglese, se possibile grammaticalmente corretto, evitate stili di scrittura poco chiari, quindi nessuna abbreviazione tipo telegramma o scrittura stile SMS o CHAT.
6) Appena registrati è consigliato presentarsi nel forum dedicato.

La non osservanza delle regole porta a provvedimenti di vari tipo da parte dello staff, in particolare la non osservanza della regola 5 porta alla cancellazione del post e alla segnalazione dell'utente. In caso di recidività l'utente rischia il ban temporaneo.
Avatar utente
ZeroUno
Staff
Staff
Messaggi: 5441
Iscritto il: ven 2 giu 2006, 14:52
Nome Cognome: Matteo Rossini
Slackware: current
Kernel: slack-current
Desktop: ktown-latest
Distribuzione: 01000000-current
Località: Roma / Castelli
Contatta:

Re: PulseAudio su slackware

Messaggio da ZeroUno »

nono.

per intero intendo il pacchetto risultante di quegli slackbuild (che hanno ARCH=i486), non passato a compat32
quindi 3 pacchetti separati
json-c-0.11-i486-1sl.txz
pulseaudio-5.0-i486-1sl.txz
alsa-plugins-1.0.26-i486-1sl.txz
e 3 pacchetti
json-c-0.11-x86_64-1sl.txz
pulseaudio-5.0-x86_64-1sl.txz
alsa-plugins-1.0.26-x86_64-1sl.txz

alle compat32 ci penso io (lo slackbuild di skype lo estrarrà dai pacchetti prefatti i486 e li metterà nelle directory di skype)
Packages finder: slakfinder.org | Slackpkg+, per aggiungere repository a slackpkg

Codice: Seleziona tutto

1011010 1100101 1110010 1101111 - 0100000 - 1010101 1101110 1101111

Avatar utente
ZeroUno
Staff
Staff
Messaggi: 5441
Iscritto il: ven 2 giu 2006, 14:52
Nome Cognome: Matteo Rossini
Slackware: current
Kernel: slack-current
Desktop: ktown-latest
Distribuzione: 01000000-current
Località: Roma / Castelli
Contatta:

Re: PulseAudio su slackware

Messaggio da ZeroUno »

Ok. mi sono fatto l'ambiente chroot 32bit ed ora ho i 3 pacchetti + speex scaricato da slacky installati.

Ora che devo farci?
per dire.. sulla versione SBo c'è rc.pulseaudio; suppongo che startato quello tutto l'audio passi per pulse.

supponendo di avere solo slack a 32bit e skype a 32bit e questi 4 pacchetti installati, ora che dovrei farlo funzionare? (non ho modificato configurazioni per ora)

EDIT:
ok, ho fatto un passo avanti. ho tolto il "supponendo" ed ho fatto il boot dall'ambiente chrootato a 32bit (se vi interessa come si fa chiedete.. è comodo per testare i pacchetti compilati).
Ho avviato skype ed in effetti l'audio funziona senza avviare niente e senza fare modifiche a file di configurazione. Il microfono non va ma potrebbe esserre semplicemente che c'è il "mute" settato :). Invece non so come testare la possibilità del funzionamento contemporaneo di alsa e pulse. Ho avviato skype e contemporaneamente ho anche avviato il testsound di kde; è sufficiente come prova? Che altre prove/configurazioni posso fare?
Packages finder: slakfinder.org | Slackpkg+, per aggiungere repository a slackpkg

Codice: Seleziona tutto

1011010 1100101 1110010 1101111 - 0100000 - 1010101 1101110 1101111

rik70
Iper Master
Iper Master
Messaggi: 2552
Iscritto il: gio 10 mar 2011, 9:21
Slackware: 15.0
Kernel: 5.15.x-generic
Desktop: Sway
Distribuzione: Arch Linux

Re: PulseAudio su slackware

Messaggio da rik70 »

Scusate se reintervengo e insisto.

Ma perché far passare tutto attraverso pulseaudio? Voglio dire: Pat non l'ho messo nei pacchetti, giusto? Ci sarà un motivo? Per un'applicazione sola, per di pù targata M$ e a sorgenti chiusi, piena di bug ad ogni rilascio uno deve passare a quel danno di server audio?

Scusate la vis polemica, ma tale non è.

Altro dettaglio:
pulseaudio di SBo è vero che ha uno script in /etc/rc.d, però non è necessario se si usa kde, xfce o altro ambiente grafico che all'avvio va a "pescare" sotto /etc/xdg/autostart.

Tra l'altro lo SlackBuild ha anche un bug - credo: la directory /var/run/pulse non viene creata durante l'installazione, quindi se si prova ad avviare rc.pulseaudio restituisce un errore. Ma questo non è importante.

rik70
Iper Master
Iper Master
Messaggi: 2552
Iscritto il: gio 10 mar 2011, 9:21
Slackware: 15.0
Kernel: 5.15.x-generic
Desktop: Sway
Distribuzione: Arch Linux

Re: PulseAudio su slackware

Messaggio da rik70 »

P.S.

Il trucco pubblicato su Arch wiki sembra funzionare:

Codice: Seleziona tutto

--- /etc/pulse/default.pa.bak	2014-08-24 21:58:36.877464684 +0200
+++ /etc/pulse/default.pa	2014-08-24 23:15:27.431211776 +0200
@@ -52,12 +52,16 @@
 #load-module module-pipe-sink
 
 ### Automatically load driver modules depending on the hardware available
-.ifexists module-udev-detect.so
-load-module module-udev-detect
-.else
+#.ifexists module-udev-detect.so
+#load-module module-udev-detect
+#.else
 ### Use the static hardware detection module (for systems that lack udev support)
-load-module module-detect
-.endif
+#load-module module-detect
+#.endif
+
+### load alsa-plugs
+load-module module-alsa-sink device=dmix
+load-module module-alsa-source device=dsnoop
 
 ### Automatically connect sink and source if JACK server is present
 .ifexists module-jackdbus-detect.so
Unico problema: come si fa a cambiare l'input? Forse bisogna settare una periferica virtuale dsnoop in asound.conf. Se riesco faccio sapere.

Avatar utente
ScorpionIT
Linux 0.x
Linux 0.x
Messaggi: 62
Iscritto il: mar 25 ago 2009, 13:32
Nome Cognome: Elia Devito
Slackware: 14.1
Kernel: 3.10.17
Desktop: KDE 4.13.3

Re: PulseAudio su slackware

Messaggio da ScorpionIT »

ZeroUno ha scritto:Ok. mi sono fatto l'ambiente chroot 32bit ed ora ho i 3 pacchetti + speex scaricato da slacky installati.

Ora che devo farci?
per dire.. sulla versione SBo c'è rc.pulseaudio; suppongo che startato quello tutto l'audio passi per pulse.

supponendo di avere solo slack a 32bit e skype a 32bit e questi 4 pacchetti installati, ora che dovrei farlo funzionare? (non ho modificato configurazioni per ora)

EDIT:
ok, ho fatto un passo avanti. ho tolto il "supponendo" ed ho fatto il boot dall'ambiente chrootato a 32bit (se vi interessa come si fa chiedete.. è comodo per testare i pacchetti compilati).
Ho avviato skype ed in effetti l'audio funziona senza avviare niente e senza fare modifiche a file di configurazione. Il microfono non va ma potrebbe esserre semplicemente che c'è il "mute" settato :). Invece non so come testare la possibilità del funzionamento contemporaneo di alsa e pulse. Ho avviato skype e contemporaneamente ho anche avviato il testsound di kde; è sufficiente come prova? Che altre prove/configurazioni posso fare?
per il microfono a me è bastato riavviare comunque puoi lanciare alsamixer premere F6 per switchare sui controlli audio della scheda audio e vedere se è mutato il canale del microfono.

EDIT: come test dovrebbe andare bene, per essere sicuro puoi eseguire un file multimediale con mplayer
Ultima modifica di ScorpionIT il lun 25 ago 2014, 0:05, modificato 2 volte in totale.

Avatar utente
ScorpionIT
Linux 0.x
Linux 0.x
Messaggi: 62
Iscritto il: mar 25 ago 2009, 13:32
Nome Cognome: Elia Devito
Slackware: 14.1
Kernel: 3.10.17
Desktop: KDE 4.13.3

Re: PulseAudio su slackware

Messaggio da ScorpionIT »

rik70 ha scritto:P.S.

Il trucco pubblicato su Arch wiki sembra funzionare:

Codice: Seleziona tutto

--- /etc/pulse/default.pa.bak	2014-08-24 21:58:36.877464684 +0200
+++ /etc/pulse/default.pa	2014-08-24 23:15:27.431211776 +0200
@@ -52,12 +52,16 @@
 #load-module module-pipe-sink
 
 ### Automatically load driver modules depending on the hardware available
-.ifexists module-udev-detect.so
-load-module module-udev-detect
-.else
+#.ifexists module-udev-detect.so
+#load-module module-udev-detect
+#.else
 ### Use the static hardware detection module (for systems that lack udev support)
-load-module module-detect
-.endif
+#load-module module-detect
+#.endif
+
+### load alsa-plugs
+load-module module-alsa-sink device=dmix
+load-module module-alsa-source device=dsnoop
 
 ### Automatically connect sink and source if JACK server is present
 .ifexists module-jackdbus-detect.so
Unico problema: come si fa a cambiare l'input? Forse bisogna settare una periferica virtuale dsnoop in asound.conf. Se riesco faccio sapere.
Io ho proposto degli slackbuild che rispechiano la mia attuale configurazione, volendo si può applicare la pach allo slackbuild di pulseaudio oppure si fa 1 pacchetto aggiuntivo da installare eventualmente in sostituzione/alternativa a alsa-plugins, per quanto riguarda il canale di input come sugerito sul wiki di archlinux con pavucontrol si dovrebbe poter settare

rik70
Iper Master
Iper Master
Messaggi: 2552
Iscritto il: gio 10 mar 2011, 9:21
Slackware: 15.0
Kernel: 5.15.x-generic
Desktop: Sway
Distribuzione: Arch Linux

Re: PulseAudio su slackware

Messaggio da rik70 »

@ScorpionIT

Ok, però non sono sicuro che con pavucontrol si possa controllare la periferica virtuale dsnoop. Penso si debba fare sempre a livello di alsa plugin, quindi con un asound.conf di sistema o un .asoundrc.

Oh beninteso, i miei sono solo suggerimenti. Come fare i pacchetti sono questioni dei packagers e dello stuff.

Una altra possibiltà è la seguente:

molte schede audio hanno 2 uscite audio e chi usa skype presumibilmente possiede una webcam con microfono integrato.
Se questo fosse vero si potrebbe fare:

1 - settare pulseaudio sulla seconda uscita hardware della scheda audio principale;
2 - utilizzare il microfono della webcam.

Il principio è lo stesso di quello precedente, ma stavolta si utilizzeranno le uscite e le entrate audio "vere", non quelle "emulate" con dmix e dsnoop.

Per intenderci:

Codice: Seleziona tutto

aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: AudioPCI [Ensoniq AudioPCI], device 0: ES1371/1 [ES1371 DAC2/ADC]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: AudioPCI [Ensoniq AudioPCI], device 1: ES1371/2 [ES1371 DAC1]
  Subdevices: 1/1
Abbiamo 2 uscie audio, che possiamo identificare con hw:0,0 e hw:0,1. A pulseaudio diamo in pasto la seconda e la prima - predefinita - rimane ad alsa. Vediamo dopo come.

Ora gli ingressi:

Codice: Seleziona tutto

arecord -l
**** List of CAPTURE Hardware Devices ****
card 0: AudioPCI [Ensoniq AudioPCI], device 0: ES1371/1 [ES1371 DAC2/ADC]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: U0x46d0x825 [USB Device 0x46d:0x825], device 0: USB Audio [USB Audio]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
Sono 2: il secondo è la webcam, che identificheremo con hw:1,0

Ora diamo tutto in pasto a pulseaudio. Basta editare /etc/pulse/default.pa e sostituire nel diff di prima

Codice: Seleziona tutto

+load-module module-alsa-sink device=dmix
+load-module module-alsa-source device=dsnoop
con:

Codice: Seleziona tutto

+load-module module-alsa-sink device=hw:0,1
+load-module module-alsa-source device=hw:1,0
Funziona perfettamente! L'audio di skype e di vlc ad esempio suonano contemporaneamente. Quindi alsa e pulse non si "vedono".

E se uno non ha la cam col microfono? Poco male, non penso userà il microfono con altre applicazioni mentre parla via skype. Basta che sostituisca hw:1,0 con hw:0,0 ed il gioco è fatto.

Insomma, morale della favola: a mio parere sarebbe meglio lasciare all'utente la scelta, magari con qualche esempio nel README del pacchetto.

P.s.
Nel frattempo vedo se riesco a usare dsnoop con il mic della webcam.

Avatar utente
ZeroUno
Staff
Staff
Messaggi: 5441
Iscritto il: ven 2 giu 2006, 14:52
Nome Cognome: Matteo Rossini
Slackware: current
Kernel: slack-current
Desktop: ktown-latest
Distribuzione: 01000000-current
Località: Roma / Castelli
Contatta:

Re: PulseAudio su slackware

Messaggio da ZeroUno »

Mmm.. Di solito l'utente sceglie la periferica dalla configurazione (gui) di skype.
è possibile mantenere questa possibilità?
Packages finder: slakfinder.org | Slackpkg+, per aggiungere repository a slackpkg

Codice: Seleziona tutto

1011010 1100101 1110010 1101111 - 0100000 - 1010101 1101110 1101111

rik70
Iper Master
Iper Master
Messaggi: 2552
Iscritto il: gio 10 mar 2011, 9:21
Slackware: 15.0
Kernel: 5.15.x-generic
Desktop: Sway
Distribuzione: Arch Linux

Re: PulseAudio su slackware

Messaggio da rik70 »

ZeroUno ha scritto:Mmm.. Di solito l'utente sceglie la periferica dalla configurazione (gui) di skype.
è possibile mantenere questa possibilità?
Il problema è che con l'ultimo skype non hai questa possibilità: hai solo PulseAudioServer (local). O mi sbaglio? E pulse si prende la prima che trova caricando i moduli udev.

Le possibilità per superare i conflitti con alsa sono:

far passare tutto per pulse come ha detto Scorpion;
tamite alsaplugin usare uscite e ingressi virtuali(dmix e dsnoop);
usare la seconda uscita che molte schede audio hanno. E questo forse si può fare anche con pavucontrol - che però io non conosco.

Avatar utente
ScorpionIT
Linux 0.x
Linux 0.x
Messaggi: 62
Iscritto il: mar 25 ago 2009, 13:32
Nome Cognome: Elia Devito
Slackware: 14.1
Kernel: 3.10.17
Desktop: KDE 4.13.3

Re: PulseAudio su slackware

Messaggio da ScorpionIT »

sisi con l'ultima versione di skype c'è solo pulseaudio (local),
Per chi fosse interessato a integrare pulseaudio cone kde posto gli altri tre 3 slackbuild:
gst-plugin-pulseaudio va ad aggiungere il supporto pulseaudio all'installazione ufficiale di gstreamer senza sovrascrivere nulla
kmix e kde-runtime vanno a sovrascrivere i pacchetti ufficiali

EDIT: se qualcuno è interessato a i binari mi faccia sapere

EDIT2:
aggiungo anche lo slackbuild di phonon, che come giustamente segnalato da hashbang è richiesto per far funzionare tutto al 100%.
ho corretto la chiamata a requirebuilder nello slackbuil di kmix

risulato:

con il pacchetto kmix:
Immagine
Immagine

con il pacchetto kde-runtime:
Immagine

gst-plugin-pulseaudio è obbligatorio per far utilizzare pulseaudio a phonon tramite gstreamer

gst-plugin-pulseaudio:

Codice: Seleziona tutto

#!/bin/bash
 
# Heavily based on the Slackware 14.1 SlackBuild
# Written by Elia Devito ( eliadevito [at] yahoo.it )
# Last build from Elia Devito ( eliadevito [at] yahoo.it )
 
# Slackware build script for gst-plugin-pulseaudio
# Official Site: http://gstreamer.freedesktop.org/

# 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.
#
# Require:

set -e

# Basic information.

PKGNAME=gst-plugin-pulseaudio
VERSION=${VERSION:-0.10.31}
BUILD=${BUILD:-1}
TAG=${TAG:-sl}
ARCH=${ARCH:-i486}
SOURCE="http://gstreamer.freedesktop.org/src/gst-plugins-good/gst-plugins-good-${VERSION}.tar.bz2"
TAR=      # empty = auto
DIR=      # empty = auto
DOCS="AUTHORS COPYING* INSTALL README*"
SLKFILES=""

# Automatically determine the architecture we're building on:
case "$ARCH" in
	  i?86) export ARCH=i486; SLKCFLAGS="-O2 -march=i486 -mtune=i686"; CHOST="i486-slackware-linux" ;;
	x86_64) SLKCFLAGS="-O2 -fPIC"; LIBDIRSUFFIX="64"; CHOST="x86_64-slackware-linux" ;;
	  arm*) export ARCH=arm; SLKCFLAGS="-O2 -march=armv5te"; CHOST="arm-slackware-linux-gnueabi" ;;
# Unless $ARCH is already set, use uname -m for all other archs:
		 *) export ARCH=$( uname -m ) ;;
esac

# If EULA
if [ -e EULA.TXT ];then
	more EULA.TXT
	echo "Do you accept terms? (yes/[no])"
	read ACCEPT
	if [ "$ACCEPT" != "yes" ];then
		echo; echo "SlackBuild Aborted!!"
		exit 1
	fi
fi

# Do not touch following if not needed
JOBS=${JOBS:--j2}
CWD=$(pwd)
TMP=${TMP:-/tmp/buildpkgs/$PKGNAME}
PKG=$TMP/package-$PKGNAME
OUTPUT=${OUTPUT:-$CWD}
TAR=${TAR:-$(basename $SOURCE)}
DIR=${DIR:-$(echo "$TAR"|sed -r 's/(\.tar|)(.gz|.bz2|.xz|.tgz|)$//')}

if [ ! -e $CWD/$TAR ];then
	wget $SOURCE -O "$CWD/$TAR"
fi

### Preparing Source
rm -rf $TMP
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
tar xvf $CWD/$TAR
cd $DIR

chown -R root:root .
chmod -R u+w,go+r-w,a-s .

# Customize as you need
CFLAGS="$CFLAGS $SLKCFLAGS" \
CXXFLAGS="$CXXFLAGS $SLKCFLAGS" \
./configure \
	--prefix=/usr \
	--libdir=/usr/lib$LIBDIRSUFFIX \
	--docdir=/usr/doc/$PKGNAME-$VERSION \
	--sysconfdir=/etc \
	--localstatedir=/var \
	--mandir=/usr/man \
	--build=$CHOST \
	--disable-debug \
	--disable-static
cd ext/pulse
make $JOBS
make install DESTDIR=$PKG
cd ../..

# Documentation
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION
 
for DC in $DOCS;do
	[ -e $DC ] && cp -r $DC $PKG/usr/doc/$PKGNAME-$VERSION/ || true
done
 
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild
 
cd $CWD
for SB in $PKGNAME.SlackBuild slack-desc doinst.sh doinst.sh.gz EULA.TXT $SLKFILES;do
	[ -e "$SB" ] && cp -r $SB $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/$SB || true
done

for i in man info
do
    if [ -d $PKG/usr/$i ]; then
   		cd $PKG/usr/$i
		find . -type f -exec gzip -9 {} \;
		for file in $( find . -type l ) ; do ln -s $( readlink $file ).gz $file.gz ; rm $file ; done
		[ "$i" == "info" ] && rm -f dir
    fi
done

cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true

mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
[ -e $CWD/doinst.sh ] && cat $CWD/doinst.sh > $PKG/install/doinst.sh
[ -e $CWD/doinst.sh.gz ] && zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh

cd $PKG
chown -R root:root $PKG

if [ -x "$(which requiredbuilder 2>/dev/null)" ];then
	requiredbuilder -y -v -s $CWD $PKG
	[ -e install/slack-required ] && cat install/slack-required > $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/slack-required
fi

/sbin/makepkg -l y -c n $OUTPUT/$PKGNAME-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-txz}

if [ "$1" = "--cleanup" ]; then
	rm -rf $TMP
fi
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---------------------------------------------|
gst-plugin-pulseaudio: gst-plugin-pulseaudio (pulseaudio GStreamer plugins)
gst-plugin-pulseaudio:
gst-plugin-pulseaudio: GStreamer Pulseaudio Plug-in
gst-plugin-pulseaudio:
gst-plugin-pulseaudio:
gst-plugin-pulseaudio:
gst-plugin-pulseaudio:
gst-plugin-pulseaudio:
gst-plugin-pulseaudio:
gst-plugin-pulseaudio:
gst-plugin-pulseaudio:
kmix.SlackBuild:

Codice: Seleziona tutto

#!/bin/bash
 
# Heavily based on the Slackware 14.1 SlackBuild
# Written by Elia Devito ( eliadevito [at] yahoo.it )
# Last build from Elia Devito ( eliadevito [at] yahoo.it )
 
# Slackware build script for kmix
# Official Site: http://www.kde.org

# 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.
#
# Require:

set -e

# Basic information.

PKGNAME=kmix
VERSION=${VERSION:-4.10.5}
BUILD=${BUILD:-1}
TAG=${TAG:-sl}
ARCH=${ARCH:-i486}
SOURCE="http://download.kde.org/stable/${VERSION}/src/${PKGNAME}-${VERSION}.tar.xz"
TAR=      # empty = auto
DIR=      # empty = auto
DOCS="AUTHORS COPYING* TODO ChangeLog"
SLKFILES=""

# Automatically determine the architecture we're building on:
case "$ARCH" in
	  i?86) export ARCH=i486; SLKCFLAGS="-O2 -march=i486 -mtune=i686"; CHOST="i486-slackware-linux" ;;
	x86_64) SLKCFLAGS="-O2 -fPIC"; LIBDIRSUFFIX="64"; CHOST="x86_64-slackware-linux" ;;
	  arm*) export ARCH=arm; SLKCFLAGS="-O2 -march=armv5te"; CHOST="arm-slackware-linux-gnueabi" ;;
# Unless $ARCH is already set, use uname -m for all other archs:
		 *) export ARCH=$( uname -m ) ;;
esac

# If EULA
if [ -e EULA.TXT ];then
	more EULA.TXT
	echo "Do you accept terms? (yes/[no])"
	read ACCEPT
	if [ "$ACCEPT" != "yes" ];then
		echo; echo "SlackBuild Aborted!!"
		exit 1
	fi
fi

# Do not touch following if not needed
JOBS=${JOBS:--j2}
CWD=$(pwd)
TMP=${TMP:-/tmp/buildpkgs/$PKGNAME}
PKG=$TMP/package-$PKGNAME
OUTPUT=${OUTPUT:-$CWD}
TAR=${TAR:-$(basename $SOURCE)}
DIR=${DIR:-$(echo "$TAR"|sed -r 's/(\.tar|)(.gz|.bz2|.xz|.tgz|)$//')}

if [ ! -e $CWD/$TAR ];then
	wget $SOURCE -O "$CWD/$TAR"
fi

### Preparing Source
rm -rf $TMP
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
tar xvf $CWD/$TAR
cd $DIR

chown -R root:root .
chmod -R u+w,go+r-w,a-s .


mkdir -p build
cd build
cmake .. \
    -DKDE_PLATFORM_FEATURE_DISABLE_DEPRECATED=TRUE \
    -DCMAKE_C_FLAGS:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_C_FLAGS_RELEASE:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS_RELEASE:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DMAN_INSTALL_DIR=/usr/man \
    -DSYSCONF_INSTALL_DIR=/etc/kde \
    -DLIB_SUFFIX=${LIBDIRSUFFIX}
make $JOBS
make install DESTDIR=$PKG

# Move the doc files to the proper place:
mv $PKG/usr/share/doc/ $PKG/usr/doc/

# Documentation
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION
 
for DC in $DOCS;do
	[ -e $DC ] && cp -r $DC $PKG/usr/doc/$PKGNAME-$VERSION/ || true
done
 
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild
 
cd $CWD
for SB in $PKGNAME.SlackBuild slack-desc doinst.sh doinst.sh.gz EULA.TXT $SLKFILES;do
	[ -e "$SB" ] && cp -r $SB $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/$SB || true
done

for i in man info
do
    if [ -d $PKG/usr/$i ]; then
   		cd $PKG/usr/$i
		find . -type f -exec gzip -9 {} \;
		for file in $( find . -type l ) ; do ln -s $( readlink $file ).gz $file.gz ; rm $file ; done
		[ "$i" == "info" ] && rm -f dir
    fi
done

cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true

mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
[ -e $CWD/doinst.sh ] && cat $CWD/doinst.sh > $PKG/install/doinst.sh
[ -e $CWD/doinst.sh.gz ] && zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh

cd $PKG
chown -R root:root $PKG

if [ -x "$(which requiredbuilder 2>/dev/null)" ];then
	requiredbuilder -y -v -c -b -s $CWD $PKG
	[ -e install/slack-required ] && cat install/slack-required > $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/slack-required
fi

/sbin/makepkg -l y -c n $OUTPUT/$PKGNAME-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-txz}

if [ "$1" = "--cleanup" ]; then
	rm -rf $TMP
fi
doinst.sh

Codice: Seleziona tutto

( cd usr/doc/HTML/en/kmix ; rm -rf common )
( cd usr/doc/HTML/en/kmix ; ln -sf /usr/share/doc/HTML/en/common common )
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------------------------------------------------------|
kmix: kmix (sound mixer)
kmix:
kmix: KMix is an application to allow you to change the volume of your
kmix: sound card.  Though small, it is full-featured, and it supports
kmix: several platforms and sound drivers.
kmix:
kmix:
kmix:
kmix:
kmix: For more information, visit:  http://www.kde.org
kmix:
kde-runtime.SlackBuild

Codice: Seleziona tutto

#!/bin/bash
 
# Heavily based on the Slackware 14.1 SlackBuild
# Written by Elia Devito ( eliadevito [at] yahoo.it )
# Last build from Elia Devito ( eliadevito [at] yahoo.it )
 
# Slackware build script for kde-runtime
# Official Site: http://www.kde.org

# 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.
#
# Require:

set -e

# Basic information.

PKGNAME=kde-runtime
VERSION=${VERSION:-4.10.5}
BUILD=${BUILD:-1}
TAG=${TAG:-sl}
ARCH=${ARCH:-i486}
SOURCE="http://download.kde.org/stable/${VERSION}/src/${PKGNAME}-${VERSION}.tar.xz"
TAR=      # empty = auto
DIR=      # empty = auto
DOCS="COPYING* README*"
SLKFILES=""

# Automatically determine the architecture we're building on:
case "$ARCH" in
	  i?86) export ARCH=i486; SLKCFLAGS="-O2 -march=i486 -mtune=i686"; CHOST="i486-slackware-linux" ;;
	x86_64) SLKCFLAGS="-O2 -fPIC"; LIBDIRSUFFIX="64"; CHOST="x86_64-slackware-linux" ;;
	  arm*) export ARCH=arm; SLKCFLAGS="-O2 -march=armv5te"; CHOST="arm-slackware-linux-gnueabi" ;;
# Unless $ARCH is already set, use uname -m for all other archs:
		 *) export ARCH=$( uname -m ) ;;
esac

# If EULA
if [ -e EULA.TXT ];then
	more EULA.TXT
	echo "Do you accept terms? (yes/[no])"
	read ACCEPT
	if [ "$ACCEPT" != "yes" ];then
		echo; echo "SlackBuild Aborted!!"
		exit 1
	fi
fi

# Do not touch following if not needed
JOBS=${JOBS:--j2}
CWD=$(pwd)
TMP=${TMP:-/tmp/buildpkgs/$PKGNAME}
PKG=$TMP/package-$PKGNAME
OUTPUT=${OUTPUT:-$CWD}
TAR=${TAR:-$(basename $SOURCE)}
DIR=${DIR:-$(echo "$TAR"|sed -r 's/(\.tar|)(.gz|.bz2|.xz|.tgz|)$//')}

if [ ! -e $CWD/$TAR ];then
	wget $SOURCE -O "$CWD/$TAR"
fi

### Preparing Source
rm -rf $TMP
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
tar xvf $CWD/$TAR
cd $DIR

chown -R root:root .
chmod -R u+w,go+r-w,a-s .


mkdir -p build
cd build
cmake .. \
    -DKDE_PLATFORM_FEATURE_DISABLE_DEPRECATED=TRUE \
    -DCMAKE_C_FLAGS:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_C_FLAGS_RELEASE:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS_RELEASE:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DMAN_INSTALL_DIR=/usr/man \
    -DSYSCONF_INSTALL_DIR=/etc/kde \
    -DLIB_SUFFIX=${LIBDIRSUFFIX} \
    -DSAMBA_INCLUDE_DIR=/usr/include/samba-4.0
make $JOBS
make install DESTDIR=$PKG

# Create a symlink in /usr/bin to the kdesu binary
( cd $PKG/usr/bin ; ln -s /usr/lib${LIBDIRSUFFIX}/kde4/libexec/kdesu . )

# Remove the hicolor icon theme index.theme so it doesn't clobber the real one
rm -f $PKG/usr/share/icons/hicolor/index.theme

# Move the dbus configuration files to the proper place:
mv $PKG/etc/kde/dbus-1 $PKG/etc/

# Move the doc files to the proper place:
mv $PKG/usr/share/doc/ $PKG/usr/doc/

# Documentation
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION
 
for DC in $DOCS;do
	[ -e $DC ] && cp -r $DC $PKG/usr/doc/$PKGNAME-$VERSION/ || true
done
 
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild
 
cd $CWD
for SB in $PKGNAME.SlackBuild slack-desc doinst.sh doinst.sh.gz EULA.TXT $SLKFILES;do
	[ -e "$SB" ] && cp -r $SB $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/$SB || true
done

for i in man info
do
    if [ -d $PKG/usr/$i ]; then
   		cd $PKG/usr/$i
		find . -type f -exec gzip -9 {} \;
		for file in $( find . -type l ) ; do ln -s $( readlink $file ).gz $file.gz ; rm $file ; done
		[ "$i" == "info" ] && rm -f dir
    fi
done

cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true

mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
[ -e $CWD/doinst.sh ] && cat $CWD/doinst.sh > $PKG/install/doinst.sh
[ -e $CWD/doinst.sh.gz ] && zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh

cd $PKG
chown -R root:root $PKG

if [ -x "$(which requiredbuilder 2>/dev/null)" ];then
	requiredbuilder -y -v -s $CWD $PKG
	[ -e install/slack-required ] && cat install/slack-required > $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/slack-required
fi

/sbin/makepkg -l y -c n $OUTPUT/$PKGNAME-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-txz}

if [ "$1" = "--cleanup" ]; then
	rm -rf $TMP
fi
doinst.sh

Codice: Seleziona tutto

if [ -x /usr/bin/update-desktop-database ]; then
  usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
fi
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------------------------------------------------------|
kde-runtime: kde-runtime (KDE runtime core)
kde-runtime:
kde-runtime: This package contains core components of the KDE base runtime module.
kde-runtime:
kde-runtime:
kde-runtime:
kde-runtime:
kde-runtime:
kde-runtime:
kde-runtime:
kde-runtime:
phonon.SlackBuilder

Codice: Seleziona tutto

#!/bin/bash
 
# Heavily based on the Slackware 14.1 SlackBuild
# Copyright 2008  Robby Workman, Northport, Alabama, USA
# Copyright 2008, 2009, 2010, 2011, 2012  Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.

# Written by  Robby Workman ( eliadevito [at] yahoo.it )
# Modified 2010, 2011, 2012 by Eric Hameleers < alien [at] slackware.com >
# Adapted to slacky's standard by Elia Devito ( eliadevito [at] yahoo.it )
# Last build from Elia Devito ( eliadevito [at] yahoo.it )

# Slackware build script for phonon
# Official Site: http://phonon.kde.org/

# 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.
#

set -e

# Basic information.

PKGNAME=phonon
VERSION=${VERSION:-4.6.0}
BUILD=${BUILD:-1}
TAG=${TAG:-sl}
ARCH=${ARCH:-i486}
SOURCE="http://download.kde.org/stable/${PKGNAME}/${VERSION}/src/${PKGNAME}-${VERSION}.tar.xz"
TAR=      # empty = auto
DIR=      # empty = auto
DOCS="doc/BUGS doc/IDEAS doc/TODO"
SLKFILES=""

# Automatically determine the architecture we're building on:
case "$ARCH" in
	  i?86) export ARCH=i486; SLKCFLAGS="-O2 -march=i486 -mtune=i686"; CHOST="i486-slackware-linux" ;;
	x86_64) SLKCFLAGS="-O2 -fPIC"; LIBDIRSUFFIX="64"; CHOST="x86_64-slackware-linux" ;;
	  arm*) export ARCH=arm; SLKCFLAGS="-O2 -march=armv5te"; CHOST="arm-slackware-linux-gnueabi" ;;
# Unless $ARCH is already set, use uname -m for all other archs:
		 *) export ARCH=$( uname -m ) ;;
esac

# If EULA
if [ -e EULA.TXT ];then
	more EULA.TXT
	echo "Do you accept terms? (yes/[no])"
	read ACCEPT
	if [ "$ACCEPT" != "yes" ];then
		echo; echo "SlackBuild Aborted!!"
		exit 1
	fi
fi

# Do not touch following if not needed
JOBS=${JOBS:--j2}
CWD=$(pwd)
TMP=${TMP:-/tmp/buildpkgs/$PKGNAME}
PKG=$TMP/package-$PKGNAME
OUTPUT=${OUTPUT:-$CWD}
TAR=${TAR:-$(basename $SOURCE)}
DIR=${DIR:-$(echo "$TAR"|sed -r 's/(\.tar|)(.gz|.bz2|.xz|.tgz|)$//')}

if [ ! -e $CWD/$TAR ];then
	wget $SOURCE -O "$CWD/$TAR"
fi

### Preparing Source
rm -rf $TMP
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
tar xvf $CWD/$TAR
cd $DIR

chown -R root:root .
chmod -R u+w,go+r-w,a-s .


mkdir -p build
cd build
cmake .. \
    -DCMAKE_C_FLAGS:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS:STRING="$CFLAGS $SLKCFLAGS" \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DMAN_INSTALL_DIR=/usr/man \
    -DLIB_SUFFIX=${LIBDIRSUFFIX} \
    -DPHONON_INSTALL_QT_EXTENSIONS_INTO_SYSTEM_QT:BOOL=ON \
    -DPHONON_QT_PLUGIN_INSTALL_DIR=/usr/lib$LIBDIRSUFFIX/qt/plugins/designer \
    -DWITH_QZeitgeist=BOOL:OFF
make $JOBS
make install DESTDIR=$PKG

# PyQT won't find the header files otherwise:
sed -i -e 's#{includedir}$#& -I\${includedir}/phonon#' $PKG/usr/lib${LIBDIRSUFFIX}/pkgconfig/phonon.pc

# Documentation
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION
 
for DC in $DOCS;do
	[ -e $DC ] && cp -r $DC $PKG/usr/doc/$PKGNAME-$VERSION/ || true
done
 
mkdir -p $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild
 
cd $CWD
for SB in $PKGNAME.SlackBuild slack-desc doinst.sh doinst.sh.gz EULA.TXT $SLKFILES;do
	[ -e "$SB" ] && cp -r $SB $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/$SB || true
done

for i in man info
do
    if [ -d $PKG/usr/$i ]; then
   		cd $PKG/usr/$i
		find . -type f -exec gzip -9 {} \;
		for file in $( find . -type l ) ; do ln -s $( readlink $file ).gz $file.gz ; rm $file ; done
		[ "$i" == "info" ] && rm -f dir
    fi
done

cd $PKG
find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true
find . | xargs file | grep "current ar archive" | cut -f 1 -d : | xargs -r strip --strip-unneeded 2> /dev/null || true

mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
[ -e $CWD/doinst.sh ] && cat $CWD/doinst.sh > $PKG/install/doinst.sh
[ -e $CWD/doinst.sh.gz ] && zcat $CWD/doinst.sh.gz > $PKG/install/doinst.sh

cd $PKG
chown -R root:root $PKG

if [ -x "$(which requiredbuilder 2>/dev/null)" ];then
	requiredbuilder -y -v -s $CWD $PKG
	[ -e install/slack-required ] && cat install/slack-required > $PKG/usr/doc/$PKGNAME-$VERSION/SlackBuild/slack-required
fi

/sbin/makepkg -l y -c n $OUTPUT/$PKGNAME-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-txz}

if [ "$1" = "--cleanup" ]; then
	rm -rf $TMP
fi
slack-desk:

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------------------------------------------------------|
phonon: phonon (multimedia framework for KDE4)
phonon:
phonon: Phonon is the multimedia API provided by Qt and is the standard
phonon: abstraction for handling multimedia streams within the KDE Software
phonon: Compilation.  Phonon provides an API for multimedia using various
phonon: backends (gstreamer, mplayer, xine) to handle the lower level I/O.
phonon:
phonon: Homepage:  http://phonon.kde.org
phonon:
phonon:
phonon:
Ultima modifica di ScorpionIT il lun 25 ago 2014, 15:47, modificato 2 volte in totale.

rik70
Iper Master
Iper Master
Messaggi: 2552
Iscritto il: gio 10 mar 2011, 9:21
Slackware: 15.0
Kernel: 5.15.x-generic
Desktop: Sway
Distribuzione: Arch Linux

Re: PulseAudio su slackware

Messaggio da rik70 »

rik70 ha scritto: P.s.
Nel frattempo vedo se riesco a usare dsnoop con il mic della webcam.
Ok, è fattibile.

Riepilogando: per usare il trucco di arch wiki e scegliere un input diverso dalla scheda audio di default basta creare un file '~/.asoundrc' o '/etc/asound.conf con questo contenuto':

Codice: Seleziona tutto

pcm.mixin {
	type dsnoop # dsnoop alsa plugin.
	ipc_key 5978293	# must be unique for all dmix plugins!!!!
	ipc_key_add_uid yes
	slave {
		pcm "hw:1,0"  # microfono della webcam.
		channels 1 # il mic della webcam ha un canale solo.
		period_size 1024
		buffer_size 4096
		rate 48000
		periods 0 
		period_time 0
	}
}
A questo punto le opzioni per pulseaudio saranno:

Codice: Seleziona tutto

load-module module-alsa-sink device=dmix
load-module module-alsa-source device=mixin
Tutto funziona perfettamente.

Insomma: alla fine ci sono diverse strade, tutte funzionanti, per evitare conflitti tra pulse e alsa. E questa è una buona notizia.

hashbang
Packager
Packager
Messaggi: 2031
Iscritto il: ven 4 giu 2010, 10:27
Slackware: Slackware ARM
Kernel: current-armv8
Desktop: dwm
Distribuzione: macOS | OpenBSD

Re: PulseAudio su slackware

Messaggio da hashbang »

rik70 ha scritto:Tra l'altro lo SlackBuild ha anche un bug - credo: la directory /var/run/pulse non viene creata durante l'installazione, quindi se si prova ad avviare rc.pulseaudio restituisce un errore. Ma questo non è importante.
Basta aggiungere nel doinst.sh

Codice: Seleziona tutto

if ! grep -q ^pulse: /etc/group ; then
    groupadd -g 216 pulse
fi

if ! grep -q ^pulse: /etc/passwd ; then
    useradd -g pulse -u 216 -d /var/lib/pulse pulse
fi

mkdir -p /var/lib/pulse/.config/pulse
touch /var/lib/pulse/.config/pulse/cookie
touch /var/lib/pulse/.pulse-cookie
chown -R pulse:pulse /var/lib/pulse
ScorpionIT ha scritto:gst-plugin-pulseaudio è obbligatorio per far utilizzare pulseaudio a phonon tramite gstreamer
Sì, ma come ho già detto prima, per far funzionare tutto al 100% e non avere integrazioni a metà, serve anche phonon ricompilato col supporto a PulseAudio, che in Slackware è disattivato per ovvi motivi.
Il backend non basta per un'integrazione corretta, perché è necessario che anche il frontend abbia un'uscita diretta col server.

rik70
Iper Master
Iper Master
Messaggi: 2552
Iscritto il: gio 10 mar 2011, 9:21
Slackware: 15.0
Kernel: 5.15.x-generic
Desktop: Sway
Distribuzione: Arch Linux

Re: PulseAudio su slackware

Messaggio da rik70 »

Una curiosità: qual'èil problema con kmix? Non si possono controllare i volumi in/out di skype... o cosa?

Io nella mia configurazione definitiva - DAC1 della scheda audio principale per l'output e mic della webcam per l'input - posso controllare tutto tramite alsamixer. Non ho bisogno neanche di pavucontrol.

Avatar utente
ScorpionIT
Linux 0.x
Linux 0.x
Messaggi: 62
Iscritto il: mar 25 ago 2009, 13:32
Nome Cognome: Elia Devito
Slackware: 14.1
Kernel: 3.10.17
Desktop: KDE 4.13.3

Re: PulseAudio su slackware

Messaggio da ScorpionIT »

rik70 ha scritto:Una curiosità: qual'èil problema con kmix? Non si possono controllare i volumi in/out di skype... o cosa?

Io nella mia configurazione definitiva - DAC1 della scheda audio principale per l'output e mic della webcam per l'input - posso controllare tutto tramite alsamixer. Non ho bisogno neanche di pavucontrol.
non ci sono problemi con kmix, l'unica differenza è il controllo separato del volume di ogni singola applicazione, resta comunque un di più
hashbang ha scritto:
ScorpionIT ha scritto:gst-plugin-pulseaudio è obbligatorio per far utilizzare pulseaudio a phonon tramite gstreamer
Sì, ma come ho già detto prima, per far funzionare tutto al 100% e non avere integrazioni a metà, serve anche phonon ricompilato col supporto a PulseAudio, che in Slackware è disattivato per ovvi motivi.
Il backend non basta per un'integrazione corretta, perché è necessario che anche il frontend abbia un'uscita diretta col server.
si effettivamente nella mia installazione anche se ero convinto del contrario lo avevo ricompilato, provando a rimettere l'ufficiale funzionava ugualmente ma i dispositi riconosciuti da phonon si mischiavano a quelli di alsa
grazie per la dritta :D

rik70
Iper Master
Iper Master
Messaggi: 2552
Iscritto il: gio 10 mar 2011, 9:21
Slackware: 15.0
Kernel: 5.15.x-generic
Desktop: Sway
Distribuzione: Arch Linux

Re: PulseAudio su slackware

Messaggio da rik70 »

ScorpionIT ha scritto: non ci sono problemi con kmix, l'unica differenza è il controllo separato del volume di ogni singola applicazione, resta comunque un di più
K, thanks. Ma voglio capire: prima di dover installare pulseaudio eri in grado di controllare separatamente - via kmix - il volume di ogni singola applicazione?
Son rimasto parecchio indietro per quanto riguarda KDE.

Rispondi