[fpc-devel] libc translations

Boian Mitov mitov at mitov.com
Sun Aug 10 11:09:02 CEST 2008

    Hi Daniel,

Thank you!
As I mentioned I am very new, and still don't know the exact rules of the 
purpose of specific units. I am not sure if the timers are available on 
other systems than Linux yet. I am sure there is some form of equivalent. I 
actually don't have any Kylix code. I am porting Windows code, actually 
making it cross platform as we support Delphi 5-2007, and plan to support 
Lazarus for Windows and Linux for now, and hopefully for other platforms in 
the future. Porting huge code from Windows is slow and error prone process, 
so I am doing it in stages. For now I have made everything to recompile 
under Lazarus in Linux, and now I am filling the items I had to cut from the 
code during the conversion. In Windows I use the Media Timers, and the only 
equivalent thing I have found in Linux is the High Resolution timers. I have 
been studding the FPC and Lazarus code, and I discovered the libc, and it 
seemed as the logical place such timers to be implemented. If they belong to 
a different location, this is fine. I can also keep them in my code, but I 
thought other people can benefit from the translation.

As I said I am days fresh on Linux, and have been playing with Lazarus and 
FPC under Windows for only a month or so, and I have a lot to learn ;-) . I 
was able however to get the libraries to work nearly 80% already, and I 
think in few months can have them ready for deployment. I still will have to 
figure out how to package them in Linux, and how to deploy them compiled 
against different visual frameworks, but that is for the future. For now I 
am focused on getting the high resolution timers to work, so I can move to 
the next issue in the list ;-) .

  With best regards,
    Boian Mitov

> This is not the right approach. Libc is a Kylix compatibility unit,
> anything that Kylix doesn't have does not have to be provided by FPC
> (after all this is, and i386 assumptions by Borland is why it is 386
> only).
> If you want to use high resulotion timers, please integrate them with
> FPC's Unix access units.
> Now, if you have Kylix code and absolutely need to use high
> resultion timers in your code, I am not principally against adding them to
> the libc unit. But in principle, libc should not be used for new code.

More information about the fpc-devel mailing list