Recent

Author Topic: Does Lazarus depend on Python?  (Read 2985 times)

jollytall

  • New Member
  • *
  • Posts: 37
Does Lazarus depend on Python?
« on: February 01, 2020, 07:20:00 pm »
I had some problems with my Python environment, so I unistalled it. And then Lazarus disappeared too (honestly I did not check what else "apt-get remove" wanted to remove when ran it.
Now I reinstalled Lazarus again, and got Python back.
Why does Lazarus depend on Python, or do I misunderstand something?

Handoko

  • Hero Member
  • *****
  • Posts: 3346
  • My goal: build my own game engine using Lazarus
Re: Does Lazarus depend on Python?
« Reply #1 on: February 01, 2020, 07:38:00 pm »
Lazarus indirectly depends on Python.

If I try to uninstall python3 package, I will be warned that will also uninstall libgdk-pixbuf2.0-dev, libglib2.0-dev, libgtk2.0-dev and some others. They are direct/indirectly required by Lazarus.

https://forum.lazarus.freepascal.org/index.php/topic,45084.msg318076.html#msg318076
https://forum.lazarus.freepascal.org/index.php/topic,44585.msg313650.html#msg313650
« Last Edit: February 01, 2020, 07:40:18 pm by Handoko »

Thaddy

  • Hero Member
  • *****
  • Posts: 9625
Re: Does Lazarus depend on Python?
« Reply #2 on: February 02, 2020, 10:31:11 am »
1. If lazarus is installed through fpcdeluxe, this is the case since it does not touch and update the installed package library.
2. If lazarus is installed through a deb package - preferably from the distribution -  this issue should not exist. I have both Python 2.7 and Python 3.+ on my machine.
If the second option is the case then it is a bug in the Python installer or the distribution provided lazarus installer.
I am more like donkey than shrek

jollytall

  • New Member
  • *
  • Posts: 37
Re: Does Lazarus depend on Python?
« Reply #3 on: February 02, 2020, 06:35:37 pm »
Thanks.
@Handoko: I am not sure I understand. The fact that Python and Lazarus both need some libraries should not mean that removing Python should remove Lazarus. It should remove Python and leave behind those libraries that might have been installed by Python but in the meantime somebody else (Lazarus in this case) also needs it.
@Thaddy . I downloaded the .deb package (2.0.6). The one regular apt-get version is much older (1.6). Btw. is there a reason why there we do not have the latest stable version?

lucamar

  • Hero Member
  • *****
  • Posts: 2383
Re: Does Lazarus depend on Python?
« Reply #4 on: February 02, 2020, 07:49:19 pm »
The one regular apt-get version is much older (1.6). Btw. is there a reason why there we do not have the latest stable version?

It depends on the repository maintainers but the usual rationale behind those kind of decisions boils down to "if it ain't broke ...". When doing a release of a distro the packages making it up (both default and optional) are "frozen" for that release and don't ever change, unless some serious bug is discovered (and fixed) in which case the corresponding package is updated, but then only to a "fixes" build, almost never to a new version.

That rationale and the problems it causes sometimes (as in this case) is why some distros adopted a "rolling release" paradigm: you get updated and upgraded packages at the cost of (almost) never being able to tell which "version" of the distro you're using.

Nevetheless, no distro should be distributing a Lazarus 1.6 by now. Are you using a (relatively) old version of yours?
« Last Edit: February 02, 2020, 07:53:31 pm by lucamar »
Turbo Pascal 3 CP/M - Amstrad PCW 8256 (512 KB !!!) :P
Lazarus 2.0.4/2.0.6  - FPC 3.0.4 on:
(K|L|X)Ubuntu 12..18, Windows XP, 7, 10 and various DOSes.

Handoko

  • Hero Member
  • *****
  • Posts: 3346
  • My goal: build my own game engine using Lazarus
Re: Does Lazarus depend on Python?
« Reply #5 on: February 02, 2020, 08:08:20 pm »
@Handoko: I am not sure I understand. The fact that Python and Lazarus both need some libraries should not mean that removing Python should remove Lazarus. It should remove Python and leave behind those libraries that might have been installed by Python but in the meantime somebody else (Lazarus in this case) also needs it.

You misunderstood what I said.

Do you have Synaptic Package Manager installed? You can use that tool to inspect and learn any package/library. There, you will know Lazarus needs libgdk-pixbuf2.0-dev, libglib2.0-dev, libgtk2.0-dev. And those three libraries need Python.

jollytall

  • New Member
  • *
  • Posts: 37
Re: Does Lazarus depend on Python?
« Reply #6 on: February 03, 2020, 09:56:46 am »
@Handoko
Indeed I misunderstood. It is clear now. Thanks.

@lucamar
I use Debian9 and when I open Synaptic, I see Lazarus 1.6.2. I run regularly apt-get update, so I guess it is the latest I can see there.

lucamar

  • Hero Member
  • *****
  • Posts: 2383
Re: Does Lazarus depend on Python?
« Reply #7 on: February 03, 2020, 11:10:07 am »
I use Debian9 and when I open Synaptic, I see Lazarus 1.6.2. I run regularly apt-get update, so I guess it is the latest I can see there.

Debian 9 was released, IIRC, in Summer, 2017, so it was frozen some months earlier. They are notoriously conservative so instead of releasing the then new 1.6.4 they used the 1.6.2

I'm not sure (never use the distro's repos for Lazarus) but IIRC one could add "sid" to sources.list to get mostly up to date packages. I wouldn't recommend it, but the option is there (I think) ... :-\
Turbo Pascal 3 CP/M - Amstrad PCW 8256 (512 KB !!!) :P
Lazarus 2.0.4/2.0.6  - FPC 3.0.4 on:
(K|L|X)Ubuntu 12..18, Windows XP, 7, 10 and various DOSes.