Recent

Author Topic: Rant: Lazarus on Linux: messed up. Completely.  (Read 39581 times)

SymbolicFrank

  • Hero Member
  • *****
  • Posts: 1313
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #15 on: February 07, 2017, 06:42:38 pm »
Mint, based on Ubuntu, with packages build for Debian.  8-)

jacmoe

  • Full Member
  • ***
  • Posts: 249
    • Jacmoe's Cyber SoapBox
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #16 on: February 07, 2017, 06:44:52 pm »
I am new to Lazarus but I am an experienced Linux user and a developer.

And I am used to install/configure/build software of all sorts.

But Lazarus and FreePascal are not easy!

If you are installing a new Lazarus over an old Lazarus, there will be some FPC/Lazarus settings that - as a general rule - always will confuse the new Lazarus. These settings - I guess they are in ~/.lazarus - must be removed so that Lazarus can recover/regenerate.

I have not used Ubuntu, or any derivative, for years because it is a oddball, buggy distribution IMO. And not making sure that their contributions to Debian gets upstream.
So, I am using Netrunner rolling release based on Debian testing. Their contributions gets back to the Debian project, and it provides both stability and a fresh, new set of packages. Highly recommended!

I don't like to use the Sourceforge hosted packages for Lazarus/FreePascal because they are not configured properly. Otherwise, if they were, Debian wouldn't think they need to be upgraded to older versions.

I've installed Lazarus 1.6.2 from Debian repositories and it works fine.
But not great. :)
Because you either have to do some magic as a root user or simply compile third-party packages in your project so that the ppu's can be found - or, I guess, figure out a way to specify the default unit output directory..

The next time I am going to install Lazarus, however, will be from source, so that Lazarus and FreePascal gets installed into my home directory. Which will enable me to compile/recompile the IDE and packages and also install new packages without running into permission issues.

One thing that I've already learned about Lazarus and FreePascal is that it is extremely sensitive. So if you are going to upgrade Lazarus, you better hunt down and completely remove each and every package!

Lastly, I think that Lazarus and FreePascal are really missing out on a big opportunity when it's not using a package manager of its own.
Python has that, Node.js has that, Rust has that, why not FPC/LCL ?
That would simplify installation/upgrade/modification to great extent.
The packages can be installed either locally or globally and that would mean that the only packages that needs to be maintained are one for Lazarus and one for FreePascal. All the rest are FreePascal packages. 
« Last Edit: February 07, 2017, 07:02:00 pm by jacmoe »
more signal - less noise

jacmoe

  • Full Member
  • ***
  • Posts: 249
    • Jacmoe's Cyber SoapBox
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #17 on: February 07, 2017, 06:48:40 pm »
Meanwhile I tried to re-compile the IDE, the current error message is:

"Cannot find interfaces used by Lazarus, incompatible ppu={path}, package LCL

Could you delete the
Code: Pascal  [Select][+][-]
  1. ~/.lazarus
directory and try again?
more signal - less noise

Handoko

  • Hero Member
  • *****
  • Posts: 5131
  • My goal: build my own game engine using Lazarus
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #18 on: February 07, 2017, 06:53:52 pm »
Sad to hear that Lazarus has so much issues.

I always take notes for useful things. Here I share some of them.

Full Lazarus Reinstallation ( UbuntuMate )

01. Uninstall lazarus, fpc, fpc-src
02. Delete ~/.lazarus, except: editoroptions, environmentoption
04. Delete /etc/fp.*
03. Delete /usr/share/fpcsrc
05. Delete /usr/lib/fpc
06. Delete /usr/bin/ppc*
07. Install fpc_3.0.0-151205_amd64.deb
08. Install fpc-src_3.0.0-151205_amd64.deb
09. Install lazarus_1.6-0_amd64.deb
Note:
- I configure my Lazarus to suit my needs, so I keep editoroptions and environmentoption.
- The file names maybe different depend on the version of them.


Cross Compile Win32 ( Ubuntu Mate )

01. cd /usr/share/fpcsrc/3.0.0
02. sudo make clean all OS_TARGET=win32 CPU_TARGET=i386
03. sudo make crossinstall OS_TARGET=win32 CPU_TARGET=i386 INSTALL_PREFIX=/usr
04. sudo ln -sf /usr/lib/fpc/3.0.0/ppcross386 /usr/bin/ppcross386

Note:
I don't use default Ubuntu Repository to instal Lazarus because as far as I know, their Lazarus (and FPC) often not up to date.
« Last Edit: February 07, 2017, 06:56:48 pm by Handoko »

jacmoe

  • Full Member
  • ***
  • Posts: 249
    • Jacmoe's Cyber SoapBox
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #19 on: February 07, 2017, 07:00:48 pm »
The 9 steps to reinstallation assumes that one have used the downloaded from Sourceforge packages; it would be a dangerous path to take if you have used the Debian package manager. There you just have to search and destroy all 'free pascal' and 'lazarus' related packages.
However, after having done a 'completely remove' round in the package manager, we can use it to check if there are remains on the system. Which is handy.
more signal - less noise

Handoko

  • Hero Member
  • *****
  • Posts: 5131
  • My goal: build my own game engine using Lazarus
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #20 on: February 07, 2017, 07:04:10 pm »
I agree with what you said.

--- edited:
I forgot to mention I use Synaptic Package Manager to do the uninstallation (in the 9 steps). It is not wise to delete those files directly.
« Last Edit: February 07, 2017, 07:22:06 pm by Handoko »

DonAlfredo

  • Hero Member
  • *****
  • Posts: 1739
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #21 on: February 07, 2017, 07:19:50 pm »
I still think fpcupdeluxe is worth a try ...  disclaimer: I am the (non-patient) maintainer ...  :D :D

edit: non-patient
« Last Edit: February 07, 2017, 07:46:51 pm by DonAlfredo »

Handoko

  • Hero Member
  • *****
  • Posts: 5131
  • My goal: build my own game engine using Lazarus
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #22 on: February 07, 2017, 07:28:41 pm »
Be patient.

He is now trying Ubuntu - my suggestion  ::)

ArminLinder

  • Sr. Member
  • ****
  • Posts: 314
  • Keep it simple.
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #23 on: February 07, 2017, 07:57:37 pm »
 ;D
Guys, we have progress.

The fpcupdeluxe tool indeed did the trick.

And there is now a starter on my desktop (not startlaz, the name is Lazarus_fpcupdeluxe)

Started Lazarus, compiled empty app, compiled "Hello" and compiled Lazarus - no problem whatsoever. Debugger tested OK too.

There's one thing left now to be done: how can we take care so the next one trying to get Lazarus started on Linux does not have to spend 2 full days following clues and doing endless trial and error to get Lazarus up and running?

Armin.

Lazarus 3.3.2 on Windows 7,10,11, Debian 10.8 "Buster", macOS Catalina, macOS BigSur, VMWare Workstation 15, Raspberry Pi

ArminLinder

  • Sr. Member
  • ****
  • Posts: 314
  • Keep it simple.
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #24 on: February 07, 2017, 08:00:35 pm »
Mint, based on Ubuntu, with packages build for Debian.  8-)

Where do you read "Debian only" anywhere on the Lazarus pages? Please send a link ...

Armin.
Lazarus 3.3.2 on Windows 7,10,11, Debian 10.8 "Buster", macOS Catalina, macOS BigSur, VMWare Workstation 15, Raspberry Pi

ArminLinder

  • Sr. Member
  • ****
  • Posts: 314
  • Keep it simple.
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #25 on: February 07, 2017, 08:06:32 pm »
Last contribution: we habe the nth variant of installation directory:

fpcupdeluxe put everything into

"/home/[my username]/fpcupdeluxe/lazarus"

Greetz,

Armin.
« Last Edit: February 07, 2017, 09:18:16 pm by Nimral »
Lazarus 3.3.2 on Windows 7,10,11, Debian 10.8 "Buster", macOS Catalina, macOS BigSur, VMWare Workstation 15, Raspberry Pi

Handoko

  • Hero Member
  • *****
  • Posts: 5131
  • My goal: build my own game engine using Lazarus
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #26 on: February 07, 2017, 08:31:35 pm »
Glad to know you now have made it works.

Still a big question to me, why you failed on Ubuntu Mint. I'm sure to try Lazarus on Mint someday.

Thanks jacmoe for recommending Netrunner. I've just checked the info about it. Although I prefer the lightweight Mate, but Netrunner seems worth to try.

I heard a lot about fpcupdeluxe. But because Lazarus installation never be a problem for me, I never try it. It should mention on the wiki page, if for some unknown reasons Lazarus fails to install correctly, one may try  fpcupdeluxe.

DonAlfredo

  • Hero Member
  • *****
  • Posts: 1739
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #27 on: February 07, 2017, 08:36:36 pm »
Yep.

Fpcupdeluxe does an isolated install. By default in your home-directory, only for you.
No paths are changed. That is why you need that link to start.
You can install many versions.
E.g. I have latest trunk, stable, NewPascal, 3.0 and 2.6.4, all in their own directory with their own link on my desktop.
For easy testing (fast GB's comes cheap these days).

Fpcupdeluxe also makes life easy when installing cross-compilers.

Its just a way to ease the install.
« Last Edit: February 07, 2017, 08:38:11 pm by DonAlfredo »

ArminLinder

  • Sr. Member
  • ****
  • Posts: 314
  • Keep it simple.
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #28 on: February 07, 2017, 08:43:28 pm »
I heard a lot about fpcupdeluxe. But because Lazarus installation never be a problem for me, I never try it. It should mention on the wiki page, if for some unknown reasons Lazarus fails to install correctly, one may try  fpcupdeluxe.

I totally agree, and I also think that the Installation page should be stripped of outdated info. Some of them are really long and time consuming and IMHO rather lead to more confusion than to a working system.

If we consider that everyone starts his Lazarus endeavours by reading that page, it should be as short and helpful as can be, and therefore carefully maintained.

Do you happen to be the maintainer of that page?

Armin.

P.S. And yes, though I finally got a running Mint/Ubuntu system ... as you read this I am busy installing the latest Debian 8.1.7 distro into a new VM...
« Last Edit: February 07, 2017, 09:17:42 pm by Nimral »
Lazarus 3.3.2 on Windows 7,10,11, Debian 10.8 "Buster", macOS Catalina, macOS BigSur, VMWare Workstation 15, Raspberry Pi

jacmoe

  • Full Member
  • ***
  • Posts: 249
    • Jacmoe's Cyber SoapBox
Re: Rant: Lazarus on Linux: messed up. Completely.
« Reply #29 on: February 07, 2017, 08:54:33 pm »
I am currently performing an fpcupdeluxe installation myself - even when I have a working Lazarus/FreePascal global install.
Because having an isolated installation in my home directory allows me to easily rebuild Lazarus and manage packages freely (without any root shenanigans).

So, I agree: fpcupdeluxe should impatiently be the recommended installation option IMO  ;D
more signal - less noise

 

TinyPortal © 2005-2018