Movatterモバイル変換


[0]ホーム

URL:


Jump to content
WikipediaThe Free Encyclopedia
Search

GLib

From Wikipedia, the free encyclopedia
Software library
For other uses, seeGlib (disambiguation).Not to be confused withglibc, the GNU implementation of the C standard library orgnulib, a portability library.
icon
This articleneeds additional citations forverification. Please helpimprove this article byadding citations to reliable sources. Unsourced material may be challenged and removed.
Find sources: "GLib" – news ·newspapers ·books ·scholar ·JSTOR
(July 2019) (Learn how and when to remove this message)
GLib
Original authorShawn Amundson
DeveloperThe GNOME Project et al.
Initial release1998; 27 years ago (1998)
Stable release
2.86.2[1] Edit this on Wikidata / 18 November 2025; 5 days ago (18 November 2025)
Repository
Written inC
Operating systemLinux,Unix-like,macOS,Windows
PlatformCross-platform
TypeLibrary
LicenseLGPLv2.1
Websitewww.gtk.org
Simplified software architecture ofGTK,Pango,GDK,ATK,GIO,Cairo and GLib.

GLib is a bundle of three (formerly five) low-level systemlibraries written inC and developed mainly byGNOME. GLib's code was separated fromGTK, so it can be used by software other than GNOME and has been developed in parallel ever since.

The name "GLib" originates from the project's start as a GTK C utility library.

Features

[edit]

GLib provides advanced data structures, such as memory chunks, doubly and singlylinked lists,hash tables, dynamicstrings and string utilities, such as alexical scanner, string chunks (groups of strings), dynamicarrays, balancedbinary trees,N-ary trees, quarks (a two-way association of a string and a unique integer identifier), keyed data lists, relations, andtuples.Caches provide memory management.

GLib implements functions that providethreads, thread programming and related facilities such as primitive variable access,mutexes, asynchronousqueues, securememory pools,message passing and logging,hook functions (callback registering) andtimers. GLib also includes message passing facilities such asbyte order conversion and I/O channels.

Some other features of GLib include:

Components

[edit]

The GLib package consisted of five libraries, but they were all merged into one library, since then named simplyGLib, and are no longer sustained as standalone libraries. The original libraries were:

  • GObject, an object system including the type system GType
  • GLib
  • GModule
  • GThread
  • GIO

Of these, three continue to reside in distinct subdirectories of the source tree, and so can be thought of as discrete components: GLib, GObject, and GIO. These can be thought of as a software stack: GObject relies on GLib, and GIO provides higher-level functionality that uses both.

Programs for the GLib library

[edit]

Command-line utilities associated with GLib, are usually packaged separately into libglib2.0-bin:

  • gapplication(1) – for starting applications via D-Bus activation
  • gdbus(1) – for working with D-Bus objects and monitoring the bus
  • gio(1) – a file management utility that can work with GIO virtual filesystems
  • gresource(1) – for extracting files from binary format (*.gresource)-files and executables
  • gsettings(1) – for inspecting and editing application configuration
  • gio-query-modules(1) – for updating caches used internally by GLib
  • glib-compile-schemas(1) – for updating caches used internally by GLib

History

[edit]

GLib began as part of theGTK+ project, now named GTK. However, before releasing GTK+ version 2, the project's developers decided to separate code from GTK+ that was not forgraphical user interfaces (GUIs), thus creating GLib as a separate software bundle. GLib was released as a separate library so other developers, those not using the GUI-related parts of GTK+, could use the non-GUI parts of the library without the overhead of depending on the full GUI library.

Since GLib is across-platform library, applications using it to interface with theoperating system are usually portable across different operating systems without major changes.[2]

Releases

[edit]

Glib is undergoing active development. For a current overview seehttps://gitlab.gnome.org/GNOME/glib/-/blob/main/NEWS. The table below documents major patch notes from 1998 to 2022.

Release seriesInitial
release date
Major enhancements
GLib 1.x
1.11998-09-12
1.21999-02-27
1.32001-09-25
GLib 2.x
2.02002-03-08
2.242010-03-26GVariant, GConverted
2.262010-09-27GSettings, GDbus,GObject property bindings (GAtomic for refcounting)
2.302011-09-26Non-unique GApplications, useeventfd() for mainloop wakeup, GHashTable set optimization, GObject data scalability
2.322012-03-24Plans for GLib 2.32
2.342012-09-23What's New for Developers in GLib 2.34
2.362013-03-25
2.382013-09-23applications launched usingD-Bus activation[3] GSubprocess,Unicode 6.3 (released September 2013)
2.402014-03-24GNotification, System notification API[4]
2.422014-09-22
2.432014-10-27
2.442015-03-23
2.452015-04-30
2.462015-09-21
2.472015-10-26
2.482016-03-22
2.502016-09-19
2.522017-03-19
2.532017-04-25
2.542018-01-08
2.552018-02-06
2.562018-03-12
2.572018-05-05
2.582018-08-30
2.592018-12-23
2.602019-03-04
2.612019-04-15
2.622019-09-05
2.632019-10-04
2.642020-02-27
2.652020-06-18
2.662020-09-10
2.672020-10-23
2.682021-03-18
2.692021-07-06
2.702021-09-17
2.712021-12-16
2.722022-03-17

Similar projects

[edit]

Other libraries provide low-level functions and implementations of data structures, including:

References

[edit]
  1. ^"2.86.2 · GNOME / GLib · GitLab". Retrieved19 November 2025.
  2. ^Krause, Andrew (2007).Foundations of GTK+ Development. Expert's Voice in Open Source.Apress. p. 5.ISBN 978-1-59059-793-4. Retrieved3 April 2013.[GLib] provides a cross-platform interface that allows your code to be run on any of its supported operating systemswith little to no rewriting of code!
  3. ^"Setting up an application for D-Bus Launching".
  4. ^"Using Notifications".

External links

[edit]
Platform
GTK
freedesktop.org
(shared)
Development
GUI designer,RAD
IDEs
GNOME
Cinnamon
Xfce
LXDE
Graphical shells
3rd-party
applications
Office
Education
Graphics
Internet
Audio
Video
Utilities
Retrieved from "https://en.wikipedia.org/w/index.php?title=GLib&oldid=1318156061"
Categories:
Hidden categories:

[8]ページ先頭

©2009-2025 Movatter.jp