Premature end of script headers: projest.cgi

This usually means that the cgi script does not print anything, so probably it is generating an error. I would guess it cannot find the lib.
:!: If you use CGI::Carp, you can show the CGI script errors in the browser so you can see what is going on.