[oe] Inheriting conditionally

Matt Hoosier matt.hoosier at gmail.com
Wed Aug 8 13:20:24 UTC 2007


On 8/8/07, Richard Purdie <rpurdie at rpsys.net> wrote:
> I can't think of a way to do this 100% neatly, the following is my best
> idea:
>
> SYSTEMWIDEDAEMON = "dummy"
> SYSTEMWIDEDAEMON_mydistro = "myspecialclass"
>
> inherit ${SYSTEMWIDEDAEMON}
>
> The ugly bit is it needs an empty dummy.bbclass.
>
> A quick test here suggests it might be harmless to use "base" there
> since base will always have already been included...
>

Thanks. I also got the "bright" idea to install a dummy init script
for any distribution other than mine:

do_install () {

  ...

  install -d -m 0755 ${D}${sysconfdir}/init.d
  if [ "${DISTRO}" = "foinse" ] ; then
      install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/pulseaudio
  else
      echo "#! /bin/sh" > ${D}${sysconfdir}/init.d/pulseaudio
      chmod 0755 ${D}${sysconfdir}/init.d/pulseaudio
  fi
}




More information about the Openembedded-devel mailing list