[OE-core] [PATCH 1/1] kernel-devsrc: remove symlink source

Robert Yang liezhi.yang at windriver.com
Wed Nov 30 02:21:27 UTC 2016



On 11/29/2016 06:57 PM, Bruce Ashfield wrote:
>
>
> On Tue, Nov 29, 2016 at 4:16 AM, Robert Yang <liezhi.yang at windriver.com
> <mailto:liezhi.yang at windriver.com>> wrote:
>
>     Fixed:
>     $ rpm -qplv tmp/deploy/rpm/qemuppc/kernel-devsrc-1.0-r0.qemuppc.rpm | grep
>     kernel/source
>     /usr/src/kernel/source ->
>     /buildarea/lyang1/test_yocto/tmp/work/qemuppc-poky-linux/kernel-devsrc/1.0-r0/image/usr/src/kernel
>
>     It is generated by kernel's "make clean _mrproper_scripts", the
>     kernel-devsrc includeds full sources, this symlink is not needed, and
>     the path is invalid on target, so remove it.
>
>     Signed-off-by: Robert Yang <liezhi.yang at windriver.com
>     <mailto:liezhi.yang at windriver.com>>
>     ---
>      meta/recipes-kernel/linux/kernel-devsrc.bb <http://kernel-devsrc.bb> | 7
>     +++++++
>      1 file changed, 7 insertions(+)
>
>     diff --git a/meta/recipes-kernel/linux/kernel-devsrc.bb
>     <http://kernel-devsrc.bb> b/meta/recipes-kernel/linux/kernel-devsrc.bb
>     <http://kernel-devsrc.bb>
>     index 9fd2e08..b182936 100644
>     --- a/meta/recipes-kernel/linux/kernel-devsrc.bb <http://kernel-devsrc.bb>
>     +++ b/meta/recipes-kernel/linux/kernel-devsrc.bb <http://kernel-devsrc.bb>
>     @@ -53,6 +53,13 @@ do_install() {
>              # architecture (since scripts and helpers are native format).
>              KBUILD_OUTPUT="$kerneldir"
>              oe_runmake -C $kerneldir CC="${KERNEL_CC}" LD="${KERNEL_LD}" clean
>     _mrproper_scripts
>     +        # make clean generates an absolute path symlink called "source"
>     +        # in $kerneldir points to $kerneldir, which doesn't make any
>     +        # sense, so remove it.
>     +        if [ -L $kerneldir/source ]; then
>     +            bbnote "Removing $kerneldir/source"
>
>
> This message needs to be clarified. When that comes out, I'd read it and think
> "it is removing my kernel source".
>
> Maybe:
>
>  bbnote "Removing $kerneldir/source symlink"
>
> is better.

Thanks, updated in the repo:

diff --git a/meta/recipes-kernel/linux/kernel-devsrc.bb 
b/meta/recipes-kernel/linux/kernel-devsrc.bb
index 9fd2e08..7004261 100644
--- a/meta/recipes-kernel/linux/kernel-devsrc.bb
+++ b/meta/recipes-kernel/linux/kernel-devsrc.bb
@@ -53,6 +53,13 @@ do_install() {
          # architecture (since scripts and helpers are native format).
          KBUILD_OUTPUT="$kerneldir"
          oe_runmake -C $kerneldir CC="${KERNEL_CC}" LD="${KERNEL_LD}" clean 
_mrproper_scripts
+        # make clean generates an absolute path symlink called "source"
+        # in $kerneldir points to $kerneldir, which doesn't make any
+        # sense, so remove it.
+        if [ -L $kerneldir/source ]; then
+            bbnote "Removing $kerneldir/source symlink"
+            rm -f $kerneldir/source
+        fi

          # As of Linux kernel version 3.0.1, the clean target removes
          # arch/powerpc/lib/crtsavres.o which is present in


// Robert

>
> Bruce
>
>
>     +            rm -f $kerneldir/source
>     +        fi
>
>              # As of Linux kernel version 3.0.1, the clean target removes
>              # arch/powerpc/lib/crtsavres.o which is present in
>     --
>     2.9.0
>
>     --
>     _______________________________________________
>     Openembedded-core mailing list
>     Openembedded-core at lists.openembedded.org
>     <mailto:Openembedded-core at lists.openembedded.org>
>     http://lists.openembedded.org/mailman/listinfo/openembedded-core
>     <http://lists.openembedded.org/mailman/listinfo/openembedded-core>
>
>
>
>
> --
> "Thou shalt not follow the NULL pointer, for chaos and madness await thee at its
> end"



More information about the Openembedded-core mailing list