Recent

Author Topic: Starting chromium-browser from within a lazarus program  (Read 8277 times)

rvk

  • Hero Member
  • *****
  • Posts: 6111
Re: Starting chromium-browser from within a lazarus program
« Reply #15 on: February 22, 2018, 11:32:19 am »
Hi, adding uses fclHttpClient and then compiling gives an error from sslsockets, saying that it can't find openssl. There is no sign of a package fclweb in the components directory.
It's fpHttpClient.

But if it's not working for you, you seem to have a non standard install (or older Lazarus).
The package for fcl-web is in fpc/packages/fcl-web but as I said, I didn't need to add this.

What version of FPC and Lazarus do you have (Help > About Lazarus).
And how did you install it?

As far as I can see the normal Lazarus 1.8 install doesn't need the fcl-web package as requirement to use TfpHttpClient.

BLL

  • Sr. Member
  • ****
  • Posts: 276
Re: Starting chromium-browser from within a lazarus program
« Reply #16 on: February 22, 2018, 06:47:48 pm »
I have fpc 3.0.0 and lazarus 1.7, RasPi3 running jessie, which I understand to be the latest available for the RaspberryPi. I know that a special version is needed for the RasPi and so one can't just use the latest version!
I can see fcl-web in /fpc/packages, but they are .pp files.

However, as I said, when I add uses fclHttpClient, I get that sslsocket error message.

I simply don't know enough about lazarus to work out what to do to sort it! I came from CBuilder, where things were so much simpler!
I wish I could get webLaz to install but it won't and nobody can tell me how to get it to do so.

In frustration.

Brian

rvk

  • Hero Member
  • *****
  • Posts: 6111
Re: Starting chromium-browser from within a lazarus program
« Reply #17 on: February 22, 2018, 07:52:00 pm »
I have fpc 3.0.0 and lazarus 1.7, RasPi3 running jessie, which I understand to be the latest available for the RaspberryPi. I know that a special version is needed for the RasPi and so one can't just use the latest version!
What gave you the idea that you can't use the latest version. Lazarus 1.7 is a "middle" version (odd number) so not an official release but probably compiled from source (trunk?). But for the RPI no special version is needed. I install Lazarus trunk (now 1.9) regularly on the RPI3 (with my own script) and it works perfectly.

Quote
I can see fcl-web in /fpc/packages, but they are .pp files.
Yes, .pp files are source files (just like .pas).

Quote
However, as I said, when I add uses fclHttpClient, I get that sslsocket error message.
Maybe your install is not done correctly. How did you install Lazarus 1.7 ????

If you used fpcupdeluxe, you can update it again.

Besides that, for Lazarus (and FPC) to work correctly there are some Linux packages that need to be installed. Normally the installation process would take care of that but maybe for you it didn't.

I have this in my script:
Quote
sudo apt-get -y install libx11-dev libgdk-pixbuf2.0-dev libcairo2-dev lpango-1.0 libpangox-1.0-dev xorg-dev libatk1.0-dev libgtk2.0-dev >/dev/null
sudo apt-get -y install libssl-dev >/dev/null # for all your ssl stuff
sudo apt-get -y install build-essential p7zip-full subversion >/dev/null

The libssl-dev is for the ssl stuff so you could try this in a terminal:
Quote
sudo apt-get -y install libssl-dev >/dev/null # for all your ssl stuff

But I'm sure your installation is not correct because if you add fpHttpClient, it shouldn't want to compile sslsockets, because that should already be compiled earlier during installation.


(I just tried the given example, without adding any requirements, so just fpHttpClient in the uses and it worked on my RPI3. I also just added weblaz 1.0 package, not needed for the example, and that worked too. The weblaz is for GUI elements like TfpHttpWebClient)

 

TinyPortal © 2005-2018