[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 447
  • Last Modified:

Stepping into System.pas

Hi there

I am working with Delphi 7 Professional (german version). Somehow I am not able to step into my System.pas, although I have it in my projects searchpath. Can this be, because it differs from the System.dcu in my Lib path ? Do I have to recompile the rtl and if, how would I do that ?

Any suggestions appreciated.

TomBig
0
TomBig
Asked:
TomBig
  • 3
  • 3
  • 2
1 Solution
 
Ivanov_GCommented:

   Project / Options / Compiler / Debugging

   tick "Use Debug DCUs"

   this should do the trick. Anyway you will not succeed to recompile system.dcu so better don't try it
0
 
TomBigAuthor Commented:
Ivanov_G

I have "Use Debug DCUs" turned on, but I just realized, that i dont have a System.dcu in my $(DELPHI)\Lib\Debug directory. What could that mean ? I assume I need a System.dcu containing debug information. How would I get one ?

TomBig
0
 
Ivanov_GCommented:

   well, it works file here :

  procedure TForm1.Button1Click(Sender: TObject);
  var
    P : Pointer;
  begin
    FreeMemory(P); // step into here ...
  end;

  If you don't have it - this could mean that you don't use it...
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
RHenningsgardCommented:
TomBig,

Hmm... I am running D6Pro, and I do have the system.dcu in my \Lib\Debug directory.  I just went to Tools|Environment Options|Library, and added the $(DELPHI)\Lib\Debug path just in front of $(DELPHI)\Lib in the list.  Built the project, and I stepped right in to the system unit on a trunc() call.

I suspect (and seem to remember) that there's an installation option to install/not the debugging DCU's.  I recommend that you find your installation CD and check it for the debug DCU's.

I haven't recompiled the SYSTEM.PAS unit in this version of Delphi, but I have modified and rebuilt SYSTEM.PAS in every other revision of Delphi since 1.0, so I can't imagine why you shouldn't be able to rebuild it in 7.0.  (I worked cross-platform a lot, so I always modified the file I/O stuff to transparently handle $0A or $0A$0D terminators in text files on readln().)

Rob---
0
 
TomBigAuthor Commented:
RHenningsgard

thanks for your hints. the funny thing is, that I have all the debug dcus (as far as i am aware of) but the system.dcu (for example i have no problem stepping into the sysutils, whos source resides at the same place as the one of system). maybe my installation is corrupt anyway. Who knows. I have had some other very strange problems recently that no one seems to know of but me (see http://www.experts-exchange.com/Programming/Programming_Languages/Delphi/Q_20962129.html if you want to earn some points).

by the way. how would i succeed in recompiling the system.pas ?

cheers TomBig
0
 
RHenningsgardCommented:
OK, I just went into my archives, and I see that when I've rebuilt the runtime libraries in the past, I used a makefile from Borland, and a standalone directory tree with my modified version(s) of several of the assembly-language files.  The makefile does accept a "-D" option to build the debug version of the entire library.

I'm deep into a project this morning, so I'll recommend that you check your installation, your installation CD, and also search Borland.com for the needed makefile and such.

On My Delphi 6 installation, a makefile for the RTL is in Program Files\Borland\Delphi6\Source\Rtl\makefile.  If you
can find this in your own installation, you should be well on your way to success.

My D6 make file indicates that one must have Turbo Assembler 4.0 or later and the Borland Resource Compiler 4.0 or later to build the runtime library.

Good luck!
0
 
TomBigAuthor Commented:
RHenningsgard

thanks a lot for your advice. I managed to recompile the rtl and now i am able to step into the system.pas ! hooray.

cheers
TomBig
0
 
RHenningsgardCommented:
TomBig,

You are more than welcome, and thanks for my very first "Accepted Answer!"  (I paid the $100 to join as an unlimited member, and really haven't taken the time to post much advice.  Figured I should start to answer at least one question a day, just to carry my weight on a technical level).

Cheers, and congratulations!

Rob---
0

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

  • 3
  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now