From bd09c115217e960cc1dff73d322e3e9581cf2d33 Mon Sep 17 00:00:00 2001 From: ticktock35 Date: Mon, 15 Dec 2008 00:11:12 -0500 Subject: opkg: add progress callbacks to libopkg api libopkg: fix opkg_install_package() git-svn-id: http://opkg.googlecode.com/svn/trunk@80 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358 --- (limited to 'libopkg/opkg.h') diff --git a/libopkg/opkg.h b/libopkg/opkg.h index 0ee1887..b35635a 100644 --- a/libopkg/opkg.h +++ b/libopkg/opkg.h @@ -16,6 +16,7 @@ */ typedef struct _opkg_t opkg_t; +typedef void (*opkg_progress_callback_t) (opkg_t *opkg, int percentage, void *user_data); opkg_t* opkg_new (); void opkg_free (opkg_t *opkg); @@ -23,8 +24,8 @@ void opkg_get_option (opkg_t *opkg, char *option, void **value); void opkg_set_option (opkg_t *opkg, char *option, void *value); int opkg_read_config_files (opkg_t *opkg); -int opkg_install_package (opkg_t *opkg, char *package_name); -int opkg_remove_package (opkg_t *opkg, char *package_name); -int opkg_upgrade_package (opkg_t *opkg, char *package_name); -int opkg_upgrade_all (opkg_t *opkg); -int opkg_update_package_lists (opkg_t *opkg); +int opkg_install_package (opkg_t *opkg, const char *package_name, opkg_progress_callback_t callback, void *user_data); +int opkg_remove_package (opkg_t *opkg, const char *package_name, opkg_progress_callback_t callback, void *user_data); +int opkg_upgrade_package (opkg_t *opkg, const char *package_name, opkg_progress_callback_t callback, void *user_data); +int opkg_upgrade_all (opkg_t *opkg, opkg_progress_callback_t callback, void *user_data); +int opkg_update_package_lists (opkg_t *opkg, opkg_progress_callback_t callback, void *user_data); -- cgit v0.9.1