RTL

From Lazarus wiki
Jump to: navigation, search

Deutsch (de) | English (en) | Español (es) | Français (fr) | Bahasa Indonesia (id) | 日本語 (ja) | Русский (ru)

Free Pascal Runtime Library (RTL)

A Run-Time Library is the set of source code files that are used to create the portion of the application which is generated or included by the compiler and used for the following purposes:

  • Initialization of the run-time-library itself prior to activation of the user's application
  • Initialization and startup of the application
  • providing standard Pascal services to the application (support for the Write and Writeln standard functions, for example)
  • providing any library functions which are not defined inline by the compiler such as mathematical routines
  • providing extended Pascal services to the application (support for the Assign extended function to assign a reference to an external file to a file variable).
  • providing a conversion for local equivalents for a standard or extended function into the local equivalent (for example, changing the Write or writeln statement to write to a window in a windowed environment if the file variable is pointing to a window, to write to the screen in a text environment if the file is pointing to the terminal, or to write to a file if the file variable is pointing to an external file.

RTL units

Due to a combination of different reasons, especially the fact that FPC tries to be compatible to two different compilers (TP/BP and Delphi) with slightly different syntax and different sets of supplied units for two different paradigms (procedural and object oriented programming), and that FPC supports many different platforms requiring support of both platform specific API functions and common routines available across all or at least most supported platforms, there are lots of different units with partly overlapping functionality. Simplified overview can be found in this unit categorization, detailed description of individual units and included routines is available in RTL unit reference manual provided as part of FPC extensive documentation.

Using RTL

Some problems using the crt and the video units with unix terminals are described here: Terminal & Fonts

Read about the API units (Video/Mouse/Keyboard) and the Crt Unix, the bigger picture in KVM API and Crt future

The windows interface units have an own page here

Developing RTL

RTL development articles

Personal tools