<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>12630</bug_id>
          
          <creation_ts>2018-03-28 06:38:25 +0000</creation_ts>
          <short_desc>postinst intercepts fail in SDKs</short_desc>
          <delta_ts>2018-04-05 09:17:18 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>deployment</component>
          <version>2.5</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.5 M4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ross Burton">ross.burton</reporter>
          <assigned_to name="Alexander Kanavin">alex.kanavin</assigned_to>
          <cc>randy.macleod</cc>
    
    <cc>stephano</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>80003</commentid>
    <comment_count>0</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2018-03-28 06:38:25 +0000</bug_when>
    <thetext>If a SDK needs to run a postinst intercept, be it in the target sysroot or the nativesdk sysroot, it will fail.

This is simply because we don&apos;t set INTERCEPT_DIR or run the intercepts, because those are actions that rootfs.py takes, whereas the sdk (sdk.py) uses the package managers directly.

We should probably move the intercept logic somewhere common like package_manager.py, so the sdk code can reuse it.

poky-contrib:ross/interceptargh has a vague attempt at copy/paste which doesn&apos;t work (conflating host and target intercepts) which may be interesting as an example of what not to do.

Reproducer:

CORE_IMAGE_EXTRA_INSTALL_append = &quot; glib-networking&quot;
$ bitbake core-image-minimal -c populate_sdk</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>80073</commentid>
    <comment_count>1</comment_count>
    <who name="Alexander Kanavin">alex.kanavin</who>
    <bug_when>2018-04-03 08:52:44 +0000</bug_when>
    <thetext>Patchset posted to list. I took the opportunity to clean up some of the other related things with postinsts, postinsts intercepts and SDKs :)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>80134</commentid>
    <comment_count>2</comment_count>
    <who name="Alexander Kanavin">alex.kanavin</who>
    <bug_when>2018-04-05 09:17:18 +0000</bug_when>
    <thetext>Fix is in master:
http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=e4b8c2bd20d1472f93c42dff564b5eeb478b1f8f</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>