Skip to content

Commit

Permalink
Merged with ShairPort 0.04 update.
Browse files Browse the repository at this point in the history
http:https://mafipulation.org/blagoblig/2011/04/08
    shairport-0.04.tar.gz
    12/4: Updated to 0.04 - compile fixed on non-x86 platforms
  • Loading branch information
okertanov committed Apr 13, 2011
1 parent ed13e78 commit 2a00238
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 19 deletions.
4 changes: 2 additions & 2 deletions INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ You need the following installed:
Perl

Debian/Ubuntu users need:
libssl-dev libcrypt-openssl-rsa-perl libao2 libao-dev libio-socket-inet6-perl
libssl-dev libcrypt-openssl-rsa-perl libao2 libao-dev libio-socket-inet6-perl libwww-perl avahi-utils

Perl modules (e.g. `perl -MCPAN -e 'install X'`):
Perl modules (install from CPAN if needed e.g. `perl -MCPAN -e 'install X'`):
HTTP::Message
Crypt::OpenSSL::RSA
IO::Socket::INET6
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PKGFLAGS:=$(shell pkg-config --cflags --libs openssl ao)
CFLAGS:=-D__i386 -O2
CFLAGS:=-O2
LDFLAGS:=-lm -lpthread
PAUFLAGS:=-lportaudio

Expand Down
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Shairport v0.03
Shairport v0.04
==============
James Laird <[email protected]>
April 11, 2011
Expand Down Expand Up @@ -38,8 +38,9 @@ Changelog
* 0.02 April 11, 2011
* bugfix: libao compatibility
* 0.03 April 11, 2011
* bugfix: ipv6 didn't work -
* IO::Socket::INET6 is required too
* bugfix: ipv6 didn't work - IO::Socket::INET6 is required too
* 0.04 April 12, 2011
* cross-platform count_leading_zeros under GCC - will now compile cleanly on ARM and other platforms


How to compile and install on Mac OSX 10.6
Expand All @@ -55,10 +56,10 @@ prerequisite: install XCode, install homebrew (https://github.com/mxcl/homebrew)
OSX 10.5 only bundles perl 5.8, which won't work with shairport. After getting a update
here (http:https://www.perl.org/get.html), it worked.

Available launch options for
Available launch options for
------
$ shairport.pl --apname=My Name --password=secret


How to run as a daemon on Mac OSX 10.6
------
Expand Down
9 changes: 2 additions & 7 deletions alac.c
Original file line number Diff line number Diff line change
Expand Up @@ -218,18 +218,13 @@ static int count_leading_zeros(int32_t input)
}
return i;
}
#elif defined(__GNUC__) && (defined(_X86) || defined(__i386) || defined(i386))
#elif defined(__GNUC__)
/* for some reason the unrolled version (below) is
* actually faster than this. yay intel!
*/
static int count_leading_zeros(int input)
{
int output = 0;
if (!input) return 32;
__asm("bsr %1, %0\n"
: "=r" (output)
: "r" (input));
return (0x1f - output);
return __builtin_clz(input);
}
#elif defined(_MSC_VER) && defined(_M_IX86)
static int count_leading_zeros(int input)
Expand Down
8 changes: 4 additions & 4 deletions shairport.pl
Original file line number Diff line number Diff line change
Expand Up @@ -114,10 +114,10 @@ sub REAP {
Proto => 'tcp');
};
if ($@) {
print "**************************************\n\n",
"* IO::Socket::INET6 not present! *\n",
"* Install this if iTunes won't play. *\n",
"**************************************\n\n";
print "**************************************\n",
"* IO::Socket::INET6 not present! *\n",
"* Install this if iTunes won't play. *\n",
"**************************************\n\n";

$listen = new IO::Socket::INET(Listen => 1,
LocalPort => 5000,
Expand Down

0 comments on commit 2a00238

Please sign in to comment.