]> git.draconx.ca Git - upkg.git/blobdiff - src/upkg.c
uobject: Namespace changes.
[upkg.git] / src / upkg.c
index e1a8a805f8bfbb83a37f112a66b102df04567030..a8c7c7e560ca02bb61bd66d3e36e352d4bcd2b80 100644 (file)
@@ -157,15 +157,15 @@ static int export(struct upkg *pkg, GObject *obj, unsigned idx)
        char name[256];
        FILE *of;
 
-       if (uobject_deserialize(obj, pkg, idx) != 0) {
+       if (u_object_deserialize(obj, pkg, idx) != 0) {
                return -1;
        }
 
-       if (UOBJECT_IS_LOADABLE(obj) && uobject_load(obj) != 0) {
+       if (U_OBJECT_IS_LOADABLE(obj) && u_object_load(obj) != 0) {
                return -1;
        }
 
-       uobject_export_name(obj, name, sizeof name);
+       u_object_export_name(obj, name, sizeof name);
 
        printf("exporting %s to %s\n", upkg_export_name(pkg, idx), name);
        of = fopen(name, "wb");
@@ -174,15 +174,15 @@ static int export(struct upkg *pkg, GObject *obj, unsigned idx)
                return -1;
        }
 
-       uobject_export(obj, of);
+       u_object_export(obj, of);
 
        if (fclose(of) != 0) {
                perror(name);
                return -1;
        }
 
-       if (UOBJECT_IS_LOADABLE(obj)) {
-               uobject_unload(obj);
+       if (U_OBJECT_IS_LOADABLE(obj)) {
+               u_object_unload(obj);
        }
 
        return 0;
@@ -202,11 +202,11 @@ int package_export(struct upkg *pkg)
                        return EXIT_FAILURE;
                }
 
-               type = uobject_module_get_class(package, class);
+               type = u_object_module_get_class(package, class);
                if (!type) continue;
 
                obj = g_object_new(type, NULL);
-               if (UOBJECT_IS_EXPORTABLE(obj)) {
+               if (U_OBJECT_IS_EXPORTABLE(obj)) {
                        if (export(pkg, obj, i) != 0) {
                                rc = EXIT_FAILURE;
                        }
@@ -253,7 +253,7 @@ int main(int argc, char **argv)
                return EXIT_FAILURE;
        }
 
-       if (uobject_module_init() != 0)
+       if (u_object_module_init() != 0)
                return EXIT_FAILURE;
 
        pkg = upkg_fopen(argv[optind]);
@@ -272,6 +272,6 @@ int main(int argc, char **argv)
        }
 
        upkg_close(pkg);
-       uobject_module_exit();
+       u_object_module_exit();
        return rc;
 }