|
createrepo_c library 1.2.3
C library for metadata manipulation
|
Functions | |
| gboolean | cr_set_cleanup_handler (const char *lock_dir, const char *tmp_out_repo, GError **err) |
| gboolean | cr_block_terminating_signals (GError **err) |
| gboolean | cr_unblock_terminating_signals (GError **err) |
| gboolean | cr_lock_repo (const gchar *repo_dir, gboolean ignore_lock, gchar **lock_dir, gchar **tmp_repodata_dir, GError **err) |
| gboolean | cr_unset_cleanup_handler (GError **err) |
| void | cr_setup_logging (gboolean quiet, gboolean verbose) |
Module with createrepo API
| gboolean cr_block_terminating_signals | ( | GError ** | err | ) |
Block process terminating signals. (Useful for creating pseudo-atomic sections in code)
| gboolean cr_lock_repo | ( | const gchar * | repo_dir, |
| gboolean | ignore_lock, | ||
| gchar ** | lock_dir, | ||
| gchar ** | tmp_repodata_dir, | ||
| GError ** | err ) |
This function does:
| repo_dir | Path to repo (a dir that contains repodata/ subdir) |
| ignore_lock | Ignore existing .repodata/ dir - remove it and create a new one. |
| lock_dir | Location to store path to a directory used as a lock. Always repodir+"/.repodata/". Even if FALSE is returned, the content of this variable IS DEFINED. |
| tmp_repodata_dir | Location to store a path to a directory used as a temporary directory for repodata generation. If ignore_lock is FALSE than lock_dir is same as tmp_repodata_dir. If FALSE is returned, the content of this variable is undefined. |
| err | GError ** |
| gboolean cr_set_cleanup_handler | ( | const char * | lock_dir, |
| const char * | tmp_out_repo, | ||
| GError ** | err ) |
This function does: Sets a signal handler for signals that lead to process temination. (List obtained from the "man 7 signal") Signals that are ignored (SIGCHILD) or lead just to stop (SIGSTOP, ...) don't get this handler - these signals do not terminate the process! This handler assures that the cleanup function that is hooked on exit gets called.
| lock_dir | Dir that serves as lock (".repodata/") |
| tmp_out_repo | Dir that is really used for repodata generation (usually exactly the same as lock dir if not –ignore-lock is specified). Could be NULL. |
| void cr_setup_logging | ( | gboolean | quiet, |
| gboolean | verbose ) |
Setup logging for the application.
| gboolean cr_unblock_terminating_signals | ( | GError ** | err | ) |
Unblock process terminating signals.
| gboolean cr_unset_cleanup_handler | ( | GError ** | err | ) |
Unset cleanup handler.
| err | GError ** |