program lmsreport; {$mode objfpc}{$H+} uses {$IFDEF UNIX} cthreads, {$ENDIF} {$IFDEF HASAMIGA} athreads, {$ENDIF} Interfaces, // this includes the LCL widgetset sysutils,Forms, abbrevia, lnetbase, MainTcpServer, tcpthreadhelper, reportDMUnit, ConnectionsDmUnit, cgiDM, xpAccessUnit, extTypes, tcpserver, tcpClient, cgiReport, cgiCommand, fr_utils, baseconnection { you can add units after this }; {$R *.res} begin RequireDerivedFormResource:=True; Application.Scaled:=True; Application.Initialize; if paramstr(1)='console' then begin Application.CreateForm(TCGIServerGUI, CGIServerGUI); Application.Run; end else begin Application.CreateForm(TConnectionsDM,ConnectionsDM); ConnectionsDM.start; while ConnectionsDM.running do sleep(1000); end; end.