[Lazarus] version `GLIBC_2.34' not found error when running app on different PC
Bo Berglund
bo.berglund at gmail.com
Fri Mar 17 13:54:24 CET 2023
On Fri, 17 Mar 2023 08:43:55 +0100 (CET), Michael Van Canneyt via lazarus
<lazarus at lists.lazarus-ide.org> wrote:
>FPC has not changed. It still works the same.
>Everything that is under control of FPC is linked statically.
>
>But a complex GUI system like the LCL uses GTK/GDK/Qt and other libraries,
>and those are dynamic, external libraries over which FPC or lazarus has no control.
This aplication is a console (i.e NO GUI) application and it only uses these
units:
videosplitcmb.lpr:
uses
{$IFDEF UNIX}
cthreads,
{$ENDIF}
Classes,
{ you can add units after this }
sysutils,
utils,
runthread;
and
utils.pas:
uses
Classes,
SysUtils,
Process;
What is complex here?
>If you use a unit that relies on LibC somewhere, you automatically depend on the libc
>version.
Since I am only using FPC units, how can I know???
>> Developing on an up-to-date system should ensure the output could work
>> everywhere, but not so now it appears....
>
>No-one can ensure this. It was never so. It used to be worse in the past.
>
>Distributions change, and sometimes break binary compatibility.
>This means you must cater for that.
>
>There are roughly 2 ways:
>- Compile on a system that has the correct version of libraries as on the
> target computer.
I checked out the project into another Ubuntu 20.04 device with Lazarus/FPC
available.
Project compiled just fine and this binary runs on 20.04 and 22.04...
>> Notice: This is a command line utility so it needs no access to any GUI
>> components at all...
>
>You use libc through some unit that is included in your sources. The libc
>library on both systems you tested on differ too much, that is why you have
>the error.
Well, since I have *not* added any units except what is supplied by FPC/Lazarus
I don't understand what this means for a simple command line utility which uses
TProcess to start instances of ffmpeg....
--
Bo Berglund
Developer in Sweden
More information about the lazarus
mailing list