* * *

Author Topic: Is libcurl ready to use  (Read 4975 times)

Goodman H__

  • Full Member
  • ***
  • Posts: 130
Is libcurl ready to use
« on: September 03, 2013, 09:31:15 am »
Greetings to everybody here!

Could be a silly question.But I failed to compile the exampe program under \lazarus\fpc\2.7.1\source\packages\libcurl\examples\testcurl.pp

I got an error something like :
Code: [Select]
cant' find unixtypeWhen I tried to add unit unixtype to the projecct ,it complained again:
Code: [Select]

could not find ptypes.inc

I stopped.I think this coul not work.

Is there anything I missed?

God,I was always encountering such issues that the project(compiler)can't find some unit ,I can search them in some folders and added them into the project by Project->Options->Paths.But to be honest,I don't quite understand 'Other unit files','Include Files','Libraries',to which I should add the file (In C/C++ I know whether a header file ,source file(s) or a lib file is missed.).So sometimes it works,sometimes the compiler still complains after I feed the files to the project.

Help would be much appreicated.

Regards,
Sam
« Last Edit: September 03, 2013, 09:38:33 am by Goodman H__ »
fpc:2.6.1 Lazarus:1.1 SVN39277
OS:win 7

marcov

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 5644
Re: Is libcurl ready to use
« Reply #1 on: September 03, 2013, 10:18:30 am »
Those are unix libs, IOW the header is simply not supported for Windows. 

Libcurl is quite unix centric, and people on Windows usually use a socket suite(Indy, Synapse) or something from the wininet api/unit. (which has FTP and http methods that also honor systemwide configured proxies)

Moreover, there is no "one" C compiler on Windows, so there could be up to 4 different libcurls in common use (cygwin or mingw could also be static, and MSVC, BCB in DLL form)

Goodman H__

  • Full Member
  • ***
  • Posts: 130
Re: Is libcurl ready to use
« Reply #2 on: September 03, 2013, 11:35:58 am »
Those are unix libs, IOW the header is simply not supported for Windows. 

Libcurl is quite unix centric, and people on Windows usually use a socket suite(Indy, Synapse) or something from the wininet api/unit. (which has FTP and http methods that also honor systemwide configured proxies)

Moreover, there is no "one" C compiler on Windows, so there could be up to 4 different libcurls in common use (cygwin or mingw could also be static, and MSVC, BCB in DLL form)

Got it.Thanks.May I know what's the best recommendation of a crossplatform library in freepascal/Lazarus then?
fpc:2.6.1 Lazarus:1.1 SVN39277
OS:win 7

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: Is libcurl ready to use
« Reply #3 on: September 03, 2013, 11:42:34 am »
Would be nice to patch it with note in the source that the program is unix only just to make it clear.

http://bugs.freepascal.org/view.php?id=24948
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: Is libcurl ready to use
« Reply #4 on: September 03, 2013, 11:44:13 am »
May I know what's the best recommendation of a crossplatform library in freepascal/Lazarus then?
I think that differs for each programmer. I find Synapse quite workable; e.g.
http://wiki.lazarus.freepascal.org/synapse#From_an_HTTP_server
AFAIR, Synapse also has proxy support, but haven't used it...
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

Goodman H__

  • Full Member
  • ***
  • Posts: 130
Re: Is libcurl ready to use
« Reply #5 on: September 03, 2013, 12:15:02 pm »
May I know what's the best recommendation of a crossplatform library in freepascal/Lazarus then?
I think that differs for each programmer. I find Synapse quite workable; e.g.
http://wiki.lazarus.freepascal.org/synapse#From_an_HTTP_server
AFAIR, Synapse also has proxy support, but haven't used it...

Sorry,do you mean Synapse is cross-platform,both for win* and *nix?Thanks.
fpc:2.6.1 Lazarus:1.1 SVN39277
OS:win 7

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: Is libcurl ready to use
« Reply #6 on: September 03, 2013, 12:19:54 pm »
Yes, I do mean Synapse is cross-platform. Have run it e.g. on Windows and Linux.
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

Leledumbo

  • Hero Member
  • *****
  • Posts: 7649
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: Is libcurl ready to use
« Reply #7 on: September 03, 2013, 05:15:13 pm »
Synapse for code oriented (though there's visual synapse, but I don't know its state), lnet for component based or just use fcl-web (not as complete as others AFAIK, but should be enough for most usage and has a better future support since it's officially part of fpc). All of them are cross platform.

Goodman H__

  • Full Member
  • ***
  • Posts: 130
Re: Is libcurl ready to use
« Reply #8 on: September 14, 2013, 02:51:20 pm »
Thank you all!
fpc:2.6.1 Lazarus:1.1 SVN39277
OS:win 7

tianya

  • New member
  • *
  • Posts: 11
Re: Is libcurl ready to use
« Reply #9 on: August 11, 2017, 05:13:58 pm »
Synapse for code oriented (though there's visual synapse, but I don't know its state), lnet for component based or just use fcl-web (not as complete as others AFAIK, but should be enough for most usage and has a better future support since it's officially part of fpc). All of them are cross platform.
I'm Sorry,In windows 32bit system,In the 'C:\lazarus\fpc\3.0.2\units\i386-win32',I cant find libcurl,how can i build it?

 

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus