<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC '-//OASIS//DTD DocBook XML V4.5//EN'
                      'http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd' [
<!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
<!ENTITY version SYSTEM "version.xml">
]>
<refentry id="glib-Version-Information">
<refmeta>
<refentrytitle role="top_of_page" id="glib-Version-Information.top_of_page">Version Information</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GLIB Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>Version Information</refname>
<refpurpose>variables and functions to check the GLib version</refpurpose>
</refnamediv>

<refsect1 id="glib-Version-Information.functions" role="functions_proto">
<title role="functions_proto.title">Functions</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="functions_proto_type" colwidth="150px"/>
<colspec colname="functions_proto_name"/>
<tbody>
<row><entry role="function_type">const <link linkend="gchar"><returnvalue>gchar</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="glib-check-version">glib_check_version</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-CHECK-VERSION:CAPS">GLIB_CHECK_VERSION</link><phrase role="c_punctuation">()</phrase></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<refsect1 id="glib-Version-Information.other" role="other_proto">
<title role="other_proto.title">Types and Values</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="other_proto_type" colwidth="150px"/>
<colspec colname="other_proto_name"/>
<tbody>
<row><entry role="variable_type">extern const guint </entry><entry role="function_name"><link linkend="glib-major-version">glib_major_version</link></entry></row>
<row><entry role="variable_type">extern const guint </entry><entry role="function_name"><link linkend="glib-minor-version">glib_minor_version</link></entry></row>
<row><entry role="variable_type">extern const guint </entry><entry role="function_name"><link linkend="glib-micro-version">glib_micro_version</link></entry></row>
<row><entry role="variable_type">extern const guint </entry><entry role="function_name"><link linkend="glib-binary-age">glib_binary_age</link></entry></row>
<row><entry role="variable_type">extern const guint </entry><entry role="function_name"><link linkend="glib-interface-age">glib_interface_age</link></entry></row>

<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-MAJOR-VERSION:CAPS">GLIB_MAJOR_VERSION</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-MINOR-VERSION:CAPS">GLIB_MINOR_VERSION</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-MICRO-VERSION:CAPS">GLIB_MICRO_VERSION</link></entry></row>

<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-26:CAPS">GLIB_VERSION_2_26</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-28:CAPS">GLIB_VERSION_2_28</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-30:CAPS">GLIB_VERSION_2_30</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-32:CAPS">GLIB_VERSION_2_32</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-34:CAPS">GLIB_VERSION_2_34</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-36:CAPS">GLIB_VERSION_2_36</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-38:CAPS">GLIB_VERSION_2_38</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-40:CAPS">GLIB_VERSION_2_40</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-42:CAPS">GLIB_VERSION_2_42</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-44:CAPS">GLIB_VERSION_2_44</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-46:CAPS">GLIB_VERSION_2_46</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-48:CAPS">GLIB_VERSION_2_48</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-50:CAPS">GLIB_VERSION_2_50</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-52:CAPS">GLIB_VERSION_2_52</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-54:CAPS">GLIB_VERSION_2_54</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-56:CAPS">GLIB_VERSION_2_56</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-58:CAPS">GLIB_VERSION_2_58</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-60:CAPS">GLIB_VERSION_2_60</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-62:CAPS">GLIB_VERSION_2_62</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-64:CAPS">GLIB_VERSION_2_64</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-2-66:CAPS">GLIB_VERSION_2_66</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-MIN-REQUIRED:CAPS">GLIB_VERSION_MIN_REQUIRED</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-VERSION-MAX-ALLOWED:CAPS">GLIB_VERSION_MAX_ALLOWED</link></entry></row>
<row><entry role="define_keyword">#define</entry><entry role="function_name"><link linkend="GLIB-DISABLE-DEPRECATION-WARNINGS:CAPS">GLIB_DISABLE_DEPRECATION_WARNINGS</link></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>

<refsect1 id="glib-Version-Information.includes"><title>Includes</title><synopsis>#include &lt;glib.h&gt;
</synopsis></refsect1>

<refsect1 id="glib-Version-Information.description" role="desc">
<title role="desc.title">Description</title>
<para>GLib provides version information, primarily useful in configure
checks for builds that have a configure script. Applications will
not typically use the features described here.</para>
<para>The GLib headers annotate deprecated APIs in a way that produces
compiler warnings if these deprecated APIs are used. The warnings
can be turned off by defining the macro <link linkend="GLIB-DISABLE-DEPRECATION-WARNINGS:CAPS"><literal>GLIB_DISABLE_DEPRECATION_WARNINGS</literal></link>
before including the glib.h header.</para>
<para>GLib also provides support for building applications against
defined subsets of deprecated or new GLib APIs. Define the macro
<link linkend="GLIB-VERSION-MIN-REQUIRED:CAPS"><literal>GLIB_VERSION_MIN_REQUIRED</literal></link> to specify up to what version of GLib
you want to receive warnings about deprecated APIs. Define the
macro <link linkend="GLIB-VERSION-MAX-ALLOWED:CAPS"><literal>GLIB_VERSION_MAX_ALLOWED</literal></link> to specify the newest version of
GLib whose API you want to use.</para>

</refsect1>
<refsect1 id="glib-Version-Information.functions_details" role="details">
<title role="details.title">Functions</title>
<refsect2 id="glib-check-version" role="function" condition="since:2.6">
<title>glib_check_version&#160;()</title>
<indexterm zone="glib-check-version" role="2.6"><primary sortas="lib_check_version">glib_check_version</primary></indexterm>
<programlisting language="C">const <link linkend="gchar"><returnvalue>gchar</returnvalue></link>&#160;*
glib_check_version (<parameter><link linkend="guint"><type>guint</type></link> required_major</parameter>,
                    <parameter><link linkend="guint"><type>guint</type></link> required_minor</parameter>,
                    <parameter><link linkend="guint"><type>guint</type></link> required_micro</parameter>);</programlisting>
<para>Checks that the GLib library in use is compatible with the
given version. Generally you would pass in the constants
<link linkend="GLIB-MAJOR-VERSION:CAPS"><type>GLIB_MAJOR_VERSION</type></link>, <link linkend="GLIB-MINOR-VERSION:CAPS"><type>GLIB_MINOR_VERSION</type></link>, <link linkend="GLIB-MICRO-VERSION:CAPS"><type>GLIB_MICRO_VERSION</type></link>
as the three arguments to this function; that produces
a check that the library in use is compatible with
the version of GLib the application or module was compiled
against.</para>
<para>Compatibility is defined by two things: first the version
of the running library is newer than the version
<parameter>required_major.required_minor</parameter>
.<parameter>required_micro</parameter>
. Second
the running library must be binary compatible with the
version <parameter>required_major.required_minor</parameter>
.<parameter>required_micro</parameter>

(same major version.)</para>
<refsect3 id="glib-check-version.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>required_major</para></entry>
<entry role="parameter_description"><para>the required major version</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>required_minor</para></entry>
<entry role="parameter_description"><para>the required minor version</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>required_micro</para></entry>
<entry role="parameter_description"><para>the required micro version</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="glib-check-version.returns" role="returns">
<title>Returns</title>
<para> <link linkend="NULL:CAPS"><literal>NULL</literal></link> if the GLib library is compatible with the
given version, or a string describing the version mismatch.
The returned string is owned by GLib and must not be modified
or freed.</para>
</refsect3><para role="since">Since: <link linkend="api-index-2.6">2.6</link></para></refsect2>
<refsect2 id="GLIB-CHECK-VERSION:CAPS" role="macro">
<title>GLIB_CHECK_VERSION()</title>
<indexterm zone="GLIB-CHECK-VERSION:CAPS"><primary sortas="LIB_CHECK_VERSION">GLIB_CHECK_VERSION</primary></indexterm>
<programlisting language="C">#define             GLIB_CHECK_VERSION(major,minor,micro)</programlisting>
<para>Checks the version of the GLib library that is being compiled
against. See <link linkend="glib-check-version"><function>glib_check_version()</function></link> for a runtime check.</para>
<refsect3 id="GLIB-CHECK-VERSION.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>major</para></entry>
<entry role="parameter_description"><para>the major version to check for</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>minor</para></entry>
<entry role="parameter_description"><para>the minor version to check for</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>micro</para></entry>
<entry role="parameter_description"><para>the micro version to check for</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="GLIB-CHECK-VERSION.returns" role="returns">
<title>Returns</title>
<para> <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if the version of the GLib header files
is the same as or newer than the passed-in version.</para>
</refsect3></refsect2>

</refsect1>
<refsect1 id="glib-Version-Information.other_details" role="details">
<title role="details.title">Types and Values</title>
<refsect2 id="glib-major-version" role="variable">
<title>glib_major_version</title>
<indexterm zone="glib-major-version"><primary sortas="lib_major_version">glib_major_version</primary></indexterm>
<programlisting language="C">extern const guint glib_major_version;
</programlisting>
<para>The major version of the GLib library.</para>
<para>An integer variable exported from the library linked
against at application run time.</para>
</refsect2>
<refsect2 id="glib-minor-version" role="variable">
<title>glib_minor_version</title>
<indexterm zone="glib-minor-version"><primary sortas="lib_minor_version">glib_minor_version</primary></indexterm>
<programlisting language="C">extern const guint glib_minor_version;
</programlisting>
<para>The minor version number of the GLib library.</para>
<para>An integer variable exported from the library linked
against at application run time.</para>
</refsect2>
<refsect2 id="glib-micro-version" role="variable">
<title>glib_micro_version</title>
<indexterm zone="glib-micro-version"><primary sortas="lib_micro_version">glib_micro_version</primary></indexterm>
<programlisting language="C">extern const guint glib_micro_version;
</programlisting>
<para>The micro version number of the GLib library.</para>
<para>An integer variable exported from the library linked
against at application run time.</para>
</refsect2>
<refsect2 id="glib-binary-age" role="variable">
<title>glib_binary_age</title>
<indexterm zone="glib-binary-age"><primary sortas="lib_binary_age">glib_binary_age</primary></indexterm>
<programlisting language="C">extern const guint glib_binary_age;
</programlisting>
<para>The binary age of the GLib library.
Defines how far back backwards compatibility reaches.</para>
<para>An integer variable exported from the library linked
against at application run time.</para>
</refsect2>
<refsect2 id="glib-interface-age" role="variable">
<title>glib_interface_age</title>
<indexterm zone="glib-interface-age"><primary sortas="lib_interface_age">glib_interface_age</primary></indexterm>
<programlisting language="C">extern const guint glib_interface_age;
</programlisting>
<para>The interface age of the GLib library.
Defines how far back the API has last been extended.</para>
<para>An integer variable exported from the library linked
against at application run time.</para>
</refsect2>
<refsect2 id="GLIB-MAJOR-VERSION:CAPS" role="macro">
<title>GLIB_MAJOR_VERSION</title>
<indexterm zone="GLIB-MAJOR-VERSION:CAPS"><primary sortas="LIB_MAJOR_VERSION">GLIB_MAJOR_VERSION</primary></indexterm>
<programlisting language="C">#define GLIB_MAJOR_VERSION 2
</programlisting>
<para>The major version number of the GLib library.</para>
<para>Like <link linkend="glib-major-version"><type>glib_major_version</type></link>, but from the headers used at
application compile time, rather than from the library
linked against at application run time.</para>
</refsect2>
<refsect2 id="GLIB-MINOR-VERSION:CAPS" role="macro">
<title>GLIB_MINOR_VERSION</title>
<indexterm zone="GLIB-MINOR-VERSION:CAPS"><primary sortas="LIB_MINOR_VERSION">GLIB_MINOR_VERSION</primary></indexterm>
<programlisting language="C">#define GLIB_MINOR_VERSION 66
</programlisting>
<para>The minor version number of the GLib library.</para>
<para>Like <link linkend="gtk-minor-version"><type>gtk_minor_version</type></link>, but from the headers used at
application compile time, rather than from the library
linked against at application run time.</para>
</refsect2>
<refsect2 id="GLIB-MICRO-VERSION:CAPS" role="macro">
<title>GLIB_MICRO_VERSION</title>
<indexterm zone="GLIB-MICRO-VERSION:CAPS"><primary sortas="LIB_MICRO_VERSION">GLIB_MICRO_VERSION</primary></indexterm>
<programlisting language="C">#define GLIB_MICRO_VERSION 2
</programlisting>
<para>The micro version number of the GLib library.</para>
<para>Like <link linkend="gtk-micro-version"><type>gtk_micro_version</type></link>, but from the headers used at
application compile time, rather than from the library
linked against at application run time.</para>
</refsect2>
<refsect2 id="GLIB-VERSION-2-26:CAPS" role="macro" condition="since:2.32">
<title>GLIB_VERSION_2_26</title>
<indexterm zone="GLIB-VERSION-2-26:CAPS" role="2.32"><primary sortas="LIB_VERSION_2_26">GLIB_VERSION_2_26</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_26       (G_ENCODE_VERSION (2, 26))
</programlisting>
<para>A macro that evaluates to the 2.26 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.32">2.32</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-28:CAPS" role="macro" condition="since:2.32">
<title>GLIB_VERSION_2_28</title>
<indexterm zone="GLIB-VERSION-2-28:CAPS" role="2.32"><primary sortas="LIB_VERSION_2_28">GLIB_VERSION_2_28</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_28       (G_ENCODE_VERSION (2, 28))
</programlisting>
<para>A macro that evaluates to the 2.28 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.32">2.32</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-30:CAPS" role="macro" condition="since:2.32">
<title>GLIB_VERSION_2_30</title>
<indexterm zone="GLIB-VERSION-2-30:CAPS" role="2.32"><primary sortas="LIB_VERSION_2_30">GLIB_VERSION_2_30</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_30       (G_ENCODE_VERSION (2, 30))
</programlisting>
<para>A macro that evaluates to the 2.30 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.32">2.32</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-32:CAPS" role="macro" condition="since:2.32">
<title>GLIB_VERSION_2_32</title>
<indexterm zone="GLIB-VERSION-2-32:CAPS" role="2.32"><primary sortas="LIB_VERSION_2_32">GLIB_VERSION_2_32</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_32       (G_ENCODE_VERSION (2, 32))
</programlisting>
<para>A macro that evaluates to the 2.32 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.32">2.32</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-34:CAPS" role="macro" condition="since:2.34">
<title>GLIB_VERSION_2_34</title>
<indexterm zone="GLIB-VERSION-2-34:CAPS" role="2.34"><primary sortas="LIB_VERSION_2_34">GLIB_VERSION_2_34</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_34       (G_ENCODE_VERSION (2, 34))
</programlisting>
<para>A macro that evaluates to the 2.34 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.34">2.34</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-36:CAPS" role="macro" condition="since:2.36">
<title>GLIB_VERSION_2_36</title>
<indexterm zone="GLIB-VERSION-2-36:CAPS" role="2.36"><primary sortas="LIB_VERSION_2_36">GLIB_VERSION_2_36</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_36       (G_ENCODE_VERSION (2, 36))
</programlisting>
<para>A macro that evaluates to the 2.36 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.36">2.36</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-38:CAPS" role="macro" condition="since:2.38">
<title>GLIB_VERSION_2_38</title>
<indexterm zone="GLIB-VERSION-2-38:CAPS" role="2.38"><primary sortas="LIB_VERSION_2_38">GLIB_VERSION_2_38</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_38       (G_ENCODE_VERSION (2, 38))
</programlisting>
<para>A macro that evaluates to the 2.38 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.38">2.38</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-40:CAPS" role="macro" condition="since:2.40">
<title>GLIB_VERSION_2_40</title>
<indexterm zone="GLIB-VERSION-2-40:CAPS" role="2.40"><primary sortas="LIB_VERSION_2_40">GLIB_VERSION_2_40</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_40       (G_ENCODE_VERSION (2, 40))
</programlisting>
<para>A macro that evaluates to the 2.40 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.40">2.40</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-42:CAPS" role="macro" condition="since:2.42">
<title>GLIB_VERSION_2_42</title>
<indexterm zone="GLIB-VERSION-2-42:CAPS" role="2.42"><primary sortas="LIB_VERSION_2_42">GLIB_VERSION_2_42</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_42       (G_ENCODE_VERSION (2, 42))
</programlisting>
<para>A macro that evaluates to the 2.42 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.42">2.42</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-44:CAPS" role="macro" condition="since:2.44">
<title>GLIB_VERSION_2_44</title>
<indexterm zone="GLIB-VERSION-2-44:CAPS" role="2.44"><primary sortas="LIB_VERSION_2_44">GLIB_VERSION_2_44</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_44       (G_ENCODE_VERSION (2, 44))
</programlisting>
<para>A macro that evaluates to the 2.44 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.44">2.44</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-46:CAPS" role="macro" condition="since:2.46">
<title>GLIB_VERSION_2_46</title>
<indexterm zone="GLIB-VERSION-2-46:CAPS" role="2.46"><primary sortas="LIB_VERSION_2_46">GLIB_VERSION_2_46</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_46       (G_ENCODE_VERSION (2, 46))
</programlisting>
<para>A macro that evaluates to the 2.46 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.46">2.46</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-48:CAPS" role="macro" condition="since:2.48">
<title>GLIB_VERSION_2_48</title>
<indexterm zone="GLIB-VERSION-2-48:CAPS" role="2.48"><primary sortas="LIB_VERSION_2_48">GLIB_VERSION_2_48</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_48       (G_ENCODE_VERSION (2, 48))
</programlisting>
<para>A macro that evaluates to the 2.48 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.48">2.48</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-50:CAPS" role="macro" condition="since:2.50">
<title>GLIB_VERSION_2_50</title>
<indexterm zone="GLIB-VERSION-2-50:CAPS" role="2.50"><primary sortas="LIB_VERSION_2_50">GLIB_VERSION_2_50</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_50       (G_ENCODE_VERSION (2, 50))
</programlisting>
<para>A macro that evaluates to the 2.50 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.50">2.50</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-52:CAPS" role="macro" condition="since:2.52">
<title>GLIB_VERSION_2_52</title>
<indexterm zone="GLIB-VERSION-2-52:CAPS" role="2.52"><primary sortas="LIB_VERSION_2_52">GLIB_VERSION_2_52</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_52       (G_ENCODE_VERSION (2, 52))
</programlisting>
<para>A macro that evaluates to the 2.52 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.52">2.52</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-54:CAPS" role="macro" condition="since:2.54">
<title>GLIB_VERSION_2_54</title>
<indexterm zone="GLIB-VERSION-2-54:CAPS" role="2.54"><primary sortas="LIB_VERSION_2_54">GLIB_VERSION_2_54</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_54       (G_ENCODE_VERSION (2, 54))
</programlisting>
<para>A macro that evaluates to the 2.54 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.54">2.54</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-56:CAPS" role="macro" condition="since:2.56">
<title>GLIB_VERSION_2_56</title>
<indexterm zone="GLIB-VERSION-2-56:CAPS" role="2.56"><primary sortas="LIB_VERSION_2_56">GLIB_VERSION_2_56</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_56       (G_ENCODE_VERSION (2, 56))
</programlisting>
<para>A macro that evaluates to the 2.56 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.56">2.56</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-58:CAPS" role="macro" condition="since:2.58">
<title>GLIB_VERSION_2_58</title>
<indexterm zone="GLIB-VERSION-2-58:CAPS" role="2.58"><primary sortas="LIB_VERSION_2_58">GLIB_VERSION_2_58</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_58       (G_ENCODE_VERSION (2, 58))
</programlisting>
<para>A macro that evaluates to the 2.58 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.58">2.58</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-60:CAPS" role="macro" condition="since:2.60">
<title>GLIB_VERSION_2_60</title>
<indexterm zone="GLIB-VERSION-2-60:CAPS" role="2.60"><primary sortas="LIB_VERSION_2_60">GLIB_VERSION_2_60</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_60       (G_ENCODE_VERSION (2, 60))
</programlisting>
<para>A macro that evaluates to the 2.60 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.60">2.60</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-62:CAPS" role="macro" condition="since:2.62">
<title>GLIB_VERSION_2_62</title>
<indexterm zone="GLIB-VERSION-2-62:CAPS" role="2.62"><primary sortas="LIB_VERSION_2_62">GLIB_VERSION_2_62</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_62       (G_ENCODE_VERSION (2, 62))
</programlisting>
<para>A macro that evaluates to the 2.62 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.62">2.62</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-64:CAPS" role="macro" condition="since:2.64">
<title>GLIB_VERSION_2_64</title>
<indexterm zone="GLIB-VERSION-2-64:CAPS" role="2.64"><primary sortas="LIB_VERSION_2_64">GLIB_VERSION_2_64</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_64       (G_ENCODE_VERSION (2, 64))
</programlisting>
<para>A macro that evaluates to the 2.64 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.64">2.64</link></para></refsect2>
<refsect2 id="GLIB-VERSION-2-66:CAPS" role="macro" condition="since:2.66">
<title>GLIB_VERSION_2_66</title>
<indexterm zone="GLIB-VERSION-2-66:CAPS" role="2.66"><primary sortas="LIB_VERSION_2_66">GLIB_VERSION_2_66</primary></indexterm>
<programlisting language="C">#define GLIB_VERSION_2_66       (G_ENCODE_VERSION (2, 66))
</programlisting>
<para>A macro that evaluates to the 2.66 version of GLib, in a format
that can be used by the C pre-processor.</para>
<para role="since">Since: <link linkend="api-index-2.66">2.66</link></para></refsect2>
<refsect2 id="GLIB-VERSION-MIN-REQUIRED:CAPS" role="macro" condition="since:2.32">
<title>GLIB_VERSION_MIN_REQUIRED</title>
<indexterm zone="GLIB-VERSION-MIN-REQUIRED:CAPS" role="2.32"><primary sortas="LIB_VERSION_MIN_REQUIRED">GLIB_VERSION_MIN_REQUIRED</primary></indexterm>
<programlisting language="C"># define GLIB_VERSION_MIN_REQUIRED      (GLIB_VERSION_CUR_STABLE)
</programlisting>
<para>A macro that should be defined by the user prior to including
the glib.h header.
The definition should be one of the predefined GLib version
macros: <link linkend="GLIB-VERSION-2-26:CAPS"><literal>GLIB_VERSION_2_26</literal></link>, <link linkend="GLIB-VERSION-2-28:CAPS"><literal>GLIB_VERSION_2_28</literal></link>,...</para>
<para>This macro defines the earliest version of GLib that the package is
required to be able to compile against.</para>
<para>If the compiler is configured to warn about the use of deprecated
functions, then using functions that were deprecated in version
<link linkend="GLIB-VERSION-MIN-REQUIRED:CAPS"><literal>GLIB_VERSION_MIN_REQUIRED</literal></link> or earlier will cause warnings (but
using functions deprecated in later releases will not).</para>
<para role="since">Since: <link linkend="api-index-2.32">2.32</link></para></refsect2>
<refsect2 id="GLIB-VERSION-MAX-ALLOWED:CAPS" role="macro" condition="since:2.32">
<title>GLIB_VERSION_MAX_ALLOWED</title>
<indexterm zone="GLIB-VERSION-MAX-ALLOWED:CAPS" role="2.32"><primary sortas="LIB_VERSION_MAX_ALLOWED">GLIB_VERSION_MAX_ALLOWED</primary></indexterm>
<programlisting language="C"># define GLIB_VERSION_MAX_ALLOWED      (GLIB_VERSION_CUR_STABLE)
</programlisting>
<para>A macro that should be defined by the user prior to including
the glib.h header.
The definition should be one of the predefined GLib version
macros: <link linkend="GLIB-VERSION-2-26:CAPS"><literal>GLIB_VERSION_2_26</literal></link>, <link linkend="GLIB-VERSION-2-28:CAPS"><literal>GLIB_VERSION_2_28</literal></link>,...</para>
<para>This macro defines the latest version of the GLib API that the
package is allowed to make use of.</para>
<para>If the compiler is configured to warn about the use of deprecated
functions, then using functions added after version
<link linkend="GLIB-VERSION-MAX-ALLOWED:CAPS"><literal>GLIB_VERSION_MAX_ALLOWED</literal></link> will cause warnings.</para>
<para>Unless you are using <link linkend="GLIB-CHECK-VERSION:CAPS"><function>GLIB_CHECK_VERSION()</function></link> or the like to compile
different code depending on the GLib version, then this should be
set to the same value as <link linkend="GLIB-VERSION-MIN-REQUIRED:CAPS"><literal>GLIB_VERSION_MIN_REQUIRED</literal></link>.</para>
<para role="since">Since: <link linkend="api-index-2.32">2.32</link></para></refsect2>
<refsect2 id="GLIB-DISABLE-DEPRECATION-WARNINGS:CAPS" role="macro">
<title>GLIB_DISABLE_DEPRECATION_WARNINGS</title>
<indexterm zone="GLIB-DISABLE-DEPRECATION-WARNINGS:CAPS"><primary sortas="LIB_DISABLE_DEPRECATION_WARNINGS">GLIB_DISABLE_DEPRECATION_WARNINGS</primary></indexterm>
<programlisting language="C">#ifdef GLIB_DISABLE_DEPRECATION_WARNINGS
</programlisting>
<para>A macro that should be defined before including the glib.h header.
If it is defined, no compiler warnings will be produced for uses
of deprecated GLib APIs.</para>
</refsect2>

</refsect1>

</refentry>
