diff options
author | Colin Walters <walters@verbum.org> | 2016-03-01 17:42:59 -0500 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2016-03-01 21:45:26 -0500 |
commit | 16979cc5ed9b158b1a9b5ba929c8af32baa41d9d (patch) | |
tree | 41614ab83ed32cbda21ad497d4f4a6a1a0b37f75 /src/libostree/ostree-deployment.h | |
parent | 2badf36cfdd7684eb83bb5d4113a4be6217a63ee (diff) | |
download | ostree-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-deployment.h')
-rw-r--r-- | src/libostree/ostree-deployment.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/libostree/ostree-deployment.h b/src/libostree/ostree-deployment.h index dc28d63a..a474b350 100644 --- a/src/libostree/ostree-deployment.h +++ b/src/libostree/ostree-deployment.h @@ -30,11 +30,15 @@ G_BEGIN_DECLS typedef struct _OstreeDeployment OstreeDeployment; +_OSTREE_PUBLIC GType ostree_deployment_get_type (void) G_GNUC_CONST; +_OSTREE_PUBLIC guint ostree_deployment_hash (gconstpointer v); +_OSTREE_PUBLIC gboolean ostree_deployment_equal (gconstpointer ap, gconstpointer bp); +_OSTREE_PUBLIC OstreeDeployment * ostree_deployment_new (int index, const char *osname, const char *csum, @@ -42,22 +46,36 @@ OstreeDeployment * ostree_deployment_new (int index, const char *bootcsum, int bootserial); +_OSTREE_PUBLIC int ostree_deployment_get_index (OstreeDeployment *self); +_OSTREE_PUBLIC const char *ostree_deployment_get_osname (OstreeDeployment *self); +_OSTREE_PUBLIC int ostree_deployment_get_deployserial (OstreeDeployment *self); +_OSTREE_PUBLIC const char *ostree_deployment_get_csum (OstreeDeployment *self); +_OSTREE_PUBLIC const char *ostree_deployment_get_bootcsum (OstreeDeployment *self); +_OSTREE_PUBLIC int ostree_deployment_get_bootserial (OstreeDeployment *self); +_OSTREE_PUBLIC OstreeBootconfigParser *ostree_deployment_get_bootconfig (OstreeDeployment *self); +_OSTREE_PUBLIC GKeyFile *ostree_deployment_get_origin (OstreeDeployment *self); +_OSTREE_PUBLIC void ostree_deployment_set_index (OstreeDeployment *self, int index); +_OSTREE_PUBLIC void ostree_deployment_set_bootserial (OstreeDeployment *self, int index); +_OSTREE_PUBLIC void ostree_deployment_set_bootconfig (OstreeDeployment *self, OstreeBootconfigParser *bootconfig); +_OSTREE_PUBLIC void ostree_deployment_set_origin (OstreeDeployment *self, GKeyFile *origin); +_OSTREE_PUBLIC OstreeDeployment *ostree_deployment_clone (OstreeDeployment *self); +_OSTREE_PUBLIC char *ostree_deployment_get_origin_relpath (OstreeDeployment *self); G_END_DECLS |