deploy: Use internal recursive copy rather than libgsystem

Since we already had a "recursive copy" implementation here, let's
reuse it rather than the libgsystem `gs_shutil_cp_a()`.  Part of the
libglnx porting.

Closes: #428
Approved by: jlebon
This commit is contained in:
Colin Walters 2016-08-04 09:37:26 -04:00 committed by Atomic Bot
parent 686d0352e1
commit d238683332
1 changed files with 7 additions and 2 deletions

View File

@ -854,10 +854,15 @@ merge_configuration (OstreeSysroot *sysroot,
if (usretc_exists)
{
glnx_fd_close int deployment_usr_dfd = -1;
if (!glnx_opendirat (deployment_dfd, "usr", TRUE, &deployment_usr_dfd, error))
goto out;
/* TODO - set out labels as we copy files */
g_assert (!etc_exists);
if (!gs_shutil_cp_a (deployment_usretc_path, deployment_etc_path,
cancellable, error))
if (!copy_dir_recurse (deployment_usr_dfd, deployment_dfd, "etc",
cancellable, error))
goto out;
/* Here, we initialize SELinux policy from the /usr/etc inside