<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jun 21, 2017 at 8:00 AM, Heghedus Razvan <span dir="ltr">&lt;<a href="mailto:razvan.heghedus@ni.com" target="_blank">razvan.heghedus@ni.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Add possibility to set KERNEL_VERSION_PKG_NAME to a user<br>
defined value.<br>
<br>
Signed-off-by: Heghedus Razvan &lt;<a href="mailto:razvan.heghedus@ni.com" target="_blank">razvan.heghedus@ni.com</a>&gt;<br>
---<br>
 meta/classes/kernel.bbclass | 8 ++++++--<br>
 1 file changed, 6 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass<br>
index 605c101e62..02728d5a86 100644<br>
--- a/meta/classes/kernel.bbclass<br>
+++ b/meta/classes/kernel.bbclass<br>
@@ -28,12 +28,16 @@ INITRAMFS_IMAGE_BUNDLE ?= &quot;&quot;<br>
 # LINUX_VERSION which is a constant.<br>
 KERNEL_VERSION_NAME = &quot;${@d.getVar(&#39;KERNEL_VERSION&#39;) or &quot;&quot;}&quot;<br>
 KERNEL_VERSION_NAME[vardepval<wbr>ue] = &quot;${LINUX_VERSION}&quot;<br>
-KERNEL_VERSION_PKG_NAME = &quot;${@legitimize_package_name(d.<wbr>getVar(&#39;KERNEL_VERSION&#39;))}&quot;<br>
-KERNEL_VERSION_PKG_NAME[varde<wbr>pvalue] = &quot;${LINUX_VERSION}&quot;<br>
<br>
 python __anonymous () {<br>
     import re<br>
<br>
+    if d.getVar(&#39;USER_KERNEL_VERSION_<wbr>PKG&#39;) is None :<br>
+        d.setVar(&#39;KERNEL_VERSION_PKG_N<wbr>AME&#39;, &quot;${@legitimize_package_name(d.<wbr>getVar(&#39;KERNEL_VERSION&#39;))}&quot;)<br>
+        d.setVar(&#39;KERNEL_VERSION_PKG_N<wbr>AME[vardepvalue]&#39;, &quot;${LINUX_VERSION}&quot;)<br>
+    else:<br>
+        d.setVar(&#39;KERNEL_VERSION_PKG_N<wbr>AME&#39;, &quot;${@legitimize_package_name(d.<wbr>getVar(&#39;USER_KERNEL_VERSION_PK<wbr>G&#39;))}&quot;)<br></blockquote><div><br></div><div>This is introducing yet another variable that tweaks the already complex setting of</div><div>the kernel version. Not to mention this code is already touchy with respect to</div><div>parse time and rebuilding of the kernel.</div><div><br></div><div>My concern is that if this is set, we are completely disassociated with the source</div><div>code of the kernel.</div><div><br></div><div>Where did you think this would be set ? local.conf ? distro config ? somewhere else ?</div><div><br></div><div>If we had a way to simply override KERNEL_VERSION, we wouldn&#39;t need any extra</div><div>variables.</div><div><br></div><div>Bruce</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
+<br>
     # Merge KERNEL_IMAGETYPE and KERNEL_ALT_IMAGETYPE into KERNEL_IMAGETYPES<br>
     type = d.getVar(&#39;KERNEL_IMAGETYPE&#39;) or &quot;&quot;<br>
     alttype = d.getVar(&#39;KERNEL_ALT_IMAGETYPE<wbr>&#39;) or &quot;&quot;<br>
<span class="m_-3599068778944099545HOEnZb"><font color="#888888">--<br>
2.13.1<br>
<br>
--<br>
______________________________<wbr>_________________<br>
Openembedded-core mailing list<br>
<a href="mailto:Openembedded-core@lists.openembedded.org" target="_blank">Openembedded-core@lists.openem<wbr>bedded.org</a><br>
<a href="http://lists.openembedded.org/mailman/listinfo/openembedded-core" rel="noreferrer" target="_blank">http://lists.openembedded.org/<wbr>mailman/listinfo/openembedded-<wbr>core</a><br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_-3599068778944099545gmail_signature" data-smartmail="gmail_signature">&quot;Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end&quot;</div>
</div></div>