Commit 9ff28a82 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

moved to separate module

parent e9aa07f6
Loading
Loading
Loading
Loading

perl/Curl_easy/Changes

deleted100644 → 0
+0 −92
Original line number Diff line number Diff line
Revision history for Perl extension Curl::easy.
Check out the file README for more info.

1.1.8  Thu Sep 20 2001: - Cris Bailiff <c.bailiff@devsecure.com>
    - Re-generate CURLOPT_ constants from curl.h and enhance makefile
      to allow this to be repeated in future or for older versions of
      libcurl. Constants up-to-date for libcurl-7.9(pre)
    - Split tests into t/*.t to simplify each case
    - Add test cases for new SSL switches. This needs ca-bundle.crt
      (from mod_ssl) for verifying test cases.

1.1.7  Thu Sep 13 2001: - Cris Bailiff <c.bailiff@devsecure.com>
    - Documentation Update only - Explicitly state that Curl_easy
      is released under the MIT-X/MPL dual licence. No code changes.

1.1.6  Mon Sep 10 2001: - Cris Bailiff <c.bailiff@devsecure.com>
    - Fix segfault due to changes in header callback behaviour
      since curl-7.8.1-pre3

1.1.5  Fri Apr 20 2001: - Cris Bailiff <c.bailiff@devsecure.com>
    - Add latest CURLOPT_ and CURLINFO_ constants to the constants list

1.1.4  Fri Apr 20 2001: - Cris Bailiff <c.bailiff@devsecure.com>
    - Fix case where curl_slists such as 'HTTPHEADERS' need to
      be re-set over persistant requests

1.1.3  Wed Apr 18 2001: - Cris Bailiff <c.bailiff@devsecure.com>
    - Change/shorten module function names: Curl::easy::curl_easy_setopt
      becomes Curl::easy::setopt etc. This requires minor changes to existing
      scripts....
    - Added callback function support to pass arbitrary SV * (including
	  FILE globs) from perl through libcurl to the perl callback.
	- Make callbacks still work with existing scripts which use STDIO
	- Initial support for libcurl 7.7.2 HEADERFUNCTION callback feature
	- Minor API cleanups/changes in the callback function signatures
	- Added Curl::easy::version function to return curl version string
	- Callback documentation added in easy.pm
    - More tests in test.pl

1.1.2  Mon Apr 16 2001: - Georg Horn <horn@koblenz-net.de>
    - Added support for callback functions. This is for the curl_easy_setopt()
      options WRITEFUNCTION, READFUNCTION, PROGRESSFUNCTION and PASSWDFUNCTION.
      Still missing, but not really neccessary: Passing a FILE * pointer,
      that is passed in from libcurl, on to the perl callback function.
    - Various cleanups, fixes and enhancements to easy.xs and test.pl.

1.1.1  Thu Apr 12 2001:
    - Made more options of curl_easy_setopt() work: Options that require
      a list of curl_slist structs to be passed in, like CURLOPT_HTTPHEADER,
      are now working by passing a perl array containing the list elements.
      As always, look at the test script test.pl for an example.

1.1.0  Wed Apr 11 2001:
    - tested against libcurl 7.7
    - Added new function Curl::easy::internal_setopt(). By calling
      Curl::easy::internal_setopt(Curl::easy::USE_INTERNAL_VARS, 1);
      the headers and content of the fetched page are no longer stored
      into files (or written to stdout) but are stored into internal
      Variables $Curl::easy::headers and $Curl::easy::content.

1.0.2  Tue Oct 10 2000:
    - runs with libcurl 7.4
    - modified curl_easy_getinfo(). It now calls curl_getinfo() that has
      been added to libcurl in version 7.4.

1.0.1  Tue Oct 10 2000:
    - Added some missing features of curl_easy_setopt():
      - CURLOPT_ERRORBUFFER now works by passing the name of a perl
        variable that shall be crated and the errormessage (if any)
	be stored to.
      - Passing filehandles (Options FILE, INFILE and WRITEHEADER) now works.
    Have a look at test.pl to see how it works...

    - Added a new function, curl_easy_getinfo(), that for now always
      returns the number of bytes that where written to disk during the last
      download. If the curl_easy_getinfo() function is included in libcurl,
      (as promised by Daniel ;-)) i will turn this into just a call to this
      function.

1.0  Thu Oct 5 2000:
    - first released version
    - runs with libcurl 7.3
    - some features of curl_easy_setopt() are still missing:
      - passing function pointers doesn't work (options WRITEFUNCTION,
	READFUNCTION and PROGRESSFUNCTION).
      - passing FILE * pointers doesn't work (options FILE, INFILE and
	WRITEHEADER).
      - passing linked lists doesn't work (options HTTPHEADER and
	HTTPPOST).
      - setting the buffer where to store error messages in doesn't work
	(option ERRORBUFFER).

perl/Curl_easy/MANIFEST

deleted100644 → 0
+0 −16
Original line number Diff line number Diff line
Changes
MANIFEST
Makefile.PL
README
easy.pm
easy.xs
curlopt-constants.c
t/00constants.t
t/01basic.t
t/02header-callback.t
t/03body-callback.t
t/04abort-test.t
t/05progress.t
t/06http-post.t
t/07ftp-upload.t
t/08ssl.t

perl/Curl_easy/Makefile.PL

deleted100644 → 0
+0 −87
Original line number Diff line number Diff line
# Makefile.PL for Perl extension Curl::easy.
# Check out the file README for more info.

use ExtUtils::MakeMaker;
# See lib/ExtUtils/MakeMaker.pm for details of how to influence
# the contents of the Makefile that is written.
WriteMakefile(
    'NAME'	=> 'Curl::easy',
    'VERSION_FROM' => 'easy.pm', # finds $VERSION
    'LIBS'	=> ['-lcurl '],   # e.g., '-lm' 
    'DEFINE'	=> '',     # e.g., '-DHAVE_SOMETHING' 
    'INC'	=> '',     # e.g., '-I/usr/include/other' 
    'clean'	=> {FILES => "head.out body.out"}
);

#
# This utility helper generates the constants function from curl.h
#
# It is normally only used by the maintainer, but if you're curl is older
# or missing some constants, you can delete curlopt-constants.c and re-run 'perl Makefile.PL'
#

if (!open(CONSTANTS,"<curlopt-constants.c")) {
    print "Rebuilding curlopt-constants.c for your libcurl version\n";
    close(CONSTANTS); 

#
# You may need to specify where to find curl.h on your platform
# These are guesses only
#
my $curl_h;
HEADER: foreach my $try (qw(

	curl.h                        
	../../include/curl.h              
	/usr/include/curl/curl.h    
	/usr/local/include/curl/curl.h
	C:\\INCLUDE\\CURL\\CURL.H  

	))
{
    if (-e $try) {
	$curl_h=$try;
	last HEADER;
    }
}

if (!defined($curl_h)) {
	die "Could not rebuild curlopt-constants.c - can't find curl.h\n";
}

print "Found curl.h in $curl_h\n";
open (CURL_H,"<".$curl_h) or die "Can't open curl.h\n";
my %types;
my %codes;
while(<CURL_H>) {
    if ($_ =~ m/CINIT\(/ and $_ !~ m/#/) {
	my ($option,$type,$code)=m/.*CINIT\((\w*)\s*,\s*(\w+)\s*,\s*(\d+).*/;
	$types{$option}=$type;
	$codes{$option}=$code;
    }
}
close(CURL_H);

# some things are ifdefed out...
foreach my $ifdef0 (qw(FLAGS PROGRESSMODE))
{
	delete $types{$ifdef0}; delete $codes{$ifdef0};
}

open(CURL_XS,">curlopt-constants.c") or die "Can't write curlopt-constants.c\n";
foreach my $next_initial ('A'..'Z') {
    print CURL_XS "        case '$next_initial':\n";
    my $count=0;
    foreach my $option (sort keys %types) {
	my $initial=substr($option,0,1);
	if ($next_initial eq $initial) {
	    print CURL_XS "            if (strEQ(name, \"$option\")) return CURLOPT_$option;\n";
	    $count++;
	}
    }    
    if ($count) {
	print CURL_XS "            break;\n";
    }
}
close(CURL_XS);
}

perl/Curl_easy/Makefile.am

deleted100644 → 0
+0 −3
Original line number Diff line number Diff line
SUBDIRS = t 

EXTRA_DIST = Changes easy.pm easy.xs curlopt-constants.c Makefile.PL MANIFEST README

perl/Curl_easy/README

deleted100644 → 0
+0 −40
Original line number Diff line number Diff line
README for Perl extension Curl::easy.

The perl module Curl::easy provides an interface to the cURL library "libcurl".
See http://curl.haxx.se/ for more information on cURL and libcurl.

This module requires libcurl and the corresponding headerfiles to be
installed. You then may install this module via the usual way:

    perl Makefile.PL
    make
    make test
    make install

If you have an older version of libcurl, you can remove 'curlopt-constants.c' 
and have it rebuilt by 'perl Makefile.PL'.

You can also do this for a later version of libcurl, except currently
you will have to update the module EXPORTS list manually.

The module provides the same functionality as libcurl provides to C programs,
please refer to the documentation of libcurl. Some examples may be found in
t/*.t.

This software is distributed AS IS, WITHOUT WARRANTY OF ANY KIND, either
express or implied. Send praise, patches, money, beer and pizza to the author.
Send complaints to /dev/null. ;-)

The original author of this software is Georg Horn <horn@koblenz-net.de>
Parts of the callback support, tests and documentation have been added by
Cris Bailiff <c.bailiff@devsecure.com> and Forrest Cahoon <forrest.cahoon@merrillcorp.com>

The current maintainer is Cris Bailiff <c.bailiff@devsecure.com>

The latest version can be downloaded from http://curl.haxx.se/libcurl/perl/
 
Copyright (C) 2000, Daniel Stenberg, , et al.  
You may opt to use, copy, modify, merge, publish, distribute and/or sell
copies of the Software, and permit persons to whom the Software is
furnished to do so, under the terms of the MPL or the MIT/X-derivate 
licenses. You may pick one of these licenses.                                             
Loading