libostree: Make OstreeBootloader private
It was only temporarily public while functionality was being merged down; that's done now.
This commit is contained in:
parent
4abaf27e57
commit
ac0154713d
|
|
@ -27,7 +27,6 @@ libostree_public_headers = \
|
||||||
src/libostree/ostree-repo-file.h \
|
src/libostree/ostree-repo-file.h \
|
||||||
src/libostree/ostree-diff.h \
|
src/libostree/ostree-diff.h \
|
||||||
src/libostree/ostree-sysroot.h \
|
src/libostree/ostree-sysroot.h \
|
||||||
src/libostree/ostree-bootloader.h \
|
|
||||||
src/libostree/ostree-deployment.h \
|
src/libostree/ostree-deployment.h \
|
||||||
src/libostree/ostree-bootconfig-parser.h \
|
src/libostree/ostree-bootconfig-parser.h \
|
||||||
$(NULL)
|
$(NULL)
|
||||||
|
|
|
||||||
|
|
@ -49,6 +49,7 @@ libostree_1_la_SOURCES = \
|
||||||
src/libostree/ostree-sysroot-deploy.c \
|
src/libostree/ostree-sysroot-deploy.c \
|
||||||
src/libostree/ostree-bootconfig-parser.c \
|
src/libostree/ostree-bootconfig-parser.c \
|
||||||
src/libostree/ostree-deployment.c \
|
src/libostree/ostree-deployment.c \
|
||||||
|
src/libostree/ostree-bootloader.h \
|
||||||
src/libostree/ostree-bootloader.c \
|
src/libostree/ostree-bootloader.c \
|
||||||
src/libostree/ostree-bootloader-syslinux.h \
|
src/libostree/ostree-bootloader-syslinux.h \
|
||||||
src/libostree/ostree-bootloader-syslinux.c \
|
src/libostree/ostree-bootloader-syslinux.c \
|
||||||
|
|
|
||||||
|
|
@ -37,12 +37,12 @@ struct _OstreeBootloaderSyslinux
|
||||||
|
|
||||||
typedef GObjectClass OstreeBootloaderSyslinuxClass;
|
typedef GObjectClass OstreeBootloaderSyslinuxClass;
|
||||||
|
|
||||||
static void ostree_bootloader_syslinux_bootloader_iface_init (OstreeBootloaderInterface *iface);
|
static void _ostree_bootloader_syslinux_bootloader_iface_init (OstreeBootloaderInterface *iface);
|
||||||
G_DEFINE_TYPE_WITH_CODE (OstreeBootloaderSyslinux, ostree_bootloader_syslinux, G_TYPE_OBJECT,
|
G_DEFINE_TYPE_WITH_CODE (OstreeBootloaderSyslinux, _ostree_bootloader_syslinux, G_TYPE_OBJECT,
|
||||||
G_IMPLEMENT_INTERFACE (OSTREE_TYPE_BOOTLOADER, ostree_bootloader_syslinux_bootloader_iface_init));
|
G_IMPLEMENT_INTERFACE (OSTREE_TYPE_BOOTLOADER, _ostree_bootloader_syslinux_bootloader_iface_init));
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
ostree_bootloader_syslinux_query (OstreeBootloader *bootloader)
|
_ostree_bootloader_syslinux_query (OstreeBootloader *bootloader)
|
||||||
{
|
{
|
||||||
OstreeBootloaderSyslinux *self = OSTREE_BOOTLOADER_SYSLINUX (bootloader);
|
OstreeBootloaderSyslinux *self = OSTREE_BOOTLOADER_SYSLINUX (bootloader);
|
||||||
|
|
||||||
|
|
@ -50,7 +50,7 @@ ostree_bootloader_syslinux_query (OstreeBootloader *bootloader)
|
||||||
}
|
}
|
||||||
|
|
||||||
static const char *
|
static const char *
|
||||||
ostree_bootloader_syslinux_get_name (OstreeBootloader *bootloader)
|
_ostree_bootloader_syslinux_get_name (OstreeBootloader *bootloader)
|
||||||
{
|
{
|
||||||
return "syslinux";
|
return "syslinux";
|
||||||
}
|
}
|
||||||
|
|
@ -111,7 +111,7 @@ append_config_from_boostree_loader_entries (OstreeBootloaderSyslinux *self,
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
ostree_bootloader_syslinux_write_config (OstreeBootloader *bootloader,
|
_ostree_bootloader_syslinux_write_config (OstreeBootloader *bootloader,
|
||||||
int bootversion,
|
int bootversion,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error)
|
GError **error)
|
||||||
|
|
@ -254,39 +254,39 @@ ostree_bootloader_syslinux_write_config (OstreeBootloader *bootloader,
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
ostree_bootloader_syslinux_finalize (GObject *object)
|
_ostree_bootloader_syslinux_finalize (GObject *object)
|
||||||
{
|
{
|
||||||
OstreeBootloaderSyslinux *self = OSTREE_BOOTLOADER_SYSLINUX (object);
|
OstreeBootloaderSyslinux *self = OSTREE_BOOTLOADER_SYSLINUX (object);
|
||||||
|
|
||||||
g_clear_object (&self->sysroot);
|
g_clear_object (&self->sysroot);
|
||||||
g_clear_object (&self->config_path);
|
g_clear_object (&self->config_path);
|
||||||
|
|
||||||
G_OBJECT_CLASS (ostree_bootloader_syslinux_parent_class)->finalize (object);
|
G_OBJECT_CLASS (_ostree_bootloader_syslinux_parent_class)->finalize (object);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
ostree_bootloader_syslinux_init (OstreeBootloaderSyslinux *self)
|
_ostree_bootloader_syslinux_init (OstreeBootloaderSyslinux *self)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
ostree_bootloader_syslinux_bootloader_iface_init (OstreeBootloaderInterface *iface)
|
_ostree_bootloader_syslinux_bootloader_iface_init (OstreeBootloaderInterface *iface)
|
||||||
{
|
{
|
||||||
iface->query = ostree_bootloader_syslinux_query;
|
iface->query = _ostree_bootloader_syslinux_query;
|
||||||
iface->get_name = ostree_bootloader_syslinux_get_name;
|
iface->get_name = _ostree_bootloader_syslinux_get_name;
|
||||||
iface->write_config = ostree_bootloader_syslinux_write_config;
|
iface->write_config = _ostree_bootloader_syslinux_write_config;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
ostree_bootloader_syslinux_class_init (OstreeBootloaderSyslinuxClass *class)
|
_ostree_bootloader_syslinux_class_init (OstreeBootloaderSyslinuxClass *class)
|
||||||
{
|
{
|
||||||
GObjectClass *object_class = G_OBJECT_CLASS (class);
|
GObjectClass *object_class = G_OBJECT_CLASS (class);
|
||||||
|
|
||||||
object_class->finalize = ostree_bootloader_syslinux_finalize;
|
object_class->finalize = _ostree_bootloader_syslinux_finalize;
|
||||||
}
|
}
|
||||||
|
|
||||||
OstreeBootloaderSyslinux *
|
OstreeBootloaderSyslinux *
|
||||||
ostree_bootloader_syslinux_new (OstreeSysroot *sysroot)
|
_ostree_bootloader_syslinux_new (OstreeSysroot *sysroot)
|
||||||
{
|
{
|
||||||
OstreeBootloaderSyslinux *self = g_object_new (OSTREE_TYPE_BOOTLOADER_SYSLINUX, NULL);
|
OstreeBootloaderSyslinux *self = g_object_new (OSTREE_TYPE_BOOTLOADER_SYSLINUX, NULL);
|
||||||
self->sysroot = g_object_ref (sysroot);
|
self->sysroot = g_object_ref (sysroot);
|
||||||
|
|
|
||||||
|
|
@ -24,15 +24,15 @@
|
||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
|
||||||
#define OSTREE_TYPE_BOOTLOADER_SYSLINUX (ostree_bootloader_syslinux_get_type ())
|
#define OSTREE_TYPE_BOOTLOADER_SYSLINUX (_ostree_bootloader_syslinux_get_type ())
|
||||||
#define OSTREE_BOOTLOADER_SYSLINUX(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), OSTREE_TYPE_BOOTLOADER_SYSLINUX, OstreeBootloaderSyslinux))
|
#define OSTREE_BOOTLOADER_SYSLINUX(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), OSTREE_TYPE_BOOTLOADER_SYSLINUX, OstreeBootloaderSyslinux))
|
||||||
#define OSTREE_IS_BOOTLOADER_SYSLINUX(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), OSTREE_TYPE_BOOTLOADER_SYSLINUX))
|
#define OSTREE_IS_BOOTLOADER_SYSLINUX(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), OSTREE_TYPE_BOOTLOADER_SYSLINUX))
|
||||||
|
|
||||||
typedef struct _OstreeBootloaderSyslinux OstreeBootloaderSyslinux;
|
typedef struct _OstreeBootloaderSyslinux OstreeBootloaderSyslinux;
|
||||||
|
|
||||||
GType ostree_bootloader_syslinux_get_type (void) G_GNUC_CONST;
|
GType _ostree_bootloader_syslinux_get_type (void) G_GNUC_CONST;
|
||||||
|
|
||||||
OstreeBootloaderSyslinux * ostree_bootloader_syslinux_new (OstreeSysroot *sysroot);
|
OstreeBootloaderSyslinux * _ostree_bootloader_syslinux_new (OstreeSysroot *sysroot);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -41,12 +41,12 @@ struct _OstreeBootloaderUboot
|
||||||
|
|
||||||
typedef GObjectClass OstreeBootloaderUbootClass;
|
typedef GObjectClass OstreeBootloaderUbootClass;
|
||||||
|
|
||||||
static void ostree_bootloader_uboot_bootloader_iface_init (OstreeBootloaderInterface *iface);
|
static void _ostree_bootloader_uboot_bootloader_iface_init (OstreeBootloaderInterface *iface);
|
||||||
G_DEFINE_TYPE_WITH_CODE (OstreeBootloaderUboot, ostree_bootloader_uboot, G_TYPE_OBJECT,
|
G_DEFINE_TYPE_WITH_CODE (OstreeBootloaderUboot, _ostree_bootloader_uboot, G_TYPE_OBJECT,
|
||||||
G_IMPLEMENT_INTERFACE (OSTREE_TYPE_BOOTLOADER, ostree_bootloader_uboot_bootloader_iface_init));
|
G_IMPLEMENT_INTERFACE (OSTREE_TYPE_BOOTLOADER, _ostree_bootloader_uboot_bootloader_iface_init));
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
ostree_bootloader_uboot_query (OstreeBootloader *bootloader)
|
_ostree_bootloader_uboot_query (OstreeBootloader *bootloader)
|
||||||
{
|
{
|
||||||
OstreeBootloaderUboot *self = OSTREE_BOOTLOADER_UBOOT (bootloader);
|
OstreeBootloaderUboot *self = OSTREE_BOOTLOADER_UBOOT (bootloader);
|
||||||
|
|
||||||
|
|
@ -54,7 +54,7 @@ ostree_bootloader_uboot_query (OstreeBootloader *bootloader)
|
||||||
}
|
}
|
||||||
|
|
||||||
static const char *
|
static const char *
|
||||||
ostree_bootloader_uboot_get_name (OstreeBootloader *bootloader)
|
_ostree_bootloader_uboot_get_name (OstreeBootloader *bootloader)
|
||||||
{
|
{
|
||||||
return "U-Boot";
|
return "U-Boot";
|
||||||
}
|
}
|
||||||
|
|
@ -98,7 +98,7 @@ create_config_from_boot_loader_entries (OstreeBootloaderUboot *self,
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
ostree_bootloader_uboot_write_config (OstreeBootloader *bootloader,
|
_ostree_bootloader_uboot_write_config (OstreeBootloader *bootloader,
|
||||||
int bootversion,
|
int bootversion,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error)
|
GError **error)
|
||||||
|
|
@ -139,39 +139,39 @@ ostree_bootloader_uboot_write_config (OstreeBootloader *bootloader,
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
ostree_bootloader_uboot_finalize (GObject *object)
|
_ostree_bootloader_uboot_finalize (GObject *object)
|
||||||
{
|
{
|
||||||
OstreeBootloaderUboot *self = OSTREE_BOOTLOADER_UBOOT (object);
|
OstreeBootloaderUboot *self = OSTREE_BOOTLOADER_UBOOT (object);
|
||||||
|
|
||||||
g_clear_object (&self->sysroot);
|
g_clear_object (&self->sysroot);
|
||||||
g_clear_object (&self->config_path);
|
g_clear_object (&self->config_path);
|
||||||
|
|
||||||
G_OBJECT_CLASS (ostree_bootloader_uboot_parent_class)->finalize (object);
|
G_OBJECT_CLASS (_ostree_bootloader_uboot_parent_class)->finalize (object);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
ostree_bootloader_uboot_init (OstreeBootloaderUboot *self)
|
_ostree_bootloader_uboot_init (OstreeBootloaderUboot *self)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
ostree_bootloader_uboot_bootloader_iface_init (OstreeBootloaderInterface *iface)
|
_ostree_bootloader_uboot_bootloader_iface_init (OstreeBootloaderInterface *iface)
|
||||||
{
|
{
|
||||||
iface->query = ostree_bootloader_uboot_query;
|
iface->query = _ostree_bootloader_uboot_query;
|
||||||
iface->get_name = ostree_bootloader_uboot_get_name;
|
iface->get_name = _ostree_bootloader_uboot_get_name;
|
||||||
iface->write_config = ostree_bootloader_uboot_write_config;
|
iface->write_config = _ostree_bootloader_uboot_write_config;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
ostree_bootloader_uboot_class_init (OstreeBootloaderUbootClass *class)
|
_ostree_bootloader_uboot_class_init (OstreeBootloaderUbootClass *class)
|
||||||
{
|
{
|
||||||
GObjectClass *object_class = G_OBJECT_CLASS (class);
|
GObjectClass *object_class = G_OBJECT_CLASS (class);
|
||||||
|
|
||||||
object_class->finalize = ostree_bootloader_uboot_finalize;
|
object_class->finalize = _ostree_bootloader_uboot_finalize;
|
||||||
}
|
}
|
||||||
|
|
||||||
OstreeBootloaderUboot *
|
OstreeBootloaderUboot *
|
||||||
ostree_bootloader_uboot_new (OstreeSysroot *sysroot)
|
_ostree_bootloader_uboot_new (OstreeSysroot *sysroot)
|
||||||
{
|
{
|
||||||
OstreeBootloaderUboot *self = g_object_new (OSTREE_TYPE_BOOTLOADER_UBOOT, NULL);
|
OstreeBootloaderUboot *self = g_object_new (OSTREE_TYPE_BOOTLOADER_UBOOT, NULL);
|
||||||
self->sysroot = g_object_ref (sysroot);
|
self->sysroot = g_object_ref (sysroot);
|
||||||
|
|
|
||||||
|
|
@ -28,14 +28,14 @@
|
||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
|
||||||
#define OSTREE_TYPE_BOOTLOADER_UBOOT (ostree_bootloader_uboot_get_type ())
|
#define OSTREE_TYPE_BOOTLOADER_UBOOT (_ostree_bootloader_uboot_get_type ())
|
||||||
#define OSTREE_BOOTLOADER_UBOOT(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), OSTREE_TYPE_BOOTLOADER_UBOOT, OstreeBootloaderUboot))
|
#define OSTREE_BOOTLOADER_UBOOT(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), OSTREE_TYPE_BOOTLOADER_UBOOT, OstreeBootloaderUboot))
|
||||||
#define OSTREE_IS_BOOTLOADER_UBOOT(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), OSTREE_TYPE_BOOTLOADER_UBOOT))
|
#define OSTREE_IS_BOOTLOADER_UBOOT(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), OSTREE_TYPE_BOOTLOADER_UBOOT))
|
||||||
|
|
||||||
typedef struct _OstreeBootloaderUboot OstreeBootloaderUboot;
|
typedef struct _OstreeBootloaderUboot OstreeBootloaderUboot;
|
||||||
|
|
||||||
GType ostree_bootloader_uboot_get_type (void) G_GNUC_CONST;
|
GType _ostree_bootloader_uboot_get_type (void) G_GNUC_CONST;
|
||||||
|
|
||||||
OstreeBootloaderUboot * ostree_bootloader_uboot_new (OstreeSysroot *sysroot);
|
OstreeBootloaderUboot * _ostree_bootloader_uboot_new (OstreeSysroot *sysroot);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
|
||||||
|
|
@ -22,15 +22,15 @@
|
||||||
#include "ostree-bootloader.h"
|
#include "ostree-bootloader.h"
|
||||||
#include "libgsystem.h"
|
#include "libgsystem.h"
|
||||||
|
|
||||||
G_DEFINE_INTERFACE (OstreeBootloader, ostree_bootloader, G_TYPE_OBJECT)
|
G_DEFINE_INTERFACE (OstreeBootloader, _ostree_bootloader, G_TYPE_OBJECT)
|
||||||
|
|
||||||
static void
|
static void
|
||||||
ostree_bootloader_default_init (OstreeBootloaderInterface *iface)
|
_ostree_bootloader_default_init (OstreeBootloaderInterface *iface)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
gboolean
|
||||||
ostree_bootloader_query (OstreeBootloader *self)
|
_ostree_bootloader_query (OstreeBootloader *self)
|
||||||
{
|
{
|
||||||
g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), FALSE);
|
g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), FALSE);
|
||||||
|
|
||||||
|
|
@ -38,12 +38,12 @@ ostree_bootloader_query (OstreeBootloader *self)
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ostree_bootloader_get_name:
|
* _ostree_bootloader_get_name:
|
||||||
*
|
*
|
||||||
* Returns: (transfer none): Name of this bootloader
|
* Returns: (transfer none): Name of this bootloader
|
||||||
*/
|
*/
|
||||||
const char *
|
const char *
|
||||||
ostree_bootloader_get_name (OstreeBootloader *self)
|
_ostree_bootloader_get_name (OstreeBootloader *self)
|
||||||
{
|
{
|
||||||
g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), NULL);
|
g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), NULL);
|
||||||
|
|
||||||
|
|
@ -51,7 +51,7 @@ ostree_bootloader_get_name (OstreeBootloader *self)
|
||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
gboolean
|
||||||
ostree_bootloader_write_config (OstreeBootloader *self,
|
_ostree_bootloader_write_config (OstreeBootloader *self,
|
||||||
int bootversion,
|
int bootversion,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error)
|
GError **error)
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@
|
||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
|
||||||
#define OSTREE_TYPE_BOOTLOADER (ostree_bootloader_get_type ())
|
#define OSTREE_TYPE_BOOTLOADER (_ostree_bootloader_get_type ())
|
||||||
#define OSTREE_BOOTLOADER(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), OSTREE_TYPE_BOOTLOADER, OstreeBootloader))
|
#define OSTREE_BOOTLOADER(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), OSTREE_TYPE_BOOTLOADER, OstreeBootloader))
|
||||||
#define OSTREE_IS_BOOTLOADER(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), OSTREE_TYPE_BOOTLOADER))
|
#define OSTREE_IS_BOOTLOADER(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), OSTREE_TYPE_BOOTLOADER))
|
||||||
#define OSTREE_BOOTLOADER_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), OSTREE_TYPE_BOOTLOADER, OstreeBootloaderInterface))
|
#define OSTREE_BOOTLOADER_GET_IFACE(inst) (G_TYPE_INSTANCE_GET_INTERFACE ((inst), OSTREE_TYPE_BOOTLOADER, OstreeBootloaderInterface))
|
||||||
|
|
@ -45,16 +45,16 @@ struct _OstreeBootloaderInterface
|
||||||
GError **error);
|
GError **error);
|
||||||
};
|
};
|
||||||
|
|
||||||
GType ostree_bootloader_get_type (void) G_GNUC_CONST;
|
GType _ostree_bootloader_get_type (void) G_GNUC_CONST;
|
||||||
|
|
||||||
gboolean ostree_bootloader_query (OstreeBootloader *self);
|
gboolean _ostree_bootloader_query (OstreeBootloader *self);
|
||||||
|
|
||||||
const char *ostree_bootloader_get_name (OstreeBootloader *self);
|
const char *_ostree_bootloader_get_name (OstreeBootloader *self);
|
||||||
|
|
||||||
gboolean ostree_bootloader_write_config (OstreeBootloader *self,
|
gboolean _ostree_bootloader_write_config (OstreeBootloader *self,
|
||||||
int bootversion,
|
int bootversion,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -992,10 +992,10 @@ ostree_sysroot_write_deployments (OstreeSysroot *sysroot,
|
||||||
{
|
{
|
||||||
gboolean ret = FALSE;
|
gboolean ret = FALSE;
|
||||||
guint i;
|
guint i;
|
||||||
gs_unref_object OstreeBootloader *bootloader = ostree_sysroot_query_bootloader (sysroot);
|
gs_unref_object OstreeBootloader *bootloader = _ostree_sysroot_query_bootloader (sysroot);
|
||||||
|
|
||||||
if (bootloader)
|
if (bootloader)
|
||||||
g_print ("Detected bootloader: %s\n", ostree_bootloader_get_name (bootloader));
|
g_print ("Detected bootloader: %s\n", _ostree_bootloader_get_name (bootloader));
|
||||||
else
|
else
|
||||||
g_print ("Detected bootloader: (unknown)\n");
|
g_print ("Detected bootloader: (unknown)\n");
|
||||||
|
|
||||||
|
|
@ -1043,8 +1043,8 @@ ostree_sysroot_write_deployments (OstreeSysroot *sysroot,
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bootloader && !ostree_bootloader_write_config (bootloader, new_bootversion,
|
if (bootloader && !_ostree_bootloader_write_config (bootloader, new_bootversion,
|
||||||
cancellable, error))
|
cancellable, error))
|
||||||
{
|
{
|
||||||
g_prefix_error (error, "Bootloader write config: ");
|
g_prefix_error (error, "Bootloader write config: ");
|
||||||
goto out;
|
goto out;
|
||||||
|
|
|
||||||
|
|
@ -60,5 +60,7 @@ OstreeOrderedHash *_ostree_sysroot_parse_kernel_args (const char *options);
|
||||||
|
|
||||||
char * _ostree_sysroot_kernel_arg_string_serialize (OstreeOrderedHash *ohash);
|
char * _ostree_sysroot_kernel_arg_string_serialize (OstreeOrderedHash *ohash);
|
||||||
|
|
||||||
|
OstreeBootloader *_ostree_sysroot_query_bootloader (OstreeSysroot *sysroot);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -800,17 +800,17 @@ ostree_sysroot_get_repo (OstreeSysroot *self,
|
||||||
* Returns: (transfer full): Currently active bootloader in @sysroot
|
* Returns: (transfer full): Currently active bootloader in @sysroot
|
||||||
*/
|
*/
|
||||||
OstreeBootloader *
|
OstreeBootloader *
|
||||||
ostree_sysroot_query_bootloader (OstreeSysroot *self)
|
_ostree_sysroot_query_bootloader (OstreeSysroot *self)
|
||||||
{
|
{
|
||||||
OstreeBootloaderSyslinux *syslinux;
|
OstreeBootloaderSyslinux *syslinux;
|
||||||
OstreeBootloaderUboot *uboot;
|
OstreeBootloaderUboot *uboot;
|
||||||
|
|
||||||
syslinux = ostree_bootloader_syslinux_new (self);
|
syslinux = _ostree_bootloader_syslinux_new (self);
|
||||||
if (ostree_bootloader_query ((OstreeBootloader*)syslinux))
|
if (_ostree_bootloader_query ((OstreeBootloader*)syslinux))
|
||||||
return (OstreeBootloader*) (syslinux);
|
return (OstreeBootloader*) (syslinux);
|
||||||
|
|
||||||
uboot = ostree_bootloader_uboot_new (self);
|
uboot = _ostree_bootloader_uboot_new (self);
|
||||||
if (ostree_bootloader_query ((OstreeBootloader*)uboot))
|
if (_ostree_bootloader_query ((OstreeBootloader*)uboot))
|
||||||
return (OstreeBootloader*) (uboot);
|
return (OstreeBootloader*) (uboot);
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
|
||||||
|
|
@ -70,8 +70,6 @@ gboolean ostree_sysroot_get_repo (OstreeSysroot *self,
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
OstreeBootloader *ostree_sysroot_query_bootloader (OstreeSysroot *sysroot);
|
|
||||||
|
|
||||||
|
|
||||||
gboolean ostree_sysroot_find_booted_deployment (OstreeSysroot *sysroot,
|
gboolean ostree_sysroot_find_booted_deployment (OstreeSysroot *sysroot,
|
||||||
GPtrArray *deployments,
|
GPtrArray *deployments,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue