Saturday, 14 April 2007

Play mp3 files in Ubuntu

For my second post of ubuntu battles, I'm going to delve back into historic battles (last night) and talk about how to get mp3's to play in Rhythmbox. The first time I did it, it was bizzarre and involved lots of messing about, but now I find the following AMAZING program...
Immense. So easy.

The best thing is, Rhythmbox has AudioScrobbler built-in, so if you are a fanatic, you only have to enter your username and password in Preferences>AudioScrobbler.

Note to self: Actually RUN the EasyUbuntu program after you download it, before you wonder why mp3's are still not recognised. Doh.

Free Pascal

For my first thrilling post, I'd like to tell you all about my entire evening trying to install Free Pascal on my laptop which runs Ubuntu Linux (Dapper Drake, no less). Since I'm not a very experienced user (not at all!) I have been mainly fumbling in the dark. However, since I just managed to compile my first pascal program, I thought I'd share those fumblings with you, incase you're interested. So.

I visited this marvellous website, and downloaded the 2.0.4 release for Linux as a .tar file:
So far, so good. I could have had the .deb packages, but they were numerous, and I didn't know what to do with them, or which ones I needed. So, the .tar version it was. I un-tarred it like so:

tar -xvf fpc-2.0.4.i386-linux.tar

And then I ran the shell script to install it thus:

sudo ./

I wrote an incredible program, and named the file "hello.pp" (my first ever pascal program!)

program hello;
writeln ('Hello, world.');

And then I typed...

fpc hello.pp

But! Woe is me! The computer told me:

hello.pp(4,1) Error: Util ld not found, switching to external linking

Which was very rude. However, after much head scratching and manual searching, I found the following enlightenment from the freepascal user manual:

Under UNIX systems (such as LINUX) you need to have the following programs installed :
1. GNU as, the GNU assembler.
2. GNU ld, the GNU linker.
3. Optionally (but highly recommended) : GNU make. For easy recompiling of the compiler and Run-Time Library, this is needed.

Compiling a compiler? I can't cope with this! A bit more detective work lead me to install binutils using the synaptic package manager, which gave me the gnu assembler and linker. Then my program compiled sweetly and ran when I typed:


Great stuff.

Hello, World.

Hello, deep abyss of cyberspace.

I feel compelled to start my own blog, mainly to chronicle my battles against my computer. It's going to be a fascinating read, I can just tell.

Everytime I work out how to do something with Linux (ie. Installing my printer, taking a whole day) I mean to write it down. However, I never do, and when my computer finally goes mental (I spill a glass of water on it) I have to re-install everything. By this time I've forgotten exactly how I ever got it to play mp3s. But this is getting more regular, as my computer becomes more geriatric. So here's my blog of reminders for myself next time it all goes tits up.

Useful, that is, providing it's not my Ethernet card that gets fried (again).

So, welcome, complete lack of readers, to this most fascinating and fishy blog.