Streaming RealAudio from the command line
howto document written by .
If you're anything like me, you too have grown tired of the annoyances of applications either not working properly, or not working at all. In the Microsoft world, one normally deals with it, as one may not feel comfortable with either finding a different application to do the same job, or learning a new Operating System.
Many years ago, I'd switched to Linux & have been very happy with it. But, like in Microsoft, I've spent too many hours trying to get applications working properly. Much of the time, this is due to applications being written either for a different distribution, or, in some cases, by badly written software. But, in all my trials of different pieces of software to do what I need or want to do, I've found that keeping things simple is the key. Why use an application with a front-end, a Graphical User Interface, if a text-based application will not only install, but will work with less likelihood of crashing?
So, becoming fed up with the GUI, I've begun the process of finding applications which work from the console (or Virtual Terminal) without having to open an XWindow session.
Among the things I do daily, is listen to radio streamed via the Web. One of the stations I've been listening to most every day is a station on the North Shore of O'ahu, Hawaii, which uses RealMedia to stream their broadcast. RealAudo doesn't write their software to work from the command line, nor does their open source project Helix.
Of the few console RealAudo stream applications I've found, I'd opted for the first one, which is only infrequently being worked on. TRPlayer, created by Matt Campbell, is very simple & clean. The others wouldn't install due to the fact I'm running Mandrake 10.0, which places countless files in places many apps aren't aware of. This howto will be updated after I switch back to a more Linux-like distro.
First, in addition to downloading & installing RealAudio itself, one must obtain the RealSystem G2 SDK. As RealMedia changes their site so frequently, the link is to their home page. I found it, finally, by deciphering the links in their site map.
I didn't spend a lot of time looking for any installation documentation, but, in any case, I'd found none. I untarred the file to find numerous files in a nice subdirectory structure, but, again, nothing about what to do with them. Matt was kind enough to tell me that the whole rmasdk_6_0 directory can go either in one's Home directory, or -- for system-wide use -- in /usr/local. I placed mine in /usr/local.
The next thing is something most -- at least those I've dealt with -- distros already have: slang library. If you don't have it, it's found easily via Google.
TRPlayer can be downloaded in, at this time, five different forms: a source distribution, a binary distribution for Linux, an RPM package, a Slackware package, or a Debian package from the TRPlayer home page.
If you download the source unpack it, change into the trplayer-1.2.0 directory and do the usual ./configure, make, and make install. But, of course, because I'm running Mandrake just now, this didn't work for me. It should in most other distros, though.
Because of differences between more current system files in Mandrake 10.0 & the Debian release on Matt's system, Matt had modified the current release of TRPlayer for me. In an e-mail, he explains:There are significant differences between gcc 2.95.x and 3.x, meaning that a program compiled with one probably won't work with a C++ library that was compiled with the other. I have pretty easy access to gcc 2.95.x on my Debian system; it might not be so easy on Mandrake. So I've compiled a new trplayer binary using gcc 2.95.4 and glibc 2.3.3. It works for me, so I'm attaching it to this message (it's small).
A copy can be obtained here: glibc-2.3.3-TRPlayer (40808 bytes, md5sum: 5fa8d6a70f129ec4d8f11db8edf2a466). This is complete & can be run directly from the the command line. I'd saved a copy of it in my home directory & ran chmod+x on it.
To run, simply enter:./trplayer http://url.of/your.stream.rm
You should see something like this:$: trplayer http://url.of/your.stream.rm Contacting Buffering (13%) Buffering (26%) Buffering (39%) Buffering (49%) Buffering (62%) Buffering (73%) Buffering (85%) Buffering (95%)
It's just that simple. After buffering, your stream should start playing just as it would in RealPlayer, only you won't get a gui window.
Meph's general page | Meph's personal home page
Free ThoughtCopyright © 2004-2018
Last update: 24-OCT-2006
This page has been served 12310 times since 04-DEC-2004