summaryrefslogtreecommitdiff
path: root/src/libostree/ostree-mutable-tree.h
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2016-03-01 17:42:59 -0500
committerColin Walters <walters@verbum.org>2016-03-01 21:45:26 -0500
commit16979cc5ed9b158b1a9b5ba929c8af32baa41d9d (patch)
tree41614ab83ed32cbda21ad497d4f4a6a1a0b37f75 /src/libostree/ostree-mutable-tree.h
parent2badf36cfdd7684eb83bb5d4113a4be6217a63ee (diff)
downloadostree-16979cc5ed9b158b1a9b5ba929c8af32baa41d9d.tar.gz
lib: Introduce versioned symbols
As rpm-ostree evolves, it keeps driving API additions to libostree. This creates a relatively tight coupling. However, if delivering via e.g. RPM, unless one manually remembers to increment the `Requires:` in the spec file, it's possible for the two to become desynchronized. RPM handles versioned symbols and will ensure a dependency if the application starts using a newer version. To implement this, switch to `-fvisibility=hidden`, along with an annotation in the header, and finally add a `.sym` file. This matches what other projects like systemd and libvirt do. Although rather than attempting to retroactively version symbols, glom them all onto the current one.
Diffstat (limited to 'src/libostree/ostree-mutable-tree.h')
-rw-r--r--src/libostree/ostree-mutable-tree.h14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/libostree/ostree-mutable-tree.h b/src/libostree/ostree-mutable-tree.h
index bc8539cd..30425d8d 100644
--- a/src/libostree/ostree-mutable-tree.h
+++ b/src/libostree/ostree-mutable-tree.h
@@ -45,50 +45,62 @@ struct OstreeMutableTreeClass
GObjectClass parent_class;
};
+_OSTREE_PUBLIC
GType ostree_mutable_tree_get_type (void) G_GNUC_CONST;
+_OSTREE_PUBLIC
OstreeMutableTree *ostree_mutable_tree_new (void);
+_OSTREE_PUBLIC
void ostree_mutable_tree_set_metadata_checksum (OstreeMutableTree *self,
const char *checksum);
+_OSTREE_PUBLIC
const char *ostree_mutable_tree_get_metadata_checksum (OstreeMutableTree *self);
+_OSTREE_PUBLIC
void ostree_mutable_tree_set_contents_checksum (OstreeMutableTree *self,
const char *checksum);
+_OSTREE_PUBLIC
const char *ostree_mutable_tree_get_contents_checksum (OstreeMutableTree *self);
+_OSTREE_PUBLIC
gboolean ostree_mutable_tree_replace_file (OstreeMutableTree *self,
const char *name,
const char *checksum,
GError **error);
+_OSTREE_PUBLIC
gboolean ostree_mutable_tree_ensure_dir (OstreeMutableTree *self,
const char *name,
OstreeMutableTree **out_subdir,
GError **error);
+_OSTREE_PUBLIC
gboolean ostree_mutable_tree_lookup (OstreeMutableTree *self,
const char *name,
char **out_file_checksum,
OstreeMutableTree **out_subdir,
GError **error);
-gboolean
+_OSTREE_PUBLIC gboolean
ostree_mutable_tree_ensure_parent_dirs (OstreeMutableTree *self,
GPtrArray *split_path,
const char *metadata_checksum,
OstreeMutableTree **out_parent,
GError **error);
+_OSTREE_PUBLIC
gboolean ostree_mutable_tree_walk (OstreeMutableTree *self,
GPtrArray *split_path,
guint start,
OstreeMutableTree **out_subdir,
GError **error);
+_OSTREE_PUBLIC
GHashTable * ostree_mutable_tree_get_subdirs (OstreeMutableTree *self);
+_OSTREE_PUBLIC
GHashTable * ostree_mutable_tree_get_files (OstreeMutableTree *self);
G_END_DECLS