Sign in Join
Wiki copytemporary

Install on Ubuntu from .deb files: what changed

Revision 1 to 2. Removed lines have a minus sign; added lines have a plus sign.

OldNewLine
11*(Ubuntu only)*
22
33**Please See [[Installing Lazarus on Linux]] - a page that covers most of what you need for most Linux Distributions.**
44
55This page is substantially out of date and may be removed.
66
77## In General
88
99### Why install from .debs?
1010
1111The easiest way to install Lazarus on Ubuntu is via the software Centre or Synaptic. However if that is unsuccessful or the version of Lazarus in the repository is too old and you want a newer version then you can 'install from debs'.
1212
1313### .deb files
1414
1515.deb files are the ideal files for installing on Ubuntu. You need to download the Lazarus .deb files you want. They will usually be on SourceForge. There will be a Lazarus .deb and a Free Pascal .deb. They will *match* each other.
1616
1717## In Particular: Lazarus 0.9.30 on Ubuntu 10.04
1818
1919### Get The files
2020
2121<https://sourceforge.net/projects/lazarus/files/>
2222
2323#### Repository
2424
2525The versions in the Ubuntu repository are
2626
2727- Lazarus 0.9.28
2828- Free Pascal 2.4.0
2929
3030These are too old.
3131
3232#### SourceForge
3333
3434The versions on SourceForge are
3535
3636- Lazarus 0.9.30
3737- Free Pascal 2.4.2
3838
3939These are what I want.
4040
4141#### Find SourceForge .deb files
4242
4343The names of the .deb files I need to download are
4444
4545- lazarus-0.9.30-i386.deb.tar (71.1MB)
4646- fpc-2.4.2-0.i386.deb.tar (38.5 MB)
4747
4848You can search for these directly in a Search engine with something like
4949
50-`Lazarus 0.9.30 .deb SourceForge`
50+```text
51+Lazarus 0.9.30 .deb SourceForge
52+```
5153
5254#### Download and Extract
5355
5456Download these two files. Double click on them and accept the offer to extract.
5557
5658- Extract Free Pascal into folder 'a'
5759- Extract Lazarus in folder 'b'.
5860- Move the folders onto the Desktop
5961
6062#### Inside the folders
6163
6264Once done, there are 21 .deb files in folder a and 12 .deb files in folder b. Two common mistakes when installing Lazarus are
6365
6466- not installing Free Pascal first
6567- not installing Free Pascal source code.
6668
6769However, notice that Free Pascal source code is one of the files in folder a. Therefore, this will NOT need to be downloaded and installed separately.
6870
6971### Install Free Pascal
7072
7173This should be done first.
7274
7375Open a terminal.
7476
7577``` bash
7678cd Desktop
7779cd a
7880dpkg -i *.deb
7981```
8082
8183This last command will install Free Pascal and Free Pascal source code.
8284
8385#### Errors
8486
8587Ideally, everything would run smoothly and the installation would complete without error. However when I did it, there were a number of errors. These errors are sometimes 'show-stoppers' so they should be sorted out if possible. The most common error is a missing dependency, as happened to me.
8688
8789#### Missing Dependencies
8890
8991This means that a package that Lazarus expects to be installed on your system already is not there. The missing packages were:
9092
9193- libgtk2-dev
9294- libogg-dev
9395- libvorbis-dev
9496- libmodplug-dev
9597- a52cat
9698- \+ a few others. If you look through the output in the terminal you will see which packages failed to install and why it was.
9799
98100#### Install missing dependencies
99101
100102Open Synaptic. Search for each of the missing packages and install them.
101103
102104##### a52cat
103105
104106This package is not in the Ubuntu 10.04 repository. We have to leave it and hope for the best.
105107
106108#### Reinstall Free Pascal
107109
108110Repeat the previous installation procedure with: Open a terminal.
109111
110112``` bash
111113cd Desktop
112114cd a
113115dpkg -i *.deb
114116```
115117
116118Free Pascal will now install fairly smoothly.
117119
118120##### fp-units-multimedia
119121
120122Only the multimedia unit will not install. This is due to the missing a52cat package. However it may not be critical.
121123
122124#### Check the installation
123125
124126You can check the Free Pascal installation in three ways:
125127
126128- Run it
127129
128130Open a terminal
129131
130-`fpc`
132+```text
133+fpc
134+```
131135
132136it should open in the terminal.
133137
134138- Look in Synaptic and check that fpc and fpc-src have been installed.
135139- Find the files
136140
137141You can see where the files are stored with
138142
139143``` bash
140144sudo dpkg -L fpc
141145```
142146
143147### Install Lazarus
144148
145149This is similar to Free Pascal
146150
147151Open a terminal.
148152
149153``` bash
150154cd Desktop
151155cd b
152156dpkg -i *.deb
153157```
154158
155159and the installation will proceed.
156160
157161#### Errors
158162
159163An error occurs installing package lcl-qt4-0.9.30.
160164
161165##### lcl-qt4-0.9.30
162166
163167From the terminal output you can see that the unit can not be installed due to a dependency on ... However, if you read the information that appears in Synaptic for this package then it says
164168
165169"Actually this is an empty package but ..."
166170
167171I think we can safely ignore it.
168172
169173#### Test
170174
171175Open Lazarus and try to create a simple 'Hello World' application with a button click. It worked with mine and the installation is complete.
172176
173177##### Check with Synaptic
174178
175179You can check that Lazarus has been installed with Synaptic
176180
177181##### Fix Broken packages
178182
179183Unfortunately, I now have 2 broken packages on my Ubuntu system, fp-multimedia and lcl-qt4. I choose 'Edit/Fix broken Packages and the fp-multimedia unit goes green but the lcl-qt4 package goes bright red - not normally a good sign. However if you select
180184
181-`Apply`
185+```text
186+Apply
187+```
182188
183189then Ubuntu will fix the multimedia package and remove the qt4 package. Everything is then in order.
184190
185191### Final test
186192
187193Create a Hello World application with a button and a label. If this works then things are looking good. Lazarus is installed.
188194
189195## See also
190196
191197- [[Install on Ubuntu]]
192198
193199---
194200*From the Free Pascal wiki, page "Install on Ubuntu from .deb files", as it stood on 2022-06-05 after a change by Malcome, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).*
195201Category: Install
196202Category: Ubuntu

Back to history