[32730] trunk/dports/net

ecronin at macports.org ecronin at macports.org
Sat Jan 12 12:00:50 PST 2008


Revision: 32730
          http://trac.macosforge.org/projects/macports/changeset/32730
Author:   ecronin at macports.org
Date:     2008-01-12 12:00:48 -0800 (Sat, 12 Jan 2008)

Log Message:
-----------
New port.  Closes #13619

Added Paths:
-----------
    trunk/dports/net/mediaserv/
    trunk/dports/net/mediaserv/Portfile
    trunk/dports/net/mediaserv/files/
    trunk/dports/net/mediaserv/files/patch-install_sh.diff
    trunk/dports/net/mediaserv/files/patch-mediaserv.diff

Added: trunk/dports/net/mediaserv/Portfile
===================================================================
--- trunk/dports/net/mediaserv/Portfile	                        (rev 0)
+++ trunk/dports/net/mediaserv/Portfile	2008-01-12 20:00:48 UTC (rev 32730)
@@ -0,0 +1,59 @@
+# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
+# $Id$
+
+PortSystem 1.0
+
+name            mediaserv
+version         0.05
+categories      net
+maintainers     ecronin
+platforms       darwin
+description     On-demand transcoding server for videos, targetting \
+                the Nokia Internet Tablets.
+long_description \
+                 mediaserv is a simple web server which exposes video \
+                 content on your desktop PC or server to your Nokia \
+                 Internet Tablet (such as the Nokia 770, Nokia N800 or \
+                 Nokia N810).  When content is accessed, it transcodes \
+                 the video "Just In Time" and streams it to your \
+                 Internet Tablet.  RSS feeds for directories are also \
+                 provided, listing the most recently updated content, \
+                 and compatible with Nokia's beta Video Center \
+                 application.
+homepage        http://mediautils.garage.maemo.org/mediaserv.html
+master_sites    https://garage.maemo.org/frs/download.php/2632
+livecheck.check regex
+livecheck.url   https://garage.maemo.org/frs/?group_id=455
+livecheck.regex mediaserv-\(\[0-9\]+\.\[0-9\]+\)\.tar\.gz
+checksums       md5 94c300a0e95c55dae42a61f77e4e41fe \
+                sha1 53aa0d2d287bdf82c232e7e944d9212453dc47b0 \
+                rmd160 78e824cd8b28effc58543e75aaf63e2cdc958941
+worksrcdir      ${name}
+
+depends_run     port:perl5.8 port:p5-libwww-perl port:p5-xml-rss \
+                port:p5-datetime port:mplayer port:tablet-encode
+
+patchfiles      patch-mediaserv.diff patch-install_sh.diff
+post-patch {
+    reinplace "s|/usr/bin/perl|${prefix}/bin/perl|g" \
+        ${worksrcpath}/mediaserv
+    reinplace "s|@@STATIC_DIR@@|${prefix}/share/${name}|g" \
+        ${worksrcpath}/install.sh
+}
+
+configure       {}
+
+build           {}
+
+destroot {
+    xinstall -m 755 ${worksrcpath}/mediaserv \
+        ${destroot}${prefix}/bin/mediaserv
+    xinstall -m 755 ${worksrcpath}/install.sh \
+        ${destroot}${prefix}/bin/mediaserv-install
+    xinstall -m 755 -d ${destroot}${prefix}/share/${name}
+    eval xinstall -m 644 [glob ${worksrcpath}/resources/*] \
+        ${destroot}${prefix}/share/${name}
+    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
+    xinstall -m 644 ${worksrcpath}/README.txt \
+        ${destroot}${prefix}/share/doc/${name}/README.txt
+}


Property changes on: trunk/dports/net/mediaserv/Portfile
___________________________________________________________________
Name: svn:keywords
   + Id
Name: svn:eol-style
   + native

Added: trunk/dports/net/mediaserv/files/patch-install_sh.diff
===================================================================
--- trunk/dports/net/mediaserv/files/patch-install_sh.diff	                        (rev 0)
+++ trunk/dports/net/mediaserv/files/patch-install_sh.diff	2008-01-12 20:00:48 UTC (rev 32730)
@@ -0,0 +1,27 @@
+--- install.sh.orig	2007-12-17 22:22:50.000000000 -0500
++++ install.sh	2007-12-17 22:42:11.000000000 -0500
+@@ -2,13 +2,12 @@
+ #
+ # Create ~/.mediaserv and copy the static files we care about into it.
+ 
+-STATIC_DIR=`dirname "$0"`
+-STATIC_DIR=`cd "$STATIC_DIR"; pwd`
++STATIC_DIR="@@STATIC_DIR@@"
+ 
+ [ -d ~/.mediaserv ] || mkdir ~/.mediaserv || exit
+ [ -f ~/.mediaserv/config ] && touch ~/.mediaserv/config
+ 
+-cp -vup "${STATIC_DIR}/resources/"* ~/.mediaserv/
++cp -vrp "${STATIC_DIR}/"* ~/.mediaserv/
+ 
+ cp ~/.mediaserv/config ~/.mediaserv/config~
+ perl -e '
+@@ -20,7 +19,7 @@
+     print;
+     print "$1 = $settings{$1}\n" if /(\w+)\s*=\s*/ and $settings{$1};
+   }
+-' "${STATIC_DIR}/resources/config" >~/.mediaserv/config
++' "${STATIC_DIR}/config" >~/.mediaserv/config
+ 
+ echo "Install of mediaserv complete."
+ 

Added: trunk/dports/net/mediaserv/files/patch-mediaserv.diff
===================================================================
--- trunk/dports/net/mediaserv/files/patch-mediaserv.diff	                        (rev 0)
+++ trunk/dports/net/mediaserv/files/patch-mediaserv.diff	2008-01-12 20:00:48 UTC (rev 32730)
@@ -0,0 +1,13 @@
+--- mediaserv.orig	2007-12-17 22:32:31.000000000 -0500
++++ mediaserv	2007-12-17 22:36:47.000000000 -0500
+@@ -82,8 +82,8 @@
+ #
+ unless ($ip) {
+     local $ENV{PATH} = '/usr/local/sbin:/usr/sbin:/sbin:'.$ENV{PATH};
+-    $ip = `ifconfig \$(netstat -arn | awk '\$1 ~ /0\.0\.0\.0/ {print \$8; exit}')`;
+-    $ip =~ s/^.*?:(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}) .*$/$1/s if $ip;
++    $ip = `ifconfig \$(netstat -arn | awk '\$1 ~ /default/ {print \$6; exit}')`;
++    $ip =~ s/^.*inet (\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}) .*$/$1/s if $ip;
+ }
+ 
+ # -- See if we can use Gnome to get thumbnails for videos...

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20080112/3816a0e8/attachment.html


More information about the macports-changes mailing list