From: Paul Barker <p...@betafive.co.uk> This change allows us to support the placement of WORKDIR and DEPLOY_DIR on different devices. As the license files are typically small, the increase in disk usage and build time should be negligible.
Signed-off-by: Paul Barker <p...@betafive.co.uk> --- meta/classes/license_image.bbclass | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/meta/classes/license_image.bbclass b/meta/classes/license_image.bbclass index 67500386bf..655b56347f 100644 --- a/meta/classes/license_image.bbclass +++ b/meta/classes/license_image.bbclass @@ -37,6 +37,7 @@ python license_create_manifest() { def write_license_files(d, license_manifest, pkg_dic, rootfs=True): import re + import shutil import stat bad_licenses = (d.getVar("INCOMPATIBLE_LICENSE") or "").split() @@ -102,7 +103,7 @@ def write_license_files(d, license_manifest, pkg_dic, rootfs=True): rootfs_license_manifest = os.path.join(rootfs_license_dir, os.path.split(license_manifest)[1]) if not os.path.exists(rootfs_license_manifest): - os.link(license_manifest, rootfs_license_manifest) + shutil.copy(license_manifest, rootfs_license_manifest) if copy_lic_dirs == "1": for pkg in sorted(pkg_dic): @@ -136,7 +137,7 @@ def write_license_files(d, license_manifest, pkg_dic, rootfs=True): continue if not os.path.exists(rootfs_license): - os.link(pkg_license, rootfs_license) + shutil.copy(pkg_license, rootfs_license) if not os.path.exists(pkg_rootfs_license): os.symlink(os.path.join('..', lic), pkg_rootfs_license) @@ -146,7 +147,7 @@ def write_license_files(d, license_manifest, pkg_dic, rootfs=True): os.path.exists(pkg_rootfs_license)): continue - os.link(pkg_license, pkg_rootfs_license) + shutil.copy(pkg_license, pkg_rootfs_license) # Fixup file ownership and permissions for walkroot, dirs, files in os.walk(rootfs_license_dir): for f in files: -- 2.17.1 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core