Bug 5572 - Enalbe COPY_LIC_MANIFEST and COPY_LIC_DIRS: No kernel license is installed in image
Summary: Enalbe COPY_LIC_MANIFEST and COPY_LIC_DIRS: No kernel license is installed in...
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 1.6
Hardware: x86 Multiple
: Medium normal
Target Milestone: 1.6 M1
Assignee: Hongxu Jia
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2013-11-20 10:34 UTC by Hongxu Jia
Modified: 2014-02-27 06:47 UTC (History)
7 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Don't know


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hongxu Jia 2013-11-20 10:34:33 UTC
Enalbe COPY_LIC_MANIFEST and COPY_LIC_DIRS: No kernel license is installed in image

*env
Add COPY_LIC_MANIFEST = "1" and COPY_LIC_DIRS = "1" to local.conf

*problem

Build image and no kernel license in ${IMAGE_ROOTFS}/usr/share/common-licenses/${pkg}/${lic};

jiahongxu:1.0-r0$bitbake core-image-minimal
jiahongxu:1.0-r0$ ls rootfs/usr/share/common-licenses/kernel-3.10.17-yocto-standard
jiahongxu:1.0-r0$ 

*analysis
For each recipe, it populated license files to ${LICENSE_DIRECTORY}/${PN},
such as kernel's license dir was ${LICENSE_DIRECTORY}/kernel-3.10.17-yocto-standard;

In do_rootfs task, it copied license directories from ${LICENSE_DIRECTORY}/
${pkg}, and ${pkg} was listed in ${INSTALLED_PKGS};

We got ${INSTALLED_PKGS} by rpm query, such as the kernel were 'kernel-*',
but the kernel's PN was linux-yocto, so searching ${LICENSE_DIRECTORY}/
kernel-* failed.

*solution
Copied license directories from ${LICENSE_DIRECTORY}/${PN} fixed this issue.