Compiling Mediatomb on Debian with Support for Samsung Smart TV

Patch and general info: http://sourceforge.net/p/mediatomb/patches/37/

Login as root and copy and paste the below:

apt-get install dpkg-dev devscripts fakeroot
 apt-get build-dep mediatomb
 apt-get source -d mediatomb
 dpkg-source -x mediatomb_0.12.1-0ubuntu4.dsc
 echo mediatomb-urifix.patch >> mediatomb-0.12.1/debian/patches/series
cat > mediatomb-0.12.1/debian/patches/mediatomb-urifix.patch << EOF --- a/tombupnp/upnp/src/genlib/net/uri/uri.c +++ b/tombupnp/upnp/src/genlib/net/uri/uri.c @@ -1042,7 +1042,8 @@ out->path_type = REL_PATH;
 }
- if( ( ( begin_hostport + 1 ) < max ) && ( in[begin_hostport] == '/' ) + //parse hostport only if scheme was found + if( ( begin_hostport > 0 ) && ( ( begin_hostport + 1 ) < max ) && ( in[begin_hostport] == '/' ) && ( in[begin_hostport + 1] == '/' ) ) { begin_hostport += 2; @@ -1059,6 +1060,12 @@ out->hostport.text.size = 0;
 out->hostport.text.buff = 0;
 begin_path = begin_hostport;
 +
 + //remove excessive leading slashes (fix for Samsung Smart TV 2012)
 + while( ( ( begin_path + 1 ) < max ) && ( in[begin_path] == '/' ) && ( in[begin_path + 1] == '/') ) {
 + begin_path++;
 + }
 +
 }
begin_fragment =
 EOF
cd mediatomb-0.12.1/
 dch -i 'Samsung Smart TV 2012 fix by swiergot'
 dpkg-buildpackage -rfakeroot
 cd ..
 dpkg -i mediatomb-common_0.12.1-4.1_armel.deb mediatomb-daemon_0.12.1-4.1_all.deb mediatomb_0.12.1-4.1_all.deb

mediatomb_console

Leave a Reply

Your email address will not be published. Required fields are marked *

20 + 16 =

This site uses Akismet to reduce spam. Learn how your comment data is processed.