A CGI program - 1 Edit the source file: > cp hw.c hwcgi.c > vi hwcgi.c #define _POSIX_SOURCE #include <stdio.h> main() { printf("Content-type: text/plain\n\n"); printf("hello world\n"); } Compile and link the program: $ c89 -o hwcgi hwcgi.c
> cp hw.c hwcgi.c > vi hwcgi.c #define _POSIX_SOURCE #include <stdio.h> main() { printf("Content-type: text/plain\n\n"); printf("hello world\n"); }
$ c89 -o hwcgi hwcgi.c