<div dir="ltr">On Thu, Oct 10, 2013 at 4:31 AM, Paul Eggleton <span dir="ltr"><<a href="mailto:paul.eggleton@linux.intel.com" target="_blank">paul.eggleton@linux.intel.com</a>></span> wrote:<br><div class="gmail_extra">
<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
That's really the recommended way to do it. If the software being configured<br>
supports it, another way is to set it up to read all configuration files from a<br>
directory and then you can simply install a new file into that directory from<br>
the other recipe (e.g. Apache is usually configured to read all configuration<br>
files in /etc/httpd/conf.d or similar).<br></blockquote><div><br></div><div>Yes, I would have liked to solve the problem that way, but unfortunately the software doesn't support it, and we don't want to make changes currently. :)</div>
<div><br></div><div>I'm having a lot of trouble getting pkg_postinst() to work.  From what I've read, it should happen during rootfs generation, but I'm not see the file in the rootfs.</div><div><br></div><div>
I found an example in the <a href="http://xfce4-session_4.10.0.bb">xfce4-session_4.10.0.bb</a> recipe.  It looks like /etc/hosts is installed by netbase, so this is very similar to what my recipe is doing.</div><div><div>
# protect from frightening message that xfce might not work correctly</div><div>pkg_postinst_${PN} () {</div><div>    echo 127.0.0.1    ${MACHINE} >> /etc/hosts</div><div>}</div></div><div><br></div><div>I've tried this in my recipe, and the file that I expect to be present in the rootfs is not there...not sure what I'm doing wrong.<br>
</div><div><div>pkg_postinst_${PN} () {</div><div>    echo test >> /etc/inittest2<br></div><div>}</div></div><div><br></div><div>Also, the documentation states that this mechanism can be used to do things on first boot.  Do I need to add code to make sure that this doesn't happen on first boot?</div>
<div><br></div><div>Thanks!</div><div><br></div><div>Seth</div><div><br></div></div></div></div>