Muggle-plugin

From VDR Wiki

(Difference between revisions)
Jump to: navigation, search
(Links: i18n)
 
(One intermediate revision not shown)
Line 14: Line 14:
==Installation==
==Installation==
To install libmad
To install libmad
-
<pre>
+
cd $SOURCEDIR
-
cd $SOURCEDIR
+
tar xvzf libmad-<VERSION>.tar.gz
-
tar xvzf libmad-<VERSION>.tar.gz
+
cd libmad-<VERSION>
-
cd libmad-<VERSION>
+
./configure --prefix=/usr/local
-
./configure --prefix=/usr/local
+
make
-
make
+
make install
-
make install
+
ldconfig
-
ldconfig
+
-
</pre>
+
libogg
libogg
-
<pre>
+
cd $SOURCEDIR
-
cd $SOURCEDIR
+
tar xvzf libogg-<VERSION>.tar.gz
-
tar xvzf libogg-<VERSION>.tar.gz
+
cd libogg-<VERSION>
-
cd libogg-<VERSION>
+
./configure --prefix=/usr/local
-
./configure --prefix=/usr/local
+
make
-
make
+
make install
-
make install
+
ldconfig
-
ldconfig
+
-
</pre>
+
libvorbis
libvorbis
-
<pre>
+
cd $SOURCEDIR
-
cd $SOURCEDIR
+
tar xvzf libvorbis-<VERSION>.tar.gz
-
tar xvzf libvorbis-<VERSION>.tar.gz
+
cd libvorbis-<VERSION>
-
cd libvorbis-<VERSION>
+
./configure --prefix=/usr/local \
-
./configure --prefix=/usr/local \
+
            --with-ogg-libraries=/usr/local/lib
-
            --with-ogg-libraries=/usr/local/lib
+
make
-
make
+
make install
-
make install
+
-
</pre>
+
taglib
taglib
-
<pre>
+
cd $SOURCEDIR
-
cd $SOURCEDIR
+
tar xvzf taglib-<VERSION>.tar.gz
-
tar xvzf taglib-<VERSION>.tar.gz
+
cd taglib-<VERSION>
-
cd taglib-<VERSION>
+
./configure --prefix=/usr/local
-
./configure --prefix=/usr/local
+
make
-
make
+
make install
-
make install
+
ldconfig
-
ldconfig
+
-
</pre>
+
and mySQL
and mySQL
-
<pre>
+
cd $SOURCEDIR
-
cd $SOURCEDIR
+
tar xvzf mysql-<VERSION>.tar.gz
-
tar xvzf mysql-<VERSION>.tar.gz
+
./configure --prefix=/usr/local
-
./configure --prefix=/usr/local
+
            --libexecdir=/usr/local/bin \
-
            --libexecdir=/usr/local/bin \
+
            --without-extra-tools \
-
            --without-extra-tools \
+
            --without-bench
-
            --without-bench
+
make
-
make
+
make install
-
make install
+
find . -name my-medium.cnf -exec cp --backup=t \{} /etc/my.cnf \;
-
find . -name my-medium.cnf -exec cp --backup=t \{} /etc/my.cnf \;
+
cd /usr/local/lib
-
cd /usr/local/lib
+
ln -s mysql/* .
-
ln -s mysql/* .
+
groupadd mysql
-
groupadd mysql
+
useradd -g mysql mysql
-
useradd -g mysql mysql
+
chown -R mysql var
-
chown -R mysql var
+
mysql_install_db --user=mysql &
-
mysql_install_db --user=mysql &
+
ldconfig
-
ldconfig
+
-
</pre>
+
See [[plugin installation]].
See [[plugin installation]].
Line 81: Line 71:
==Configuration==
==Configuration==
Start mySQL with
Start mySQL with
-
<pre>
+
mysqld_safe --user=mysql &
-
mysqld_safe --user=mysql &
+
-
</pre>
+
Now the database can be filled with information (we assume your MP3 archive is under '''/mp3''')
Now the database can be filled with information (we assume your MP3 archive is under '''/mp3''')
-
<pre>
+
cd $SOURCEDIR/VDR/PLUGINS/src/muggle
-
cd $SOURCEDIR/VDR/PLUGINS/src/muggle
+
make mugglei
-
make mugglei
+
cp mugglei /usr/local/bin
-
cp mugglei /usr/local/bin
+
cd scripts
-
cd scripts
+
sh make-empty-db
-
sh make-empty-db
+
cd /mp3
-
cd /mp3
+
find * -path 'Assorted' -prune -o -type f -exec mugglei -z -h localhost -n GiantDisc -f \{} \;
-
find * -path 'Assorted' -prune -o -type f -exec mugglei -z -h localhost -n GiantDisc -f \{} \;
+
-
</pre>
+
To update later via the command menu of VDR add the following to '''/etc/vdr/commands.conf'''
To update later via the command menu of VDR add the following to '''/etc/vdr/commands.conf'''
-
<pre>
+
Update DB : echo "cd /mp3 ; \
-
Update DB : echo "cd /mp3 ; \
+
            find * -path 'Assorted' -prune -o -type f \  
-
find * -path 'Assorted' -prune -o -type f \  
+
            -exec /usr/local/bin/mugglei -z -h localhost \
-
-exec /usr/local/bin/mugglei -z -h localhost \
+
            -n GiantDisc -f '{}' ';'"|at now
-
-n GiantDisc -f '{}' ';'"|at now
+
-
</pre>
+
===Parameter===
===Parameter===
Line 184: Line 168:
[[Category:Plugins]]
[[Category:Plugins]]
-
<!-- Link to german wiki page -->
+
{{i18n|muggle-plugin}}
-
[[de:Hello-plugin]]
+

Latest revision as of 16:46, 13 March 2006

Contents

Description

Setup

The muggle plugin is similar to the mplayer-plugin as it plays MP3 and OGG audio files. But it provides a database backend. One can search and sort his sound archiv in different ways.

Hardware requirements

Software requirements

  • mySQL
  • libmad
  • taglib
  • libvorbis
  • libvorbisfile (optional)

Installation

To install libmad

cd $SOURCEDIR
tar xvzf libmad-<VERSION>.tar.gz
cd libmad-<VERSION>
./configure --prefix=/usr/local
make
make install
ldconfig

libogg

cd $SOURCEDIR
tar xvzf libogg-<VERSION>.tar.gz
cd libogg-<VERSION>
./configure --prefix=/usr/local
make
make install
ldconfig

libvorbis

cd $SOURCEDIR
tar xvzf libvorbis-<VERSION>.tar.gz
cd libvorbis-<VERSION>
./configure --prefix=/usr/local \
            --with-ogg-libraries=/usr/local/lib
make
make install

taglib

cd $SOURCEDIR
tar xvzf taglib-<VERSION>.tar.gz
cd taglib-<VERSION>
./configure --prefix=/usr/local
make
make install
ldconfig

and mySQL

cd $SOURCEDIR
tar xvzf mysql-<VERSION>.tar.gz
./configure --prefix=/usr/local
            --libexecdir=/usr/local/bin \
            --without-extra-tools \
            --without-bench
make
make install
find . -name my-medium.cnf -exec cp --backup=t \{} /etc/my.cnf \;
cd /usr/local/lib
ln -s mysql/* .
groupadd mysql
useradd -g mysql mysql
chown -R mysql var
mysql_install_db --user=mysql &
ldconfig

See plugin installation.

Configuration

Start mySQL with

mysqld_safe --user=mysql &

Now the database can be filled with information (we assume your MP3 archive is under /mp3)

cd $SOURCEDIR/VDR/PLUGINS/src/muggle
make mugglei
cp mugglei /usr/local/bin
cd scripts
sh make-empty-db
cd /mp3
find * -path 'Assorted' -prune -o -type f -exec mugglei -z -h localhost -n GiantDisc -f \{} \;

To update later via the command menu of VDR add the following to /etc/vdr/commands.conf

Update DB : echo "cd /mp3 ; \
            find * -path 'Assorted' -prune -o -type f \ 
            -exec /usr/local/bin/mugglei -z -h localhost \
            -n GiantDisc -f '{}' ';'"|at now

Parameter

Plugin

Parameter (short) Parameter (long) Description
-h HHHH --host=HHHH specify database host (default is localhost)
-s SSSS --socket=PATH specify database socket (default is TCP connection)
-n NNNN --name=NNNN specify database name (overridden by -g)
-p PPPP --port=PPPP specify port of database server (default is )
-u UUUU --user=UUUU specify database user (default is )
-w WWWW --password=WWWW specify database password (default is empty)
-t TTTT --toplevel=TTTT specify toplevel directory for music (default is /mnt/music)
-g --giantdisc enable full Giantdisc compatibility mode

Mugglei

Parameter Description
-s <socket> specify a socket for mySQL communication (default is TCP)
-n <database> specify database name (default is 'GiantDisc')
-u <username> specify user of mySql database (default is empty)
-p <password> specify password of user (default is empty password)
-f <filename> name of music file to import or update
-a import track as if it was on an assorted album
-z scan all database entries and delete entries for files not found

Problems

  • under SuSE one has to compile mySQL from source as the binary is inadequate. The binaries from http://www.mysql.com are also fine.

Links

[1] http://www.htpc-tech.de/htpc/muggle.htm Plugin homepage
[2] http://www.mysql.org mySQL homepage
[3] http://www.underbit.com/products/mad Libmad homepage
[4] http://www.xiph.org/ogg/vorbis Ogg Vorbis CODEC project homepage
[5] http://developer.kde.org/~wheeler/taglib.html Taglib - Audio Meta-Data library homepage
[6] http://vdrportal.de/board/thread.php?postid=206688 snd2usb for muggle to write to USB sticks
Personal tools
Participate