Since the question is coming up again and again, I decided to make a little tutorial about installing PureBasic 4.01 under Linux.
I did not use a native install, since I also wanted to test a "Ubuntu Feisty Fawn 7.04 german" vmWare image.
I used "wink" (www.debugmode.com) to catch the screenshots.
I took me some time, so I hope this will help.

Like everytime on Linux, there are many ways to solve one problem (like in Perl

So, if you follow the tutorial _AND_ you have an active Internet-Connection you should be easily able to get PB running on Ubuntu!
Have fun!
Oh, yes... you'll need the file! Grab it here:
http://bembulak.bas-x.de/files/pb_ubuntu.pdf
(~ 8 Mib, sorry)