1 # Helper class for container manager config creation.
3 # - Recipe name is 'cm-config-' + <guest name>
4 # - Corresponding files {config,system.conf}.<guest name>.in are in
6 # - That references to the DRM lease device name are parameterized
7 # with @DRM_LEASE_DEVICE@ in the .in files
11 if not bpn.startswith('cm-config-'):
12 bb.error('Recipe name does not start with \'cm-config-\'')
14 d.setVar('CM_CONFIG_NAME', config)
19 DRM_LEASE_DEVICE ??= "card0-HDMI-A-1"
21 do_configure[noexec] = "1"
22 do_compile[noexec] = "1"
24 do_install:append () {
25 install -m 0755 -d ${D}/opt/container/guests/${CM_CONFIG_NAME}
26 for f in system.conf.${CM_CONFIG_NAME}.in; do
27 sed -e 's|@DRM_LEASE_DEVICE@|${DRM_LEASE_DEVICE}|g' \
28 ${WORKDIR}/$f > ${D}/opt/container/guests/${CM_CONFIG_NAME}/${f%.${CM_CONFIG_NAME}.in}
32 FILES:${PN}:append = "/opt/container/guests/${CM_CONFIG_NAME}"