From Amarok Wiki

English | 简体中文


Installation on Gentoo

For Amarok 2 (The KDE 4 SLOT)

# emerge -av amarok:4

If this fails, see the unmasking section.

For the Amarok 1 (The KDE 3.5 SLOT)

# emerge -av amarok:3.5

Running Amarok 1 with Amarok 2 Installed

Note that it is possible to have both installed at the same time. To run Amarok 1 when you also have Amarok 2 also installed:

# /usr/kde/3.5/bin/amarok

Unmasking Amarok2 and QT4

Note that as of 2009-09-07, KDE-4 is still keyworded in gentoo. Read the Gentoo KDE Guide first to install QT4 [1]. Then, you will probably have to unmask your chosen amarok version.

eix is a tool to view available package versions (as a replacement for emerge -s)

# emerge -av eix
# eix-update
# eix media-sound/amarok

Choose a version (in this example, 2.1.1)

# echo "=media-sound/amarok-2.1.1" >> /etc/portage/package.keywords
# emerge -av amarok:4

Problems + Configuration

Configure xine to play MP3s:

The default engine for Amarok is xine, and as such its supported types are controlled through the useflags for xine-lib.

  • For xine-lib-1.1.2, set the "mp3" useflag.
  • For xine-lib >= 1.1.3, MP3 support will always be present through FFMPEG, although the previously used MAD decoder can be employed instead by enabling the "mad" useflag.

See the Gentoo instructions on MP3 if Amarok says that the xine backend does not support MP3 playback.

Amarok 2 and Mysql Embedded

If you are running Gentoo, more work may be needed to make sure that Amarok is able to properly load your collection. The typical symptom of this problem is Amarok scanning for a while and then no songs showing up in your collection. There are two solutions to this probem

Mysql Embedded as a shared library

1) Set your LDFLAGS to "-Wl,--as-needed" Install the latest ~arch ebuild of mysql or mysql-community, and recompile amarok (with these ldflags)

Mysql Embedded built with -fPIC

Add these two lines to your /etc/portage/env/dev-db/mysql (or mysql-community, if that is what you have installed)

CFLAGS="${CFLAGS} -DPIC -fPIC"
CXXFLAGS="${CXXFLAGS} -DPIC -fPIC"

And recompile both mysql and Amarok.

Debugging

If you would like to be able to debug Amarok and other packages under Gentoo, please ensure that either "nostrip" or (better) "splitdebug" is in your FEATURES, that "debug" is set for Amarok in package.use and that and Amarok has been rebuilt with these settings in place. For further information, refer to the Gentoo backtrace guide listed below.

Further information on debugging