Recent

Author Topic: Updated Curlpas anyone?  (Read 6544 times)

kpeters58

  • Sr. Member
  • ****
  • Posts: 267
Updated Curlpas anyone?
« on: July 25, 2016, 06:03:13 pm »
Just downloaded CurlPas and saw it's from 2005 - so no surprise that it breaks all over the place when trying to compile with 1.6.

Does anybody have an updated version?
Lazarus 2.0.4/FPC 3.0.4/Win 64

Thaddy

  • Hero Member
  • *****
  • Posts: 14364
  • Sensorship about opinions does not belong here.
Re: Updated Curlpas anyone?
« Reply #1 on: July 25, 2016, 08:04:21 pm »
You don't need it. You'll probably already have it... ;)
Curl bindings  come as standard with FreePascal and is under packages/libcurl.
A little while ago (less than a year) I submitted a patch to get the examples working for Windows too (applied in trunk by Florian) and at that time I also checked en tested if there was major funtionality missing: there wasn't.
It may have a refresh when I have time, but there really is no need for it except for SSL protocol related support that definitely needs updating. I have some internal patches for that, but it still needs work at places I don't need myself and it has no priority.

IOW: Curlpas is outdated but the standard version in FPC isn't. The libcurl  standard one that is included with FPC is recently tested and compiles without errors for all platforms for which libcurl is supported.

If you need help (e.g. enabling a recent feature) , plz ask: there are not many people that use curl on Pascal Platforms, they rather tend to use Pascal native solutions like fcl-web (also standard) or synapse. But I use it myself sometimes.

Note that basic URL support is also in Lazarus as standard and takes just the inclusion of lclintf in your project: GetURL etc.... Just as convenient.
« Last Edit: July 25, 2016, 08:38:23 pm by Thaddy »
Object Pascal programmers should get rid of their "component fetish" especially with the non-visuals.

tianya

  • New Member
  • *
  • Posts: 25
Re: Updated Curlpas anyone?
« Reply #2 on: August 11, 2017, 03:35:32 pm »
how to use libcurl in mac os and windows,I have some problems in them.
In Mac os:
   the lazarus only support i386,but the libcurl is 64 bit.
In Windows:
   I use the unit,libcurl but the lazarus show error like : can't find libcurl.

Thaddy

  • Hero Member
  • *****
  • Posts: 14364
  • Sensorship about opinions does not belong here.
Re: Updated Curlpas anyone?
« Reply #3 on: August 11, 2017, 03:39:41 pm »
On windows you have to install the proper dll.  See the official website: https://curl.haxx.se/download.html
AFAIK on MAC both 32 bit and 64 bit are supported, but you need a 64 bit Lazarus install for the 64 bit libcurl. (of course!)
Also note libcurl is not available for Windows in FPC versions before 3.0.2. I enabled it for Windows only last year. See also my previous notes.
« Last Edit: August 11, 2017, 03:52:15 pm by Thaddy »
Object Pascal programmers should get rid of their "component fetish" especially with the non-visuals.

tianya

  • New Member
  • *
  • Posts: 25
Re: Updated Curlpas anyone?
« Reply #4 on: August 11, 2017, 04:36:38 pm »
thank you for your reply :D

tianya

  • New Member
  • *
  • Posts: 25
Re: Updated Curlpas anyone?
« Reply #5 on: August 11, 2017, 05:39:36 pm »
On windows you have to install the proper dll.  See the official website: https://curl.haxx.se/download.html
AFAIK on MAC both 32 bit and 64 bit are supported, but you need a 64 bit Lazarus install for the 64 bit libcurl. (of course!)
Also note libcurl is not available for Windows in FPC versions before 3.0.2. I enabled it for Windows only last year. See also my previous notes.
I'm Sorry,In windows 32bit system,In the 'C:\lazarus\fpc\3.0.2\units\i386-win32',I cant find libcurl
[100%] Skipped package libcurl which has been disabled for target i386-win32

Thaddy

  • Hero Member
  • *****
  • Posts: 14364
  • Sensorship about opinions does not belong here.
Re: Updated Curlpas anyone?
« Reply #6 on: August 12, 2017, 08:03:18 am »
You have an old version of Freepascal. libcurl is enabled for win32 in 3.0.2
Object Pascal programmers should get rid of their "component fetish" especially with the non-visuals.

tianya

  • New Member
  • *
  • Posts: 25
Re: Updated Curlpas anyone?
« Reply #7 on: August 12, 2017, 08:34:23 am »
You have an old version of Freepascal. libcurl is enabled for win32 in 3.0.2
,i use the C:\lazarus\fpc\3.0.2\,and the same error in lazarus 1.8rc4

Thaddy

  • Hero Member
  • *****
  • Posts: 14364
  • Sensorship about opinions does not belong here.
Re: Updated Curlpas anyone?
« Reply #8 on: August 12, 2017, 08:53:25 am »
Maybe my patch was not backported from trunk after all. That could have been done since I submitted the patch may/june last year, before the freeze for 3.0.2.
Anyway, it is just a header file, so copy the sourcecode of the header and it will work. (The example just doesn't work without a small change, but the library will work)
Object Pascal programmers should get rid of their "component fetish" especially with the non-visuals.

tianya

  • New Member
  • *
  • Posts: 25
Re: Updated Curlpas anyone?
« Reply #9 on: August 12, 2017, 02:47:06 pm »
how cant i do then?...

Thaddy

  • Hero Member
  • *****
  • Posts: 14364
  • Sensorship about opinions does not belong here.
Re: Updated Curlpas anyone?
« Reply #10 on: August 12, 2017, 02:49:29 pm »
You can... explain?
Object Pascal programmers should get rid of their "component fetish" especially with the non-visuals.

tianya

  • New Member
  • *
  • Posts: 25
Re: Updated Curlpas anyone?
« Reply #11 on: August 12, 2017, 03:26:15 pm »
Is there any tutorial 、 sample,or lazarus component about libcurl?

Almir.Bispo

  • Jr. Member
  • **
  • Posts: 91
  • CSV Comp DB is the Best NoSQL
    • CSV Comp DB (NoSQL)
Re: Updated Curlpas anyone?
« Reply #12 on: August 12, 2017, 04:37:22 pm »
You can use the Synapse library (http,tcp,etc)
http://synapse.ararat.cz/doku.php
CSV Comp DB Developer {Pascal Lover}

tianya

  • New Member
  • *
  • Posts: 25
Re: Updated Curlpas anyone?
« Reply #13 on: August 12, 2017, 04:56:07 pm »
perfect,Although this is good,  still wants the FPC to support libcurl better

 

TinyPortal © 2005-2018