Recent

Author Topic: I finally managed to install lazarus 0.9.30 and fpc 2.4.2 on Ubuntu  (Read 12160 times)

macmike

  • Jr. Member
  • **
  • Posts: 85
    • Soft-Practice
I've had a lot of difficulty installing Lazarus 0.9.30 on Ubunut but I persevered because Lazarus is awesome, so having finally managed it I though I'd share in case anyone else has the same problems!

Things I tried:
I tried updating apt sources with “deb http://www.hu.freepascal.org/lazarus/ lazarus-stable universe” but got an error:

    Failed to fetch http://www.hu.freepascal.org/lazarus/dists/lazarus-stable/Release  Unable to find expected entry ‘universe/source/Sources’ in Release file (Wrong sources.list entry or malformed file)

I tried checking out the daily source from SVN but couldn’t work out how to make it all build properly. I tried the daily downloads of deb packages but got an error on starting that said “LCLBase 1.0″ – “Unit not found: RegisterLCL” error.

I tried downloading various archives full of stuff and either making, installing debs or whatever with a variety of problems. Often there were broken package dependencies around e(.g. “package lcl-units-0.9.30 is not installed”).

What worked:
Finally I found a way that worked over the weekend so I thought I’d share it for others having these difficulties. First if you’ve got a corrupt/broken installation or an old version installed it’s a good idea to get rid of it. I did this by doing:

1. Delete any existing FPC and Lazarus stuff, conflicts between versions are the source of many of the problems!

    sudo apt-get purge fpc lazarus
    sudo rm -Rf /usr/lib/fpc
    sudo rm -Rf /usr/lib/lazarus
    sudo rm -Rf /usr/share/fpcsrc
    sudo rm -f ~/.fpc
    sudo rm -Rf ~/.lazarus

2.  Download and extract the fpc packages and the lazarus packages. This ends up with two folders full or .deb files. Going into the fpc one first, then the lazarus one and entering:

    sudo dpkg -i *

Installs FPC and then Lazarus.

3. Finally run Lazarus from your main menu, weird unity thingy or whatever you use :D

eny

  • Hero Member
  • *****
  • Posts: 1653
Hm, doesn't work.
It's worse then then the windows dll hell   :'( :'(

Installing FPC went fine.

Now Trying to install lazarus:
lcl-qt4-0.9.30 depends on libqt4pas-dev; however:
  Package libqt4pas-dev is not installed.

WTF!!

Alright, try to install that one:
libqt4pas-dev depends on libqt4pas5 (= 2.1Qt4.5.3-4); however:
  Version of libqt4pas5 on system is 2.1Qt4.5.3-1ubuntu2.


Alright, let's try that one:
libqt4pas5 depends on libqt4-network (>= 4:4.5.3); however:
  Package libqt4-network is not installed.
 libqt4pas5 depends on libqtcore4 (>= 4:4.7.0~beta2); however:
  Package libqtcore4 is not installed.
 libqt4pas5 depends on libqtgui4 (>= 4:4.6.1); however:
  Package libqtgui4 is not installed.
 libqt4pas5 depends on libqtwebkit4; however:
  Package libqtwebkit4 is not installed.

<snif>
« Last Edit: May 26, 2011, 09:51:27 pm by eny »
All posts based on: Win10 (Win64); Lazarus 3_4  (x64) 25-05-2024 (unless specified otherwise...)

macmike

  • Jr. Member
  • **
  • Posts: 85
    • Soft-Practice
This thing really isn't very easy to install :(
I must have tried about 20 times in total!

Leledumbo

  • Hero Member
  • *****
  • Posts: 8835
  • Programming + Glam Metal + Tae Kwon Do = Me
@eny:
I never managed to install Qt version from repo, so I download the Qt interface manually (Qt is already installed here), compile it, put somewhere the compiler and IDE could find, recompile Lazarus, VOILA! I have Qt version of Lazarus.
@macmike:
To some people, yes. 20 times isn't that much, I've had more years back.

99Percent

  • Full Member
  • ***
  • Posts: 160
Re: I finally managed to install lazarus 0.9.30 and fpc 2.4.2 on Ubuntu
« Reply #4 on: June 09, 2011, 05:29:28 am »

2.  Download and extract the fpc packages and the lazarus packages. This ends up with two folders full or .deb files. Going into the fpc one first, then the lazarus one and entering:

From where exactly did you download these packages? I am also having a hell of a time trying to install Lazarus 0.9.30 and FPC 2.4.2 on Ubuntu. The instructions in this page: http://wiki.freepascal.org/Lazarus_release_version_for_Ubuntu DO NOT work for Ubuntu 11.04 it will install Lazarus 0.9.28 and FPC 2.4.0
« Last Edit: June 09, 2011, 05:32:21 am by 99Percent »

99Percent

  • Full Member
  • ***
  • Posts: 160
Re: I finally managed to install lazarus 0.9.30 and fpc 2.4.2 on Ubuntu
« Reply #5 on: June 09, 2011, 03:45:12 pm »
First I ran these commands:

sudo apt-get -f install
sudo apt-get purge fpc lazarus
sudo apt-get autoremove
(this last command seems to be necessary too)
sudo rm -Rf /usr/lib/fpc
sudo rm -Rf /usr/lib/lazarus

Ok, I downloaded Lazarus 0.9.30 and FPC 2.4.2 from here:

http://sourceforge.net/projects/lazarus/files/Lazarus%20Linux%20i386%20DEB/Lazarus%200.9.30/

I extracted all *.deb files to a single directory

then I ran:

sudo dpkg -i *

I still got some dependencies issues for the following:
 fp-units-gtk
 fp-units-multimedia
 fpc
 fp-units-gnome1

But atleast Lazarus starts and compiles without errors so far.

Would it be very hard to make a one click installer (like PostgreSQL has for Linux).

99Percent

  • Full Member
  • ***
  • Posts: 160
Re: I finally managed to install lazarus 0.9.30 and fpc 2.4.2 on Ubuntu
« Reply #6 on: June 09, 2011, 05:26:32 pm »
Scratch that. For some reason I can no longer rebuild Lazarus from the IDE. Can't find Unit blablabla. Its getting very annoying not knowing what the hell is going on :(

jl

  • Full Member
  • ***
  • Posts: 178
Re: I finally managed to install lazarus 0.9.30 and fpc 2.4.2 on Ubuntu
« Reply #7 on: June 09, 2011, 07:16:38 pm »
Scratch that. For some reason I can no longer rebuild Lazarus from the IDE. Can't find Unit blablabla. Its getting very annoying not knowing what the hell is going on :(


You may need to reinstall Ubuntu or just create an Ubuntu vm dedicated to Lazarus.

See here for the steps - http://www.lazarus.freepascal.org/index.php/topic,13419.msg70196.html#msg70196

garlar27

  • Hero Member
  • *****
  • Posts: 652
Re: I finally managed to install lazarus 0.9.30 and fpc 2.4.2 on Ubuntu
« Reply #8 on: June 09, 2011, 07:35:24 pm »
I did the following:

1- Unistalled old Lazarus and FPC.
2- Erased "/home/user/.lazarus/" folder.
3- Installed FPC 2.4.4.
4- Created a Lazarus folder "/home/user/lazarus/0.9.30/"
5- Decompressed the "lazarus-0.9.30-src.tar.bz2" file in "/home/user/lazarus/0.9.30/" folder.
6- From console: Executed "make clean all"  in previous folder.
7- Execute Lazarus and set compiler, and FPC source folder.

At this point you might have some problems with some FPC binaries and fpcres not found. To resolve that you can create a simlink to those binaries in folder "/usr/bin/"

You can look at this thread

 

TinyPortal © 2005-2018