On Sun, 27 Sep 2020 19:44:36 +0200, Sven Barth via fpc-pascal <fpc-pascal@lists.freepascal.org> wrote:
>> I am not using wsmenus... >> > >Yes, you are, even if it is indirectly. Otherwise the compiler or linker >wouldn't complain about it. > It would be very good if the linker could be told to show a message saying from where the call to the missing identifiers came. Now it just prints a long list of undefined references to WSxxx identifiers, without showing where the call that brought up wsmenus.pp came from. Like: wsmenus.pp(263,1) Error: undefined reference to `WSRegisterPopupMenu' Why is it there? As it is now I have inspected all project units to see if there is any un-needed uses clause that might bring in GUI components. The sources are rather big and many and they were originally created as part o´f a regular Windows program intrfacing the hardware. So there are a number of GUI items embedded, which I have hunted down and ifdef-ed out. There are about 20 units comprising some 30-35000 lines of code. :( I have used a conditional "GUI_MODE" to enable/block all uses of GUI calls like Message boxes and the like. Also to replace Application.ProcessMessages with Sleep() so I can condition away Forms in the uses clause on the GUI_MODE identifier (which is not set). While doing this I found a number of calls to ShowMessage and similar dialogs. Now I have exhausted my list of units and it still happens. I even enabled the option LCLWidgetType:=nogui, but to no avail... The only required packages for my application now are: LCLBase and indylaz. And if I remove LCLBase it still compiles OK but also still fails the link step. In Delphi I believe it was possible to use for example Forms in a command line application so that Application.ProcessMessages could be called. But it seems not so with FPC/Lazarus. -- Bo Berglund Developer in Sweden _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal