Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[HowTo] Get phonon-xine as backend with at least kde 4.8.5
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
aCOSwt
Bodhisattva
Bodhisattva


Joined: 19 Oct 2007
Posts: 2537
Location: Hilbert space

PostPosted: Wed Jul 18, 2012 12:47 pm    Post subject: [HowTo] Get phonon-xine as backend with at least kde 4.8.5 Reply with quote

I WARNING

Following this how-to, you will be on your own.
Gentoo officially drop phonon-xine from the portage's tree, this means that Gentoo definitely does not support this method.
This solution is necessarily a dead end as there will certainly be a day when phonon-xine becomes definitely incompatible with phonon.
Let's just expect that when this time comes, the other backends will have reached an equivalent level of reliability and functionality.

I suggest you immediately read III.1.4 warning which mentions the most severe constraint impacting this howto before deciding to proceed.

I tested this successfully under amd64 stable arch and kde 4.7.4 and 4.8.3.

[EDIT : 2012.SEP.05 : Works also with 4.8.5]

Ultimate warning : No Gentoo Dev will tell you that it is sensible to follow this howto ! :twisted:

II PURPOSE

This howto is written for those who are not happy with the two existing phonon backends : phonon-vlc and phonon-gstreamer, whatever their reasons
(I personally get half a dozen that can be found using the search facility of this forum :twisted: ) and who would look for a phonon backend that would be :
- Jack-aware
- Capable of reliably selecting the output sound device when more than a single hardware device available
- Capable of High and reliable quality resampling
etc...

III PREPARING THE LOCAL OVERLAY

You will need four entries in your local overlay :

- kde-base/phonon-kde
- media-libs/phonon
- media-libs/phonon-xine
- media-libs/xine-lib

1/ kde-base/phonon-kde

- Create the needed directories (when they do not already exist)
Code:
# cd BaseName_of_your_local_overlay
# mkdir kde-base
# mkdir kde-base/phonon-kde
# cd kde-base/phonon-kde

- Copy the version of the phonon-kde ebuild corresponding to the package already installed on your system. (To date, you get 4.7.4 ; 4.8.3 and 4.8.4)
Code:
# cp BaseName_of_your_GentooPortage_Tree/kde-base/phonon-kde/phonon-kde-4.X.Y.ebuild .

- Open this file under your preferred editor then :

a/ Look for a line showing
Code:
IUSE="alsa debug pulseaudio
and change it for
Code:
IUSE="alsa debug xine pulseaudio"

b/ Look for a line showing
Code:
>=media-libs/phonon-4.4.3
and change it for
Code:
>=media-libs/phonon-4.4.3[xine?]

c/ Look for a line showing
Code:
$(cmake-utils_use_with alsa)
and immediately after this line, insert a new line showing
Code:
$(cmake-utils_use_with xine)

d/ 2 lines above, you get a line of code showing
Code:
-DWITH_Xine=OFF
, delete it.
That's it you can save and exit your editor.
Code:
# repoman manifest

2/ media-libs/phonon

- Create the needed directories (when they do not already exist)
Code:
# cd BaseName_of_your_local_overlay
# mkdir media-libs
# mkdir media-libs/phonon
# cd media-libs/phonon

- Copy the version of the phonon ebuild corresponding to the last stable (To date, 4.5.1-r1)
Code:
# cp BaseName_of_your_GentooPortage_Tree/media-libs/phonon/phonon-4.5.1-r1.ebuild .

- Open this file under your preferred editor then :

a/ Look for a line showing
Code:
IUSE="aqua debug +gstreamer pulseaudio vlc"
and change it for
Code:
IUSE="aqua debug +gstreamer pulseaudio vlc xine"

b/ Look for a line showing
Code:
REQUIRED_USE="|| ( aqua gstreamer vlc )"
and change it for
Code:
REQUIRED_USE="|| ( aqua gstreamer vlc xine )"

c/ Look for a line showing
Code:
vlc? ( >=media-libs/phonon-vlc-0.3.2 )
and immediately after this line, insert a new line showing
Code:
xine? ( >=media-libs/phonon-xine-0.4.4 )

That's it you can save and exit your editor.
Code:
# repoman manifest


3/ media-libs/phonon-xine

- Create the needed directories (when they do not already exist)
Code:
# cd BaseName_of_your_local_overlay/media-libs
# mkdir phonon-xine
# cd phonon-xine

- Download last phonon-xine ebuild from there : http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/media-libs/phonon-xine/phonon-xine-4.4.4.ebuild?revision=1.5 into the present working directory and name it phonon-xine-4.4.4.ebuild

Code:
# repoman manifest

- This should among other things download the necessary tarball.
- If it fails downloading the necessary tarball then refer to http://lfs.traduc.org/view/blfs-24012011/kde4/phonon-backend-xine.html, fetch the tarball from the link mentioned as well as the MD5 info and copy the file downloaded in your portage distfiles directory as phonon-backend-xine-4.4.4.tar.bz2
Then re repoman manifest

4/ media-libs/xine-lib

WARNING : last xine-lib stable under Gentoo-Portage to date is 1.2.1-r1
Because it was arbitrarily declared insufficiently tested, phonon-backend devs decided to prevent the build of phonon-xine with xine-lib-1.2
So phonon-xine is, as is, only buildable with xine-lib < 1.2
Of course it is possible to bypass this block but this would require patching some files in the phonon-xine tarball which goes beyond the purpose of this howto.
So, you should :

a/ Check if you get installed on your system some packages depending on xine-lib
Code:
# equery depends xine-lib

Then if the result is not empty, wonder whether these packages actually need a >= 1.2 xine-lib
Only if you are happy with a xine-lib < 1.2 then proceed to b/.

b/ Create the needed directories (when they do not already exist)
Code:
# cd BaseName_of_your_local_overlay/media-libs
# mkdir xine-lib
# cd xine-lib


c/ Download last xine-lib ebuild from there : http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/media-libs/xine-lib/xine-lib-1.1.20.ebuild?revision=1.7 into the present working directory and name it xine-lib-1.1.20.ebuild
Code:
# repoman manifest

- This should among other things download the necessary tarball.
- If it fails downloading the necessary tarball then refer to http://lfs.traduc.org/view/blfs-24012011/multimedia/xine-lib.html, fetch the tarball from the link mentioned as well as the MD5 info and copy the file downloaded in your portage distfiles directory as xine-lib-1.1.20.tar.xz
Then re repoman manifest

5/ If you did all this work under root, change the owner/group of all the files you created :
Code:

# chown -R portage kde-base
# chown -R portage media-libs
# chgrp -R portage kde-base
# chgrp -R portage media-libs


IV/ REBUILDING

1/ Setting useflags

Of course you want to set the xine useflag for the phonon and the phonon-kde packages... what else would we be doing here ? :lol:
Do this according to your preferred method, mine is to update my /etc/portage/package.use with the following lines :
Code:
kde-base/phonon-kde                 alsa -debug -pulseaudio xine
media-libs/phonon                   -debug, gstreamer, -pulseaudio, vlc, xine

And of course, you won't forget setting the xine-lib use flags according to your needs, mines are :
+X, +a52, +aac, +alsa, +css, +dts, +flac, +jack, +mad, +mmap, +mng, +modplug, +musepack, +opengl, +sdl, +speex, +theora, +truetype, +v4l, +vorbis, +wavpack, +xcb, +xv, +xvmc, -aalib, -libcaca, -nls, -directfb, -ipv6, -fbcon, -samba, -dxr3, -oss, -xinerama, -vcd, -imagemagick, -gtk, -pulseaudio, -vis

And for phonon-xine, mines are : -debug, +xcb

2/ Mask xine-lib >= 1.1.20
Code:
echo ">=media-libs/xine-lib-1.1.20" > /etc/portage/package.mask

3/ rebuilding xine-lib
Code:
# emerge xine-lib

Remember the result of III.4.a : If you had other packages depending on xine-lib then of course, you'll need to
Code:
# revdep-rebuild

4/ rebuilding the rest :
Code:
# emerge phonon-xine
# emerge phonon
# emerge phonon-kde


OK, that's it you should get the possibility to select the xine backend under kde's systemsettings/multimedia/phonon/backend tab.
Do not forget that after setting a new backend, KDE requires you logoff and login again before selecting your device preferences.

This works reliably for me, but I may have done errors when writing this howto.
Please cross-check twice and feel free to correct my post.
_________________


Last edited by aCOSwt on Mon Sep 17, 2012 8:06 pm; edited 7 times in total
Back to top
View user's profile Send private message
xdarma
l33t
l33t


Joined: 08 Dec 2003
Posts: 719
Location: tra veneto e friuli (italy)

PostPosted: Sun Aug 05, 2012 9:06 am    Post subject: Reply with quote

So it's possible to keep the old-good xine backend?
Great, on my computer, xine has always worked right. Not like vlc and gstreamer.

Thank you.
_________________
proud user of faKeDE-4.7.3 -> back to windowmaker -> moved to LXQt
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum