[poky] Add single user
Gary Thomas
gary at mlbassoc.com
Fri Oct 11 04:23:42 PDT 2013
On 2013-10-10 16:06, Michael Davis wrote:
> I am attempting to add a single user to my poky build. I am trying to follow the useradd-example.bb layout but I cannot get bitbake to like it. My bb file looks like so:
>
> SUMMARY = "Add a user"
>
> DESCRIPTION = "This recipe will add a new user"
>
> PR = "r0"
>
> LICENSE = "MIT"
>
> LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
>
> S = "${WORKDIR}"
>
> inherit useradd
>
> USERADD_PACKAGES = "${PN}"
>
> USERADD_PARAM_${PN} = "--disabled-password hal"
>
> do_install () {
>
> chown -R hal ${D}${datadir}/hal
>
> }
>
> FILES_${PN} = "${datadir}/hal/*"
>
> I have the useradd package specified as a dependency for a package group which I am installing for my image. When I bake, it attempts do_rootfs but fails and spits out a huge log
> after which it simple states that it couldn’t satisfy dependencies for my package group and and points the the useradd package. Is there any obvious reason why such a simple
> recipe like this would not work? Thanks
Your package is empty since the install step is not quite correct.
Try adding this line before 'chown'
install -d ${D}${datadir}/hal
Also, I think you may need this:
FILES_${PN} = "${datadir}/hal /home/hal"
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
More information about the poky
mailing list