- From: #LI CHAOHUI# <P145163551@ntu.edu.sg>
- Date: Sun, 25 Feb 2001 18:02:05 +0800
- To: "'www-lib@w3.org'" <www-lib@w3.org>
Hi, everyone:
I have tried to build a CGI program using libwww. However, it seems that
libwww can not be linked into CGI program. To test it, I built a simple
program as follows:
#include <iostream>
#include <string>
int main()
{
cout << "Content-type: text/html" << endl << endl;
cout << "<html>" << endl;
cout << "It is a test message! << endl;
cout << "</html>" << endl;
}
When I compile the above code without linking to libwww, the generated cgi
program works normally and is able to output the text specified in the code.
However, if I compile the program with the following command:
g++ -o test.cgi test.cc `libwww-config --cflags` `libwww-config --libs`
the generated cgi program can not work.
Does anybody have idea about this case? Is libwww able to be used to create
cgi program?
Thanks a lot
Susan Lee
Received on Sunday, 25 February 2001 05:02:18 UTC