+#include "gmoduleconf.h"
+#include "gstdio.h"
+
+/**
+ * SECTION:modules
+ * @title: Dynamic Loading of Modules
+ * @short_description: portable method for dynamically loading 'plug-ins'
+ *
+ * These functions provide a portable way to dynamically load object files
+ * (commonly known as 'plug-ins'). The current implementation supports all
+ * systems that provide an implementation of dlopen() (e.g. Linux/Sun), as
+ * well as Windows platforms via DLLs.
+ *
+ * A program which wants to use these functions must be linked to the
+ * libraries output by the command
+ * <command>pkg-config --libs gmodule-2.0</command>.
+ *
+ * To use them you must first determine whether dynamic loading
+ * is supported on the platform by calling g_module_supported().
+ * If it is, you can open a module with g_module_open(),
+ * find the module's symbols (e.g. function names) with g_module_symbol(),
+ * and later close the module with g_module_close().
+ * g_module_name() will return the file name of a currently opened module.
+ *
+ * If any of the above functions fail, the error status can be found with
+ * g_module_error().
+ *
+ * The #GModule implementation features reference counting for opened modules,
+ * and supports hook functions within a module which are called when the
+ * module is loaded and unloaded (see #GModuleCheckInit and #GModuleUnload).
+ *
+ * If your module introduces static data to common subsystems in the running
+ * program, e.g. through calling
+ * <literal>g_quark_from_static_string ("my-module-stuff")</literal>,
+ * it must ensure that it is never unloaded, by calling g_module_make_resident().
+ *
+ * Example: Calling a function defined in a GModule
+ * |[<!-- language="C" -->
+ * /* the function signature for 'say_hello' */
+ * typedef void (* SayHelloFunc) (const char *message);
+ *
+ * gboolean
+ * just_say_hello (const char *filename, GError **error)
+ * {
+ * SayHelloFunc say_hello;
+ * GModule *module;
+ *
+ * module = g_module_open (filename, G_MODULE_BIND_LAZY);
+ * if (!module)
+ * {
+ * g_set_error (error, FOO_ERROR, FOO_ERROR_BLAH,
+ * "%s", g_module_error ());
+ * return FALSE;
+ * }
+ *
+ * if (!g_module_symbol (module, "say_hello", (gpointer *)&say_hello))
+ * {
+ * g_set_error (error, SAY_ERROR, SAY_ERROR_OPEN,
+ * "%s: %s", filename, g_module_error ());
+ * if (!g_module_close (module))
+ * g_warning ("%s: %s", filename, g_module_error ());
+ * return FALSE;
+ * }
+ *
+ * if (say_hello == NULL)
+ * {
+ * g_set_error (error, SAY_ERROR, SAY_ERROR_OPEN,
+ * "symbol say_hello is NULL");
+ * if (!g_module_close (module))
+ * g_warning ("%s: %s", filename, g_module_error ());
+ * return FALSE;
+ * }
+ *
+ * /* call our function in the module */
+ * say_hello ("Hello world!");
+ *
+ * if (!g_module_close (module))
+ * g_warning ("%s: %s", filename, g_module_error ());
+ * return TRUE;
+ * }
+ * ]|
+ */
+
+/**
+ * GModule:
+ *
+ * The #GModule struct is an opaque data structure to represent a
+ * <link linkend="glib-Dynamic-Loading-of-Modules">Dynamically-Loaded
+ * Module</link>. It should only be accessed via the following functions.
+ */
+
+/**
+ * GModuleCheckInit:
+ * @module: the #GModule corresponding to the module which has just been loaded
+ *
+ * Specifies the type of the module initialization function.
+ * If a module contains a function named g_module_check_init() it is called
+ * automatically when the module is loaded. It is passed the #GModule structure
+ * and should return %NULL on success or a string describing the initialization
+ * error.
+ *
+ * Returns: %NULL on success, or a string describing the initialization error
+ */
+
+/**
+ * GModuleUnload:
+ * @module: the #GModule about to be unloaded
+ *
+ * Specifies the type of the module function called when it is unloaded.
+ * If a module contains a function named g_module_unload() it is called
+ * automatically when the module is unloaded.
+ * It is passed the #GModule structure.
+ */
+
+/**
+ * G_MODULE_SUFFIX:
+ *
+ * Expands to the proper shared library suffix for the current platform
+ * without the leading dot. For most Unices and Linux this is "so", and
+ * for Windows this is "dll".
+ */
+
+/**
+ * G_MODULE_EXPORT:
+ *
+ * Used to declare functions exported by modules. This is a no-op on Linux
+ * and Unices, but when compiling for Windows, it marks a symbol to be
+ * exported from the library or executable being built.
+ */
+
+/**
+ * G_MODULE_IMPORT:
+ *
+ * Used to declare functions imported from modules.
+ */
+