I have been trying to create a recipe for an init script so that I can
start a program at Angstrom start up, but have been having trouble
thus far. I have created a script that does the job, but I have been
having trouble packaging it using bitbake and I could use some help.
Right now I can place the g7start (my init script) file in the /etc/
init.d folder followed by "update-rc.d defaults" to get everything
working. I want to automate it by making a .bb file to automatically
install the file and run the command. I haven't made many BB recipes
so I need help with syntax and whatnot, but have been having trouble
getting it working despite Google and other means. Could someone tell
me where I am going wrong?
Thanks!
Here is the tree:
.../recipes
|-- ...
|-- g7start
|-- files
| `-- init-g7
`--
g7start_1.0.0.bb
init-g7 is my init script that is to be installed as /etc/init.d/
g7start
Bitbake tells me that /etc/init.d/g7start was not shipped in any
package despite the fact that I have it listed in FILES_g7start
My bitbake recipe named
g7start_1.0.0.bb was modeled after parts of
dhcp_3.0.2.bb:
DESCRIPTION = "g7server Initialization"
PR = "r0"
SRC_URI = "file://init-g7"
inherit update-rc.d
INITSCRIPT_PACKAGES = "g7start"
INITSCRIPT_NAME_g7start = g7start
INITSCRIPT_PARAMS_g7start = "start 32 2 3 4 5 . stop 32 0 1 6 ."
do_install() {
install -d ${D}${sysconfdir}/init.d
install -m 0755 ${WORKDIR}/init-g7 ${D}${sysconfdir}/init.d/
g7start
}
PACKAGES = "g7start"
FILES_${PN} = ""
FILES_g7start = "${sysconfdir}/init.d/g7start"