[fpc-devel] Debug compiler

Ondrej Pokorny lazarus at kluug.net
Fri Oct 30 16:01:47 CET 2015


just out of curiosity, I wanted to play with the debugger and try to add 

As the first step, I want to debug the compiler while it is compiling my 
simple project.

What I did:
1.) I opened "compiler\ppx86_64.lpi" from FPC trunk.

2.) I set run parameters to:
-MObjFPC -Scghi -O1 -g -gl -l -vewnhibq 
-FUP:\programs\lazarus\_zk\CT_ClassConstruct\lib\x86-win64\ project1.lpr
(basically the same Lazarus uses to build project1.lpr)

3.) I set working directory to:
(directory with project1.lpr)

4.) I run it and get the following output:

Free Pascal Compiler version 3.1.1 [2015/10/30] for x86_64
Copyright (c) 1993-2015 by Florian Klaempfl and others
(1002) Target OS: Win64 for x64
(3104) Compiling project1.lpr
Fatal: (10022) Can't find unit system used by project1

What could be wrong? Did I forget to supply the fpc.cfg or something 
like that?
Is there any wiki page about debugging the compiler?


More information about the fpc-devel mailing list