[fpc-pascal] A linking error when compiling with FPC 2.4.4
Michael Van Canneyt
michael at freepascal.org
Mon Oct 31 13:31:27 CET 2011
On Mon, 31 Oct 2011, Marco van de Voort wrote:
> In our previous episode, Michael Van Canneyt said:
>>> finer. (-dyn and static in separate packages, so that the static one alone
>>> gets the dependency. Lazarus then only depends on the dyn packages).
>> That would be a regular nightmare, because there are many packages that depend
>> on fcl-db, and this would split all these packages in 2 variants.
>> There is a good reason that apache, php, ODBC and many other large programs/
>> libraries introduced dynamically loadable packages. It saves you from
>> having to recompile everything for your particular system, and thus makes
>> maintenance and installation simpler.
>> So if anything, IMHO we should make all packages that link in external C libs
>> "dynamically loaded".
> This only shifts the problem from having to say "install the static version
> of the C lib" to having to say "install the relevant FPC/lazarus db package".
I don't understand this remark ? What static version of the C lib ?
The -dev packages install a symlink (.so) and header files, not a static lib.
It's been years since I've seen a static lib installed, and as a rule,
I install lots of -dev packages.
As for additional work: we need to do the work anyway.
If a lib changes versions, we need to adapt our units anyway, dynamic or not.
More information about the fpc-pascal