help-cgicc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

cgicc + FastCGI, patch


From: Volker Wysk
Subject: cgicc + FastCGI, patch
Date: Thu, 18 Oct 2001 14:26:41 +0200 (CEST)

Hi

The cgicc website says, cgicc was compatible with FastCGI. This is not
really true.

You could modify the cgicc source files to #include FastCGI's CGI
compatibility library "fcgi_stdio.h". Then cgicc could actually work with
FastCGI (haven't tried it). "fcgi_stdio.h" contains #define's for things
like "stdin", "fopen" and "fprintf".

However, you wouldn't want to use the compatibility library for C++
programs, because you would have to do C style I/O. It would also make
cgicc's HTML generation facilities useless. You'd rather want to use
"fcgiapp.h" and "fcgio.h", which implements C++ streams on top of the
FastCGI streams. So you can do normal C++ I/O, using the "<<" and ">>"
operators.

I've patched cgicc to really be compatible with FastCGI. The patch is
attached. It makes some (compatible) modifications to the Cgicc and
CgiEnvironment classes, and introduces the new subclasses Fcgicc and
FcgiEnvironment to be used instead, in FastCGI programs.

Use "patch -p0 < cgicc-fastcgi-patch" in the cgicc-3.1.5 directory to
apply the patch.

The patch remains yet to be integrated into to configuration script.
Something like "--with-fastcgi" should be added. (Don't know how to do
this). I could also provide a skeleton program for documentation on how to
use FastCGi and cgicc together, if the maintainer wants to include the
patch in the cgicc distribution.

Yours,
Volker Wysk

Attachment: cgicc-fastcgi-patch
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]