Jump to content

Lazarus (software)

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Arch5280 (talk | contribs) at 16:31, 24 April 2013. The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
Lazarus
Developer(s)Volunteers
Stable release
1.0.8 / March 19, 2013; 12 years ago (2013-03-19)
Repository
Operating systemCross-platform
TypeRAD tool for Pascal and Object Pascal
LicenseGNU General Public License, GNU Lesser General Public License, and others
Websitehttp://www.lazarus.freepascal.org/

Lazarus is a free cross-platform Integrated development environment (IDE) which provides a Delphi-like development experience for Pascal and Object Pascal software developers. It is developed for, and supported by, the Free Pascal compiler. Since early 2008, Lazarus has been available for Microsoft Windows, several Linux distributions, FreeBSD, and Mac OS X. Some versions were created even earlier, and Lazarus is a front end for the much older Free Pascal.

Cross-platform development

Lazarus uses Free Pascal as its back-end compiler. Therefore Lazarus can, theoretically, be used to develop applications for all platforms supported by Free Pascal.

Similar to Free Pascal’s run-time library, Lazarus provides a cross-platform application framework called the Lazarus Component Library (LCL), which provides a single, unified interface for programmers, with different platform-specific implementations. Using LCL, one can create applications in a write once, compile anywhere manner, unless system-dependent features are used explicitly.

Cross-compiling

As Free Pascal supports cross-compiling, Lazarus applications can be cross-compiled from Windows to Linux and FreeBSD, and vice versa. Compiling from Mac OS X to Windows, Linux and FreeBSD is possible. Cross-compiling to Mac OS X could be done for older (PowerPC) versions, but not for newer Intel versions, since Apple doesn't release the assembler and linker sources anymore.

Applications for embedded devices (Phones, PDA's, routers, game consoles) are cross-compiled from a *nix or Windows.

Lazarus Component Library

Architecture of the Lazarus Component Library

The standard application framework, Lazarus Component Library (LCL) was modeled after the Visual Component Library (VCL) in Delphi 6, but it is available for operating systems other than Windows. This is done by separating the definition of common widget classes and their widgetset-specific implementation. Support for each widget set is done by providing an interface which interacts directly with the widget set.[1]

Currently (early 2011), the development status of widget toolkit interfaces is roughly as follows.

Widget set Supported Operating Systems Status
Windows API, GDI Windows Mainstream use
Windows CE API, GDI Windows CE Mainstream use
GTK+ 1.2.x Linux (via X11) Deprecated
GTK+ 2.8+ Windows, Linux (X11 and framebuffer) and Mac OS X (via X11) Mainstream use
GTK+ 3.x As Gtk2 Planned as full rewrite
Qt 4.5+ Windows, Linux (X11 and framebuffer), Mac OS X Mainstream use. Works in Windows, Linux, Mac OS X, Maemo, etc
Cocoa Mac OS X In progress
Carbon Mac OS X Mainstream use
fpGUI Windows, Windows CE, Linux (via X11) Initial stage
Lazarus Custom Drawn Controls Android, Windows, Linux (via X11), Mac OS X Initial stage

The plan is to write a new GTK3 backend from scratch, because the GTK2 backend was no clean implementation and inherits GTK1 traits.

Database development

Developers can install packages that allow Lazarus to support several databases. Programs can interact with databases through code or by components dropped on a form. The data-aware components represent fields and are connected by the correct setting of properties to a TDataSource, which represents a table, and to the database components, which may be TPSQLDatabase, TSQLiteDataSet, or equivalent.

The following databases are supported out of the box using the built in database components:

Other components, such as Zeoslib, can also be used

  • MSSQL works with Zeoslib. FPC versions 2.6.2 and higher have built-in support for MSSQL access (using the FreeTDS client library).

Differences from Delphi

While resembling Delphi in many ways, there are a few limitations regarding the performance and feature set.

  • Under Windows executable, by default, file size is somewhat larger than the Delphi (6/7) equivalent because debug information is included within Lazarus executables, instead of as separate files like Delphi. However, the 0.9.30 release introduces an external debug symbols feature. Lazarus program file size can be significantly reduced by using an external symbols file (it can be set in Compiler options), and also by using Strip
  • Components for Delphi can be installed in Lazarus, but they must be converted, which can be complex. (2.4.x based 0.9.30 should make this easier)
  • Missing important media libraries and widgets:
    • Microsoft Office connectivity (popping up Excel with a simple table filled out works fine in 2.5.x trunk)
    • Datasnap (not a publicly documented system, Borland proprietary enterprise functionality)
  • Networking is mostly available
  • No support to directly call .NET libraries. On the other hand, it is possible to call Object Pascal code from .NET software. [2]
  • COM support was missing from the 2.0.x series, but it was initially working in 2.2.0, and has matured since.
  • Missing dynamically loadable packages support.
  • Not 100 percent compatible with VCL. As mentioned previously this is by design, although the current LCL widget set should suffice for most applications. But this makes the deep repository of available VCL widgets inaccessible without conversion. The conversion effort mostly involves some editing, although there are a few fundamental differences. When porting, missing units in the libraries and COM support are a considerably bigger problem than incompatibilities between LCL and VCL.

Distribution and licensing

Like Free Pascal, Lazarus is free software. Different portions are distributed under different free software licenses, including GPL, LGPL, MPL, and a modified version of LGPL.[3]

Specifically, the LCL, which is statically built into the produced executables, is licensed under a modified version of the LGPL, granting extra permissions to allow it to be statically built into the produced software, including proprietary ones.

Note that installing a design-time package is equivalent to linking to the IDE. Thus, distributing the Lazarus IDE with a GPL-incompatible design-time package (e.g. the JEDI packages, which are licensed under the Mozilla Public License) pre-installed would cause a license violation. This does not prohibit proprietary packages from being developed with Lazarus, though.

Lazarus is officially distributed via Sourceforge.

Versions

Legend:
Unsupported
Supported
Latest version
Preview version
Future version
Version number Release date Platform Comments
Unsupported: 0.0.5 January 2001 Windows First release of component library
Unsupported: 0.1 January 2001 Windows Redesign of component library to support platform-sensitive development for Linux and Windows using GTK+ and other widgetsets.
Unsupported: 0.5 January 30th, 2001 Windows, Linux Bug fixes and new features supporting cross-platform development and project skeletons.
Unsupported: 0.8.4 August 19th, 2002 Windows, Linux Improved graphics and font support, support for Delphi 6 syntax. Binary DFMs are now automatically converted to LFMs.
Unsupported: 0.9.0.3 September 4th, 2003 Linux First release on Sourceforge
Unsupported: 0.9.1 February 27th, 2004 Windows, Linux Support for packages, numerous added and enhanced properties.
Unsupported: 0.9.4 January 3rd, 2005 Windows Threading support improved, oldest public version hosted at Sourceforge
Unsupported: 0.9.6 February 25th, 2005 Windows
Unsupported: 0.9.8 July 19th, 2005 Windows
Unsupported: 0.9.10 October 3rd, 2005 Windows, Mac OS X (PPC) Bug fixes, extensibility of IDE improved, document editor for FPDoc files. Includes Free Pascal 2.0.1
Unsupported: 0.9.12 February 7th, 2006 Windows New packages for database support, CGI applications and printing.
Unsupported: 0.9.14 April 2nd, 2006 Windows, Mac OS X (PPC), Linux Bugfixes, more controls in the WinCE and Qt4 interface
Unsupported: 0.9.16 May 28th 2006 Windows, Mac OS X (PPC), Linux Bug fixes, online help for IDE windows and for LCL applications, improvements to QT widgetset interface. Includes Free Pascal 2.0.2
Unsupported: 0.9.18 September 23rd, 2006 Windows, Mac OS X (PPC), Linux Bugfixes, procedure list implemented, new command-line tool "lazbuild"
Unsupported: 0.9.20 November 5th 2006 Windows, Mac OS X (PPC), Linux Bufixes, code folding implemented, QT widgetset improved.
Unsupported: 0.9.22 March 26th, 2007 Windows, Mac OS X (PPC), Linux New components to write Windows services and Linux daemons, support for custom mouse cursors. Includes Free Pascal 2.0.4
Unsupported: 0.9.24 November 15th 2007 Windows, Mac OS X (Intel and PPC), Linux First stable release for Win64, WinCE, and Intel-based Mac OS X. Improvements in Qt, Carbon, and Gtk2 widgetset interfaces. Customizable toolbar. Includes Free Pascal 2.2.0
Unsupported: 0.9.26 October 5th, 2008 Windows, Mac OS X (Intel and PPC), Linux Internal graphic system was rewritten. LCL now uses Unicode strings encoded as UTF-8 on all platforms. FPDoc help in tooltips. First version to run natively using the Carbon widgetset on Mac OS X.
Unsupported: 0.9.26.2 March 13th, 2009 Windows, Mac OS X (Intel and PPC), Linux Bug fixes, improved icon support. Includes Free Pascal 2.2.2
Unsupported: 0.9.28 September 29th, 2009 Windows, Mac OS X (Intel and PPC), Linux Improvements of editor and debugger including support for double-byte fonts such as Eastern, Japanese, Chinese, and Arabic, smaller file sizes of generated applications. Includes Free Pascal 2.2.4
Unsupported: 0.9.28.2 October 25th, 2009 Windows, Mac OS X (Intel and PPC), Linux Mainly bug fixes.
Unsupported: 0.9.30 March 22nd, 2011 Windows, Mac OS X (Intel and PPC), Linux Large number of new features, including docking and multiple source-code windows. Based on Free Pascal 2.4.2.
Unsupported: 0.9.30.2RC1 September 30th 2011 Windows, Mac OS X (Intel and PPC), Linux Includes Free Pascal 2.4.4. Release candidate for Lazarus 0.9.30.2.
Unsupported: 0.9.30.2RC2 October 26th, 2011 Windows, Mac OS X (Intel and PPC), Linux Release candidate for Lazarus 0.9.30.2.
Unsupported: 0.9.30.2 November 5th, 2011 Windows, Mac OS X (Intel and PPC), Linux Bug fixes.
Unsupported: 0.9.30.4RC1 March 3rd, 2012 Windows, Mac OS X (Intel and PPC), Linux Bug fixes, includes Free Pascal 2.6.0. Release candidate for Lazarus 0.9.30.4.
Unsupported: 0.9.30.4RC2 March 7th, 2012 Windows, Mac OS X (Intel and PPC), Linux Release candidate for Lazarus 0.9.30.4.
Unsupported: 0.9.30.4RC3 March 11th, 2012 Windows, Mac OS X (Intel and PPC), Linux Release candidate for Lazarus 0.9.30.4.
Unsupported: 0.9.30.4 March 14th, 2012 Windows, Mac OS X (Intel and PPC), Linux Bug fixes
Supported: 1.0RC1 July 29th, 2012 Windows, Mac OS X (Intel), Linux Release candidate for Lazarus 1.0.
Supported: 1.0RC2 August 21st, 2012 Windows, Mac OS X (Intel and PPC), Linux Release candidate for Lazarus 1.0.
Supported: 1.0 August 28th, 2012 Windows, Mac OS X (Intel and PPC), Linux First final version. This stable release includes Free Pascal 2.6.0. Multiple corrections and improvements of the IDE, including a macro function, expanded code-folding and new debugger functions.
Supported: 1.0.2 October 10th, 2012 Windows, Mac OS X (Intel and PPC), Linux Bug fixes, minor additions to LCL and widgetsets
Supported: 1.0.4 December 2nd, 2012 Windows, Mac OS X (Intel and PPC), Linux Bug fixes, minor additions to IDE, LCL and widgetsets as well as LazReport and TAChart
Supported: 1.0.6 February 3rd, 2013 Windows, Mac OS X (Intel and PPC), Linux Bug fixes, minor additions to IDE, LCL and widgetsets as well as LazReport and TAChart
Latest version: 1.0.8 March 19th, 2013 Windows, Mac OS X (Intel and PPC), Linux Bug fix release. Includes Free Pascal 2.6.2
Preview version: 1.1 N/A N/A in development
Future version: 1.2 N/A N/A planned

Applications produced with Lazarus

  • ASuite is a free open source application launcher for Windows. From 2.0 Alpha 2, it's fully written in Lazarus/FPC.
  • Cartes du Ciel is a free planetarium program for Linux, Mac OS X and Windows. The software maps out and labels most of the constellations, planets, and objects you can see with a telescope. It's fully written in Lazarus/FPC and released under GPL.
  • Cheat Engine is an open source memory scanner/hex editor/debugger. It is useful for cheating in computer games. Since version 6.0 it is compiled with Lazarus/FPC.
  • MyNotex is a free software for Gnu/Linux useful to take and to manage textual notes.
  • Peazip is an open source archiver, made with Lazarus/FPC
  • TorChat is moving away from Python, and is being rewritten in Lazarus + Free Pascal.

Libraries compatible with Lazarus

See also

References

  1. ^ See LCL Internals.
  2. ^ http://wiki.lazarus.freepascal.org/Using_Pascal_Libraries_with_.NET_and_Mono
  3. ^ ""COPYING.txt" file from the online source code repository".