I have no experience with Apache, and I can run FCGI modules on IIS - Windows 10 successfully.
Logically thinking, IIS runs FCGI program so I do not assign separate port -- I think the same applies to Apache. Separate port is necessary to run it as HTTP server, which responses directly, not via IIS or Apache.
First, test with following main program.
begin
Application.Title:='fcgihellow';
{ Uncomment the port setting here if you want to run the
FastCGI application stand-alone (e.g. for NGINX) }
// Application.Port:=2015; // For example
LegacyRouting:= True;
Application.Initialize;
Application.Run;
end.
In IIS, I have to set Handler Mappings --- I have to add mapping for the application program. Don't know how to do this in Apache.
Important thing is that allowPathInfo should be set TRUE. Again, no idea whether this is applicable to Apache.
But as I posted in other posts, Free Pascal fCGI model is not perfect --- I believe it has some problem in memory management. (the author acknowledges this).
Anyway please let me know your result. I'd like to have as many developers of Lazarus webserver as possible.^^