anchor.diff:  
   FILES_${PN} += " \
       ${libdir}/ctapi \
  -    ${nonarch_base_libdir}/udev \
  +    ${nonarch_libdir}/udev \
       ${libdir}/openct-ifd.so \
       ${libdir}/pcsc \
   "
  
positive.code: 
  INSANE_SKIP_${PN} += "dev-deps"
  
  do_install () {
      rm -rf ${D}
      install -d ${D}/etc
      install -dm 755 ${D}${nonarch_base_libdir}/udev
      # fix up hardcoded paths
      sed -i -e 's,/etc/,${sysconfdir}/,' -e 's,/usr/sbin/,${sbindir}/,' \
          ${WORKDIR}/openct.service ${WORKDIR}/openct.init
  
negative.code:     oe_runmake install DESTDIR=${D}
      install -dm 755 ${D}${libdir}/ctapi/
      mv ${D}${libdir}/libopenctapi.so ${D}${libdir}/ctapi/
      install -Dpm 644 etc/openct.udev ${D}${nonarch_libdir}/udev/rules.d/60-openct.rules
      install -pm 644 etc/openct.conf ${D}${sysconfdir}/openct.conf
  
      install -Dpm 755 ${WORKDIR}/openct.init ${D}${sysconfdir}/init.d/openct
      install -Dpm 644 ${WORKDIR}/openct.sysconfig ${D}${sysconfdir}/sysconfig/openct
  
      install -d ${D}${systemd_unitdir}/system
      install -m 644 ${WORKDIR}/openct.service ${D}${systemd_unitdir}/system
  
      so=$(find ${D} -name \*.so | sed "s|^${D}||")
      sed -i -e 's|\\(LIBPATH\\s*\\).*|\\1$so|' etc/reader.conf
      install -Dpm 644 etc/reader.conf ${D}${sysconfdir}/reader.conf.d/openct.conf
  }
  