flatpak-builtins-create-usb.c (flatpak-1.15.1.tar.xz) | : | flatpak-builtins-create-usb.c (flatpak-1.15.2.tar.xz) | ||
---|---|---|---|---|
skipping to change at line 114 | skipping to change at line 114 | |||
GError **error) | GError **error) | |||
{ | { | |||
g_autoptr(GBytes) deploy_data = NULL; | g_autoptr(GBytes) deploy_data = NULL; | |||
g_autoptr(FlatpakDeploy) deploy = NULL; | g_autoptr(FlatpakDeploy) deploy = NULL; | |||
g_autoptr(GKeyFile) metakey = NULL; | g_autoptr(GKeyFile) metakey = NULL; | |||
const char *commit = NULL; | const char *commit = NULL; | |||
g_autofree char *arch = NULL; | g_autofree char *arch = NULL; | |||
g_autofree char *branch = NULL; | g_autofree char *branch = NULL; | |||
GList *extensions, *l; | GList *extensions, *l; | |||
g_debug ("Finding related refs for ‘%s’", flatpak_decomposed_get_ref (ref)); | g_info ("Finding related refs for ‘%s’", flatpak_decomposed_get_ref (ref)); | |||
arch = flatpak_decomposed_dup_arch (ref); | arch = flatpak_decomposed_dup_arch (ref); | |||
branch = flatpak_decomposed_dup_branch (ref); | branch = flatpak_decomposed_dup_branch (ref); | |||
deploy_data = flatpak_dir_get_deploy_data (dir, ref, FLATPAK_DEPLOY_VERSION_AN Y, cancellable, error); | deploy_data = flatpak_dir_get_deploy_data (dir, ref, FLATPAK_DEPLOY_VERSION_AN Y, cancellable, error); | |||
if (deploy_data == NULL) | if (deploy_data == NULL) | |||
return FALSE; | return FALSE; | |||
if (flatpak_deploy_data_has_subpaths (deploy_data) && !opt_allow_partial) | if (flatpak_deploy_data_has_subpaths (deploy_data) && !opt_allow_partial) | |||
g_printerr (_("Warning: Related ref ‘%s’ is partially installed. Use --allow -partial to suppress this message.\n"), | g_printerr (_("Warning: Related ref ‘%s’ is partially installed. Use --allow -partial to suppress this message.\n"), | |||
skipping to change at line 231 | skipping to change at line 231 | |||
g_autoptr(FlatpakDecomposed) runtime_ref = NULL; | g_autoptr(FlatpakDecomposed) runtime_ref = NULL; | |||
g_autofree char *runtime_remote = NULL; | g_autofree char *runtime_remote = NULL; | |||
g_autofree char *runtime_collection_id = NULL; | g_autofree char *runtime_collection_id = NULL; | |||
g_autofree const char **runtime_subpaths = NULL; | g_autofree const char **runtime_subpaths = NULL; | |||
g_auto(GStrv) resolved_runtime_subpaths = NULL; | g_auto(GStrv) resolved_runtime_subpaths = NULL; | |||
const char *commit = NULL; | const char *commit = NULL; | |||
const char *runtime_commit = NULL; | const char *runtime_commit = NULL; | |||
CommitAndSubpaths *c_s; | CommitAndSubpaths *c_s; | |||
g_autoptr(GVariant) extra_data_sources = NULL; | g_autoptr(GVariant) extra_data_sources = NULL; | |||
g_debug ("Finding the runtime for ‘%s’", flatpak_decomposed_get_ref (ref)); | g_info ("Finding the runtime for ‘%s’", flatpak_decomposed_get_ref (ref)); | |||
deploy_data = flatpak_dir_get_deploy_data (dir, ref, FLATPAK_DEPLOY_VERSION_AN Y, cancellable, error); | deploy_data = flatpak_dir_get_deploy_data (dir, ref, FLATPAK_DEPLOY_VERSION_AN Y, cancellable, error); | |||
if (deploy_data == NULL) | if (deploy_data == NULL) | |||
return FALSE; | return FALSE; | |||
commit = flatpak_deploy_data_get_commit (deploy_data); | commit = flatpak_deploy_data_get_commit (deploy_data); | |||
deploy = flatpak_dir_load_deployed (dir, ref, commit, cancellable, error); | deploy = flatpak_dir_load_deployed (dir, ref, commit, cancellable, error); | |||
if (deploy == NULL) | if (deploy == NULL) | |||
return FALSE; | return FALSE; | |||
skipping to change at line 319 | skipping to change at line 319 | |||
if (!glnx_shutil_mkdir_p_at (mount_root_dfd, dest_repo_path, 0755, cancellable , error)) | if (!glnx_shutil_mkdir_p_at (mount_root_dfd, dest_repo_path, 0755, cancellable , error)) | |||
return FALSE; | return FALSE; | |||
/* Always use the archive repo mode, which works on FAT file systems that | /* Always use the archive repo mode, which works on FAT file systems that | |||
* don't support xattrs, compresses files to save space, doesn't store | * don't support xattrs, compresses files to save space, doesn't store | |||
* permission info directly in the file attributes, and is at least sometimes | * permission info directly in the file attributes, and is at least sometimes | |||
* more performant than bare-user */ | * more performant than bare-user */ | |||
OstreeRepoMode mode = OSTREE_REPO_MODE_ARCHIVE; | OstreeRepoMode mode = OSTREE_REPO_MODE_ARCHIVE; | |||
g_debug ("%s: Creating repository in mode %u", G_STRFUNC, mode); | g_info ("%s: Creating repository in mode %u", G_STRFUNC, mode); | |||
g_autoptr(OstreeRepo) dest_repo = ostree_repo_create_at (mount_root_dfd, dest_ repo_path, | g_autoptr(OstreeRepo) dest_repo = ostree_repo_create_at (mount_root_dfd, dest_ repo_path, | |||
mode, NULL, cancellab le, error); | mode, NULL, cancellab le, error); | |||
if (dest_repo == NULL) | if (dest_repo == NULL) | |||
return FALSE; | return FALSE; | |||
struct stat dest_repo_stbuf; | struct stat dest_repo_stbuf; | |||
if (!glnx_fstat (ostree_repo_get_dfd (dest_repo), &dest_repo_stbuf, error)) | if (!glnx_fstat (ostree_repo_get_dfd (dest_repo), &dest_repo_stbuf, error)) | |||
return FALSE; | return FALSE; | |||
skipping to change at line 788 | skipping to change at line 788 | |||
{ | { | |||
if (appstream_error != NULL) | if (appstream_error != NULL) | |||
{ | { | |||
/* Print a warning if both appstream and appstream2 are missing */ | /* Print a warning if both appstream and appstream2 are missing */ | |||
g_printerr (_("Warning: Couldn't find appstream data for remote ‘%s’ arch ‘%s’: %s; %s\n"), | g_printerr (_("Warning: Couldn't find appstream data for remote ‘%s’ arch ‘%s’: %s; %s\n"), | |||
remote_name, current_arch, appstream2_error->message , appstream_error->message); | remote_name, current_arch, appstream2_error->message , appstream_error->message); | |||
} | } | |||
else | else | |||
{ | { | |||
/* Appstream2 is only for efficiency, so just print a debug mess age */ | /* Appstream2 is only for efficiency, so just print a debug mess age */ | |||
g_debug (_("Couldn't find appstream2 data for remote ‘%s’ arch ‘ %s’: %s\n"), | g_info (_("Couldn't find appstream2 data for remote ‘%s’ arch ‘% s’: %s\n"), | |||
remote_name, current_arch, appstream2_error->message); | remote_name, current_arch, appstream2_error->message); | |||
} | } | |||
} | } | |||
} | } | |||
} | } | |||
/* Delete the local source repo summary if it exists. Old versions of this | /* Delete the local source repo summary if it exists. Old versions of this | |||
* command erroneously created it and if it's outdated that causes problems. * / | * command erroneously created it and if it's outdated that causes problems. * / | |||
if (!flatpak_dir_update_summary (dir, TRUE, cancellable, error)) | if (!flatpak_dir_update_summary (dir, TRUE, cancellable, error)) | |||
return FALSE; | return FALSE; | |||
skipping to change at line 817 | skipping to change at line 817 | |||
GLNX_HASH_TABLE_FOREACH (all_refs, OstreeCollectionRef *, collection_ref) | GLNX_HASH_TABLE_FOREACH (all_refs, OstreeCollectionRef *, collection_ref) | |||
{ | { | |||
if (!ostree_validate_collection_id (collection_ref->collection_id, error)) | if (!ostree_validate_collection_id (collection_ref->collection_id, error)) | |||
return FALSE; | return FALSE; | |||
if (!ostree_validate_rev (collection_ref->ref_name, error)) | if (!ostree_validate_rev (collection_ref->ref_name, error)) | |||
return FALSE; | return FALSE; | |||
g_string_append_printf (all_refs_str, "(%s, %s) ", collection_ref->collect ion_id, collection_ref->ref_name); | g_string_append_printf (all_refs_str, "(%s, %s) ", collection_ref->collect ion_id, collection_ref->ref_name); | |||
} | } | |||
g_debug ("Copying the following refs: %s", all_refs_str->str); | g_info ("Copying the following refs: %s", all_refs_str->str); | |||
if (!ostree_create_usb (context, src_repo, mount_root_path, mount_root_stbuf , | if (!ostree_create_usb (context, src_repo, mount_root_path, mount_root_stbuf , | |||
mount_root_dfd, all_refs, cancellable, error)) | mount_root_dfd, all_refs, cancellable, error)) | |||
return FALSE; | return FALSE; | |||
} | } | |||
return TRUE; | return TRUE; | |||
} | } | |||
gboolean | gboolean | |||
End of changes. 5 change blocks. | ||||
5 lines changed or deleted | 5 lines changed or added |