#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include <string.h>
#include "glib.h"
Enumerations | |
| enum | GbrInitError { GBR_INIT_ERROR_NOMEM, GBR_INIT_ERROR_OPEN_MAPS, GBR_INIT_ERROR_READ_MAPS, GBR_INIT_ERROR_INVALID_MAPS, GBR_INIT_ERROR_DISABLED } |
Functions | |
| gboolean | gbr_init (GError **error) |
| gboolean | gbr_init_lib (GError **error) |
| gchar * | gbr_find_exe (const gchar *default_exe) |
| gchar * | gbr_find_exe_dir (const gchar *default_dir) |
| gchar * | gbr_find_prefix (const gchar *default_prefix) |
| gchar * | gbr_find_bin_dir (const gchar *default_bin_dir) |
| gchar * | gbr_find_sbin_dir (const gchar *default_sbin_dir) |
| gchar * | gbr_find_data_dir (const gchar *default_data_dir) |
| gchar * | gbr_find_locale_dir (const gchar *default_locale_dir) |
| gchar * | gbr_find_lib_dir (const gchar *default_lib_dir) |
| gchar * | gbr_find_libexec_dir (const gchar *default_libexec_dir) |
| gchar * | gbr_find_etc_dir (const gchar *default_etc_dir) |
|
|
These error codes can be returned by br_init(), br_init_lib(), gbr_init() or gbr_init_lib().
|
|
|
Locate the application's binary folder. The path is generated by the following pseudo-code evaluation: prefix + "/bin"
|
|
|
Locate the application's data folder. The path is generated by the following pseudo-code evaluation: prefix + "/share"
|
|
|
Locate the application's configuration files folder. The path is generated by the following pseudo-code evaluation: prefix + "/etc"
|
|
|
Find the canonical filename of the current application.
|
|
|
Locate the directory in which the current application is installed. The prefix is generated by the following pseudo-code evaluation: dirname(exename)
|
|
|
Locate the application's library folder. The path is generated by the following pseudo-code evaluation: prefix + "/lib"
|
|
|
Locate the application's libexec folder. The path is generated by the following pseudo-code evaluation: prefix + "/libexec"
|
|
|
Locate the application's localization folder. The path is generated by the following pseudo-code evaluation: prefix + "/share/locale"
|
|
|
Locate the prefix in which the current application is installed. The prefix is generated by the following pseudo-code evaluation: dirname(dirname(exename))
|
|
|
Locate the application's superuser binary folder. The path is generated by the following pseudo-code evaluation: prefix + "/sbin"
|
|
|
Initialize the BinReloc library (for applications). This function must be called before using any other BinReloc functions. It attempts to locate the application's canonical filename.
|
|
|
Initialize the BinReloc library (for libraries). This function must be called before using any other BinReloc functions. It attempts to locate the calling library's canonical filename.
|
1.4.4