It seems to be more difficult with Xubuntu 16.
While I was successful in installing Free Pascal (including compiling and running a simple FPC program) Lazarus is unable to link due to an unmet dependency (the missing library is probably libgtk1.2-dev. It cannot be installed with apt, however).
I'm using Xubuntu 16 LTS and I had't had any problem installing and updating from the ubuntu repository. It isn't the latest build but it works perfectly.
How did you install Lazarus?
I used a fresh installation of Xubuntu 16.04, first installed Free Pascal with
sudo apt-get install fpc and then Free Pascal sources with
sudo apt-get install fpcsrc.
I wasn't able, however, to install Lazarus with
sudo apt-get install lazarus, since APT complained about unmet dependencies.
I then tried to force install Lazarus from a downloaded deb package with
sudo dpkg -i lazarus-project_1.6.4-0_i386.deb. This in fact resulted in a working IDE, but if I try to compile a very simple program I get an error message as shown in the attached screen shot.
Checking the installation with
sudo apt-get check delivers the following reply:
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
lazarus-project : Depends: libgtk2.0-dev (>= 2.6.0) but it is not installed
E: Unmet dependencies. Try using -f.Obviously, the missing libgtk2.0-dev prevents building apps with GUI, since I am able to build normal FPC console mode programs without any problem. Unfortunately, I am unable to install this library, since apt didn't find it in the standard repositories and I didn't find a package as well.