<font class="Apple-style-span" face="verdana, sans-serif"><br><br>On Tue, Aug 30, 2011 at 12:47 PM, Koen Kooi &lt;<a href="mailto:koen@dominion.thruhere.net">koen@dominion.thruhere.net</a>&gt; wrote:<br>&gt;<br>&gt; Op 30 aug. 2011, om 18:46 heeft Jason Kridner het volgende geschreven:<br>
&gt;<br>&gt;&gt; On Mon, Aug 29, 2011 at 7:08 PM, Joel A Fernandes &lt;<a href="mailto:agnel.joel@gmail.com">agnel.joel@gmail.com</a>&gt; wrote:<br>&gt;&gt;&gt; On Mon, Aug 29, 2011 at 4:03 PM, Jason Kridner &lt;<a href="mailto:jkridner@beagleboard.org">jkridner@beagleboard.org</a>&gt; wrote:<br>
&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt;&gt;&gt; This script is BSP specific and shouldn&#39;t live in the OE-core layer.<br>&gt;&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt;&gt; The only issue is this script is used from within the IMAGE_CMD_sdimg<br>
&gt;&gt;&gt;&gt;&gt;&gt; code which lives in OE-core (meta/classes/image_types.<br>&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt; classes shouldn&#39;t be calling external scripts<br>&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; Is the right approach to add parameters to the IMAGE_CMD_sdimg class<br>&gt;&gt;&gt;&gt; such that it can be used generically to produce SD card images,<br>&gt;&gt;&gt;&gt; instead of trying to move this to meta-ti?  Should it perhaps be a bit<br>
&gt;&gt;&gt;&gt; closer to what is being done by the Linaro image tools [1]?<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; [1] <a href="https://wiki.linaro.org/Source/ImageBuilding">https://wiki.linaro.org/Source/ImageBuilding</a><br>
&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;<br>&gt;&gt;&gt; Don&#39;t the Linaro scripts need to run on the target?<br>&gt;&gt;<br>&gt;&gt; No.<br>&gt;&gt;<br>&gt;&gt;&gt; Does it fit well<br>&gt;&gt;&gt; with OE(-core) ?<br>&gt;&gt;<br>
&gt;&gt; I don&#39;t know, but I hoped that others would comment to help figure it<br>&gt;&gt; out.  I think it is a common challenge not just for ARM architectures.<br>&gt;&gt; I&#39;m not sure if the approach is general enough or not, but it does go<br>
&gt;&gt; beyond the BeagleBoard.<br>&gt;&gt;<br>&gt;&gt; My primary concerns about leaving it in the BSP are:<br>&gt;&gt; 1) that there is some room for non-BeagleBoard specific optimizations<br>&gt;&gt; to the card layout and<br>
&gt;&gt; 2) there may be improvements to the tools that make it easier to<br>&gt;&gt; create images for systems with different boot requirements.<br>&gt;&gt;<br>&gt;&gt; Also, I think we might want to move to an ext3 partition only in the<br>
&gt;&gt; future or other such layout optimizations.  I&#39;d like that to be<br>&gt;&gt; something that can be parameterized by the BSP.<br>&gt;<br>&gt; I think you&#39;re missing the point:<br>&gt;<br>&gt; The *script* needs to go into the BSP, you are free to extend the bbclasses with code to deal with sd cards internally in OE-core.<br>
&gt;<br>&gt;<br><br>Hi Koen,<br><br>Can you suggest how we proceed with extending the bbclass?<br><br>I have tried both .bbappend and BBCLASSEXTEND and didn&#39;t get it to work.<br><br>I could create a new class and inherit the oe-core one from it with tweaks.</font><div>
<font class="Apple-style-span" face="verdana, sans-serif"><br></font></div><div><font class="Apple-style-span" face="verdana, sans-serif">Here is complete IRC discussion between me and bluelightning on the reasoning to extend the image.bbclass:<br>
<br>* cminyard (~<a href="mailto:cminyard@pool-173-57-155-71.dllstx.fios.verizon.net">cminyard@pool-173-57-155-71.dllstx.fios.verizon.net</a>) has joined #oe<br>&lt;joelagnel&gt; I&#39;d like to extend a bbclass in oe-core with tweaks in another layer<br>
&lt;joelagnel&gt; What is the right way to do so? .bbappend ? BBCLASSEXTEND?<br>&lt;GNUtoo|work&gt; JaMa|Wrk, btw I&#39;ve also another patch:<br>&lt;GNUtoo|work&gt; at eukrea we use ubifs, and had the exact same issue than the freerunner ubifs issue, at least it seems<br>
&lt;GNUtoo|work&gt; we fixed it<br>&lt;GNUtoo|work&gt; so if the patch arrived, it should fix it for you too<br>&lt;GNUtoo|work&gt; joelagnel, BBCLASSEXTEND seem for recipes<br>&lt;joelagnel&gt; I&#39;ve seen it for classes in meta-oe:<br>
&lt;joelagnel&gt; ../meta-openembedded/meta-oe/classes/gnome.bbclass:BBCLASSEXTEND += &quot;native&quot;<br>&lt;joelagnel&gt; GNUtoo|work, but it doesn&#39;t do what I want<br>&lt;joelagnel&gt; I can create a new class, inherit from the oe-core one and put my code there, but I think that&#39;ll get rejected ;)<br>
&lt;GNUtoo|work&gt; ok<br>&lt;GNUtoo|work&gt; maybe ask in the list<br>&lt;joelagnel&gt; everyone here on long weekend holiday? ;)<br>* hollisb (~<a href="mailto:hollisb@c-24-20-193-174.hsd1.or.comcast.net">hollisb@c-24-20-193-174.hsd1.or.comcast.net</a>) has joined #oe<br>
&lt;bluelightning&gt; joelagnel: I don&#39;t think bbclassextend is what you want<br>&lt;bluelightning&gt; what tweaks do you want to apply?<br>&lt;joelagnel&gt; bluelightning, can I name a class in an upper layer with the same filename as that of a lower layer, and still be able to inherit the lower layer one?<br>
&lt;bluelightning&gt; I don&#39;t think you can do it that way no<br>&lt;bluelightning&gt; if it&#39;s the same name it will just replace it effectively<br>&lt;bluelightning&gt; the most likely result in that case is you&#39;ll get a circular reference<br>
&lt;joelagnel&gt; BlindMan, there was some talk about moving my changes (IMAGE_CMD_sdimg) to the bsp layer<br>&lt;joelagnel&gt; <a href="https://github.com/joelagnel/oe-core/blob/db4c960da57e8e0ae4741eea703a4e163c589efa/meta/classes/image_types.bbclass">https://github.com/joelagnel/oe-core/blob/db4c960da57e8e0ae4741eea703a4e163c589efa/meta/classes/image_types.bbclass</a><br>
&lt;joelagnel&gt; sorry I meant bluelightning ;)<br>&lt;joelagnel&gt; need coffee!!! :-D<br>&lt;joelagnel&gt; and need .bbclassappend ;)<br>* msm (~<a href="mailto:msm@192.88.168.35">msm@192.88.168.35</a>) has joined #oe<br>
&lt;bluelightning&gt; hmm; this is an interesting one<br>&lt;bluelightning&gt; I recall the discussion on the mailing list... I do wonder whether we ought to try to find a way to get this into oe-core itself<br>* phdeswer has quit (Ping timeout: 276 seconds)<br>
&lt;joelagnel&gt; bluelightning, I&#39;m copying in a ubi file into the rootfs which I don&#39;t think is generic enough<br>&lt;joelagnel&gt; also all sorts of assumptions are made about bootloader file names (U-boot, uEnv, user.txt) etc<br>
&lt;bluelightning&gt; hmm<br>&lt;bluelightning&gt; is this only likely to be applicable to one machine then?<br>&lt;joelagnel&gt; bluelightning, yeah. specially the bootloader environment files etc make assumptions about the machine (i2c bus names etc)<br>
&lt;joelagnel&gt; bluelightning, also Richard was suggesting that this was attempted before but requires special mounts etc which is true<br>&lt;joelagnel&gt; we need it in there though so we could move it to the bsp for now<br>
&lt;joelagnel&gt; sounds good?<br>* Hoolxi (~<a href="mailto:Openfree@124.78.96.197">Openfree@124.78.96.197</a>) has joined #oe<br>&lt;bluelightning&gt; joelagnel: well as a temporary measure but really duplicating class files is worth avoiding<br>
&lt;bluelightning&gt; just because of the pain of keeping it up-to-date<br>&lt;joelagnel&gt; sure<br>&lt;bluelightning&gt; I have to admit I&#39;m unsure of the correct solution in this case though<br>&lt;bluelightning&gt; it&#39;s worth trying to coax people on the mailing list to come up with the right answer :)<br>
&lt;joelagnel&gt; bluelightning, sure will do ,thanks :)</font><br></div><div><font class="Apple-style-span" face="verdana, sans-serif"><br></font></div><div><font class="Apple-style-span" face="verdana, sans-serif"><br></font></div>
<div><font class="Apple-style-span" face="verdana, sans-serif">Thanks,</font></div><div><font class="Apple-style-span" face="verdana, sans-serif">Joel</font></div>