cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: libcurl (perl) and windows

From: lupusdacicus <lupusdacicus_at_juno.com>
Date: Mon, 4 Nov 2002 23:39:53 -0800

> My install/fix process:

I have seen/read this message before I even wrote you. It's not working in
my case. I didn't even had libcurl.lib, because I didn't know how to compile
it. I tried with Visual C, but I had to many errors. Anway, after other 3
hours (or more) or research, I was able to compile the sources and have
libcurl.lib and libcurl.dll.

This step by step tutorial was very helpful and it's why I could actually
use VC to compile the files.
http://curl.haxx.se/libcurl/c/visual_studio.pdf

For future versions of curl, or maybe on the web site, I think it would be
helpful if you had a windows development FAQ, maybe even have the link to
some windows compilers, Nmake and such.

As I said this document (http://curl.haxx.se/libcurl/c/visual_studio.pdf)
was very helpful, but I am doing something wrong, or there is something
wrong with some of the files and settings from my perl/vc++, because at the
end of that tutorial, I couldn't even get that simple.c program working. I
mean, yes, I want to be able to use perl, but I am not that afraid of C
either, although there are many things/features/syntax that I forgot or
never even used. But if I was able to use libcurl from VC, I may one day be
able to develop programs that can be used on any windows machine... anyway,
when trying to run simple.c I was told something like:
"Unexpected end of file simple.c"... and something/error with linking header
files.

Now when I reopened VC++, I am told something else... I can do compile
(ctrl+f7):
--------------------Configuration: My curl application - Win32
Debug--------------------
Compiling...
Skipping... (no relevant changes detected)
My curl application.cpp

My curl application.obj - 0 error(s), 0 warning(s)

_____

But when trying to run/build (F7) the script:

--------------------Configuration: My curl application - Win32
Debug--------------------
Linking...
My curl application.obj : error LNK2001: unresolved external symbol
_curl_easy_cleanup
My curl application.obj : error LNK2001: unresolved external symbol
_curl_easy_perform
My curl application.obj : error LNK2001: unresolved external symbol
_curl_easy_setopt
My curl application.obj : error LNK2001: unresolved external symbol
_curl_easy_init
Debug/My curl application.exe : fatal error LNK1120: 4 unresolved externals
Error executing link.exe.

My curl application.exe - 5 error(s), 0 warning(s)
______

If I spend another hour looking, maybe I will pass this error, but I will
get stuck in another one...

Hmm, I am just thinking... Is there any way that we could convince the guys
from Active State to invlude libcurl in their PPM library ? That would
simplify the whole proces... supposing that the installation process goes
fine when using their PPM tool.

And have you thought about making curl and libcurl available from CPAN.ORG
too ?

> - Decompress tar.gz

I was using alladin expander, but something wouldn't work now.
I found ICEOWS, this 100% free unzipping software available from
download.com and it knows how to unzip tar.gz files.

> - Edit Makefile.PL to add correct curl-7.9.7 include directory in
@includes

I did this long time ago. I just wish this was the only problem.

> - perl Makefile.PL

The only reasons I installed active state is because I wanna use
curl/libcurl from perl.

> - Edit Makefile
> - Line 264, Add "libcurl.lib" to LDLOADLIBS variable

I did this today.

> - Make sure libcurl.lib is installed in the VC6 lib directory

There was no libcurl.lib on my PC. Because I couldn't compile the SRC files.
I did with the help of the PDF file I mentiones earlier.

> - nmake

It crashes, because of the compiler. It says:

cl -c -I -nologo -O1 -MD -DNDEBUG -DWIN32 -D_CONSOLE -DNO_STRICT -DHAVE_DES_
FCRYPT -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -DPERL_MSVCRT_READFIX -O1
 -MD -DNDEBUG -DVERSION=\"1.35\" -DXS_VERSION=\"1.35\" -IC:\Perl\lib\CO
RE -DHAVE_INTERNAL_VARS easy.c
easy.c
Command line error D2027 : cannot execute 'c1'

I am thinking, now that I am actually having the libcurl.lib and
libcurl.dll, is there anyway to tell (n)make to use those files ?

> - nmake test
> - nmake install
>
> Hope this helps. I'm running Win2k with Activeperl 5.6.1 build 631. And
> I'm using libcurl 7.9.7.

I am running win98se. And the latests active perl and libcurl distribution.

-------------------------------------------------------
This sf.net email is sponsored by: See the NEW Palm
Tungsten T handheld. Power & Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0001en
Received on 2002-11-06