开发者

How to use FastMM4 in a Delphi 6 package?

I have been using FastMM4 version 4.92 in my Delphi 6 Pro application smoothly. I now want to use it in a package I created (BPL). I tried putting the units in the Contains section and then moving them to the top of the list but I still get the error from FastMM4 complaining that it is not the first unit to be initialized. To fix this I want to put FastMM4 in the Requires section but I can't find a DCP file for FastMM4 anywhere (runtime library). Does anyone know how to开发者_运维技巧 make this happen?


Probably, the reason you've got this error is that you should include FastMM4 unit not in your package, but in project where you are testing(using) your newcreated package(ofcourse on the first place in 'uses' section).


Did you set UseRuntimePackages in the FastMM4Options.inc file? Otherwise you could try to use ShareMem and the BorlndMM.dll replacement that comes with FastMM. Although ShareMem is designed for DLLs, its use should route all memory management routines to those in the BorlndMM.dll, allowing both the standard packages and yours to use FastMM code.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜