Gentlemen,
As it turned out, my problems are uglier than I thought at first. I will provide a concise description of them below, in the hope that some of you can enlighten me towards a solution.
I have a (relatively) simple cross-platform application that fetches data from several online databases to present information on biological species in an integrated format (the full source code can be found here:
https://github.com/maurobio/especies.
It compiles and runs without problems under Windows and Linux but (there is always a "but"!) only in a machine that has Lazarus installed. On a machine which has not Lazarus installed, it fails with an "Access violation" error and that is that.
The application uses units fphttpclient, openssl, opensslsockets, DOM, XMLRead, and XPath; therefore it depends upon the OpenSSL and Expat libraries which are, of course, installed along with Lazarus in a regular installation of the IDE. I thought at first that it should be a simple matter of including these libraries in the application folder (at least under Windows), but this do not work. In Windows, I first put the required libraries (libeay32.dll, ssleay32.dll, libexpat.dll) in the application folder, but got an error saying something about the libraries not being compiled for use under Windows. I then installed the OpenSSL binaries (from here:
https://slproweb.com/products/Win32OpenSSL.html), but it did not work either (that is, the application keeps issuing the "Access violation" error).
Under Linux the situation is, of course, a little bit more complicated. In an installation of Linux Mint 21 (without Lazarus installed), I found libssl installed but NOT libcrypto.
What I want it to provide these libraries to users, along with the installation packages for both the Windows and Linux versions. Under Linux, I create a Debian package for distribution the application and so I presume I should include these libraries in the list of dependencies. Under Windows, I use InnoSetup to create executable installation packages and I suppose I should include the required libraries in it to be put in the Windows/System folder. I have successfully deployed other application developed with FPC/Lazarus using both methods, but none of these applications are dependent of these libraries.
Are there some simple and clean ways of getting out of this mess?
Thanks in advance for any assistance you can provide!
With warmest regards,