PDA

View Full Version : AlienBBC and Mac latest installation instructions



Daniel Cohen
2005-01-12, 02:43
With the additional work done by Michael and Adrian, and based on the
instructions in Jules' Web page, I can now give working instruction
for AlienBBC 0.12 on the Mac. Neil's recent input solved my final
difficulty.

The new beta, if one feels like installing it or if one waits till it
is out of beta, will provide much simpler installation. However,
these notes will still provide some helpful hints until Jules or I
can give detailed information.

Jules, feel free to put this on your site if you wish.


WARNING. Some of the downloads can take quite a long time, even on
broadband, and the installation, though it's automated, may take a
very long time.

Step 1. Install the Developer Tools (on your installation CDs) and
X11 (also on the CDs with Panther. Looking at
http://www.apple.com/macosx/features/x11/download/, I don't think a
Jaguar version is available).

Step 2. Go to http://fink.sourceforge.net/ and follow the
instructions for downloading Fink. Fink provides a version for OS X
of many useful Unix programs.

The download and installation is mostly automated, but you will, I
think, have to answer various Yes/No questions during the process, so
you can't be away from your computer too much.

Fink comes with FinkCommander, a GUI for installation of software.

Step 3. Use FinkCommander to download and install the following:

lame
madplay
HTML::Parser

In FinkCommander's preferences, under Commander you will probably
want to check "always choose default response to prompts", so that
installation can proceed without you being there.

The main FinkCommander window is divided into two parts. In the upper
part is a list of packages with descriptions. You may find others
that interest you, for instance anacron will take care of system
maintenance even if the computer is asleep at the scheduled time. To
install a package, click to select it, go to Binary in the menus and
use Install if available. If it is greyed out, go to Source in the
menus and select Install.

After that it all goes forward, with detailed information in the
lower half of the window. One of the reasons things can take a long
time is that each package may require some subsidiary packages
downloaded and installed also. Also, during the compilation phase
there may be no obvious activity going on.

Step 4. Download and decompress AlienBBC. You will get a folder
containing the file alienstream (which is no longer needed), a file
transcoder_proxy.pl, and a folder Plugins.

Step 5. Download and decompress

http://prdownloads.sf.net/mplayerosx/ffmpegXbinaries1115.zip

and put the mplayer anywhere convenient (for instance, put it in
/usr/local/bin)

Step 6. One needs an audio codec called cook.bundle. At one time this
was obtainable from helixcommunity.org, but the version there no
longer works with the version of mplayer. I suspect, but do not know,
that this relates to the change from RealPlayer 9 to RealPlayer 10. A
workable form of the codec, slightly more awkward to install, can be
obtained as detailed below.

Go to http://www1.mplayerhq.hu/homepage/design7/codecs.html and
download the codec package RealPlayer 9 Mac OS X. This decompresses
to an installer package, which installs files, including cook.bundle,
into /usr/local/lib/codecs.

Create a folder /Library/Application Support/ffmpegX/reallib
cook.bundle in this folder. This can be done in the terminal (/usr is
invisible in normal use) but it is also possible to use the Go menu
in the Finder to go to /usr/

You may want to debug the installation of mplayer and the codec at
this stage. If so, run mplayer in the terminal with the parameter
rtsp://rmlivev8.bbc.net.uk/farm/*/ev7/live24/radio2/live/r2_dsat_g2.ra

The terminal should give a load of messages, many of which are
complaints that certain files can't be found. These can be ignored as
long as the line

opening shared object '/Library/Application Support/ffmpegX/reallib
....' is followed by a successful message and shortly thereafter by
the radio stream getting played.

For the rest of the procedure, there are slight differences
depending on whether you have installed SlimServer for all users or
just for one user.

If you have installed it for all users, it will be in
/Library/PreferencePanes but if installed for only one it is in
~/Library/PreferencePanes.

Whichever Library it is in will also have a folder SlimDevices. If
this folder does not already have a subfolder labelled Plugins, move
(or copy, if you prefer) the Plugins folder of AlienBBC into the
SlimDevices folder. If a Plugins folder already exists move or copy
the contents of the AlienBBC Plugins folder (which will be a folder
named Alien) into the Plugins folder in SlimDevices.

Edit transcoder_proxy.pl according to the instructions in the next
step. Then Control-click on the SlimServer preference pane to get a
contextual menu, and choose "Show package contents". Open the
subfolder 'server' of Contents. Copy (option-drag), not move,
transcoder_proxy.pl into this folder.

Note. The reason for editing the file in its place and then copying
it rather than moving is that I think, though I am not sure, that an
upgrade of SlimServer will delete it from the contents of the new
version. If you have kept it, you can then copy it in again. By
contrast, the contents of SlimDevices doesn't get destroyed in an
update.

Step 7. You now need to edit a couple of files using your favourite
text editor. There is an issue with line endings, as Unix ends its
lines with a Line Feed and Mac OS ends lines with a Carriage Return.
Your text editor needs to give you the choice. For editing, it is
simplest to first convert all line feeds to carriage returns (this is
the default preference in Tex-Edit-Plus, which I use. Other text
editors will have their own ways of doing this, perhaps from a Tools
menu item). This provides a more readable file than the original.
Edit the file, and VERY IMPORTANT convert the carriage returns back
into line feeds and save the file.

Edit transcoder_proxy.pl so that the first line reads
#!/usr/bin/perl -w
-I/Library/PreferencePanes/SlimServer.prefPane/Contents/server/CPAN

if you have installed SlimServer for all users,

and so that it reads
#!/usr/bin/perl -w
-I/Users/yourusername/Library/PreferencePanes/SlimServer.prefPane/Contents/server/CPAN

if you have installed it for one user only. Here, of course,
'yourusername' needs to be replaced by the actual user name.

Note. My contextual menu items includes "Copy path to clipboard", but
I'm not sure if this seems to have been installed by File Buddy. If
you have this item, instead of typing in the path, you may simply
want to go to CPAN (as previously, control-click on the preference
pane and "Show package contents" to get to it), copy its path to the
clipboard and paste it into the text.

In the Config block of transcoder_proxy.pl, in the line beginning my
@encoder_search_paths add the location of lame. (Lame is likely to be
in /usr/local/bin/lame or else /sw/bin/lame.) Don't forget " at
beginning and end, and a comma separating two places if you want to
allow it to look at both places. If you can't see the file (and /usr
is invisible normally), just do Command-F, remembering to look for
visible and invisible files, to find out where it is.

Similarly, edit the line beginning my $mplayer = so that it points to
the location of your copy of mplayer.

The other bit of editing needed is to edit Plugin.pm (which is inside
SlimDevices/Plugins/Alien) so that the line beginning my $proxy_path
points to the actual path to transcoder_proxy.pl. It should be either

my $proxy_path =
"/Library/PreferencePanes/SlimServer.prefPane/Contents/server/transcoder_proxy.pl

or

my $proxy_path =
"/Users/yourusername/Library/PreferencePanes/SlimServer.prefPane/Contents/server/transcoder_proxy.pl

where, as before, 'yourusername' should be replaced by your actual
user name. Don't forget the semi-colon at the end of the line.

Notes. When AlienBBC is updated, you will need to edit the new
transcoder_proxy.pl, and put the new copy of Alien in the Plugins
folder and edit the new plugin.pm.
When SlimServer is updated, you will need to recopy
transcoder_proxy.pl from its original place into its place in the
preference pane.


Step 8. One person found that the previous steps were all that was
needed. Others, including me, found that AlienBBC would now work if
Silserver was run from the command line, but not in normal use. Neil
Sleightholm solved this issue. Some necessary Perl modules are on the
hard drive, but aren't in the right place for SlimServer to recognise
them. This may be dealt with in a later version of SlimServer or
AlienBBC, so now is the time to check if the installation has worked.

You can check on the Squeezebox to see if AlienBBC is there - its
default place is in the Internet Radio items. If it's not, you need
to check things using the Web interface - you can do this anyway
instead of using the Squeezebox to check. I used the default skin, I
don't know if everything is present with other skins.

Go to Server settings, Plugins on the Web interface and see if
AlienBBC is listed (if there is a plugin just named 'Alien" rather
than AlienBBC' with a version number, then you need to go to the next
step). If AlienBBC is listed, make sure its checkbox is ticked, and
try stopping SlimServer and restarting it. For some installations
(it's the default) this is needed to load a plugin. All should work
ok now.

Step 9. If a plugin named 'Alien' showed in the Web interface in Step
8, there's more work to do. (If neither 'AlienBBC' nor 'Alien'
appeared, something must have gone wrong).

Locate two folders named HTML in the Perl installation on your hard
drive. On my system these showed up inside
/sw/lib/perl5/5.8.1/darwin-thread-multi-2level
directly inside this folder, the second in a folder named 'auto'
inside this folder. Your installation may have them elsewhere, and
you may have to search for them.

Find your SlimServer preference pane, control-click and choose show
package contents. The contents have a subfolder 'server' which in
turn has a subfolder 'CPAN'. Copy (not move) the contents of the
first HTML folder into the HTML folder inside CPAN. Create a folder
'auto' inside 'CPAN' and copy the other HTML folder (the one inside a
folder 'auto' of your Perl installation) into this 'auto' folder.

That should be all that's needed. Do Step 8 again to test the installation.
--
Daniel Cohen