From e35bd86542450a001901e7937fbde34c56219eb9 Mon Sep 17 00:00:00 2001 From: Martin Spasov Date: Sat, 16 Apr 2011 23:04:32 +0300 Subject: [PATCH 1/3] Some documentation addition, fixed caps. Minor documentation additions. Changed caps Shairport -> ShairPort --- INSTALL.md | 2 +- README.md | 9 +++++---- shairport.pl | 2 +- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/INSTALL.md b/INSTALL.md index 0e8d5c2b..3c211a20 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -23,7 +23,7 @@ Perl modules (install from CPAN if needed e.g. `perl -MCPAN -e 'install X'`): ## Mac OS X: * install XCode - * install [Homebrew](https://github.com/mxcl/homebrew) or [Macports](http://www.macports.org/) + * install [Homebrew](https://github.com/mxcl/homebrew) or [MacPorts](http://www.macports.org/) * type: $ export ARCHFLAGS="-arch x86_64" (replace x86_64 by your arch) diff --git a/README.md b/README.md index 08139120..c9edc1c1 100644 --- a/README.md +++ b/README.md @@ -1,19 +1,20 @@ -Shairport v0.05 +ShairPort v0.05 ============== James Laird April 13, 2011 What it is ---------- -This program emulates an Airport Express for the purpose of streaming music from iTunes and compatible iPods. It implements a server for the Apple RAOP protocol. +This program emulates an AirPort Express for the purpose of streaming music from iTunes and compatible iPods. It implements a server for the Apple RAOP protocol. +ShairPort does not support AirPlay v2 (video and photo streaming). -It probably supports multiple simultaneous streams, if your audio output chain (as detected by libao) does so. +It supports multiple simultaneous streams, if your audio output chain (as detected by libao) does so. How to use it ------------- `perl shairport.pl`. See INSTALL.md for further information. -The triangle-in-rectangle Airtunes logo will appear in the iTunes status bar of any machine on the network, or on iPod play controls screen. Choose your access point name to start streaming to the Shairport instance. +The triangle-in-rectangle AirTunes (now AirPlay) logo will appear in the iTunes status bar of any machine on the network, or on iPod play controls screen. Choose your access point name to start streaming to the ShairPort instance. Thanks ------ diff --git a/shairport.pl b/shairport.pl index a7d00297..0fe8fb52 100755 --- a/shairport.pl +++ b/shairport.pl @@ -58,7 +58,7 @@ GetOptions("a|apname=s" => \$apname, "h|help" => \$help); sub usage { - print "Shairport version $shairportversion - Airport Express emulator\n". + print "ShairPort version $shairportversion - Airport Express emulator\n". "Usage:\n". "$0 [OPTION...]\n". "\n". From b4743936b010c6acfa497dc6ce96ef849ef94bfa Mon Sep 17 00:00:00 2001 From: James Laird Date: Sun, 17 Apr 2011 12:01:01 +1000 Subject: [PATCH 2/3] Revert "Fix typo when getting content-length" Feature, not typo... prevents comparison with undefined warning. This reverts commit ad1a0ea33d266a27ce69de998bd84d55da6b6690. --- shairport.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shairport.pl b/shairport.pl index a7d00297..07401fe5 100755 --- a/shairport.pl +++ b/shairport.pl @@ -261,7 +261,7 @@ sub conn_handle_request { my ($fh, $conn) = @_; my $req = $conn->{req};; - my $clen = $req->header('content-length') || 0; + my $clen = $req->header('content-length') // 0; if ($clen > 0 && !length($req->content)) { $conn->{req_need} = $clen; return; # need more! From 2c3206c124278ac90dacff6f9b31aaa6a43149a8 Mon Sep 17 00:00:00 2001 From: James Laird Date: Mon, 18 Apr 2011 00:57:13 +1000 Subject: [PATCH 3/3] Make Perl version requirement clear. --- INSTALL.md | 2 +- shairport.pl | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/INSTALL.md b/INSTALL.md index 3c211a20..6d95af24 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -4,7 +4,7 @@ You need the following installed: * openssl * libao - * Perl + * Perl 5.10 or higher * Linux: avahi * Windows/Mac OS X: Bonjour diff --git a/shairport.pl b/shairport.pl index 5477130e..14a40382 100755 --- a/shairport.pl +++ b/shairport.pl @@ -23,6 +23,8 @@ # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR # OTHER DEALINGS IN THE SOFTWARE. +use 5.10.0; + use Getopt::Long; use FindBin;