<?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>6659</bug_id>
          
          <creation_ts>2014-08-24 18:51:54 +0000</creation_ts>
          <short_desc>Add new SDK publishing tool</short_desc>
          <delta_ts>2016-06-20 13:32:27 +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>devtools / tool chain</component>
          <version>1.7</version>
          <rep_platform>All</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>enhancement</bug_severity>
          <target_milestone>2.0</target_milestone>
          <dependson>6559</dependson>
          <blocked>6660</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Paul Eggleton">bluelightning</reporter>
          <assigned_to name="Chen Qi">Qi.Chen</assigned_to>
          <cc>alexandru.c.georgescu</cc>
    
    <cc>bash65</cc>
    
    <cc>bluelightning</cc>
    
    <cc>bogdanx.a.voiculescu</cc>
    
    <cc>costin.c.constantin</cc>
    
    <cc>jose.perez.carranza</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>Qi.Chen</cc>
          
          <qa_contact name="Francisco Pedraza">francisco.j.pedraza.gonzalez</qa_contact>
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>Yes (doc changes required)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>45239</commentid>
    <comment_count>0</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2014-08-24 18:51:54 +0000</bug_when>
    <thetext>Add a tool to help with publishing the new SDK, including the SDK installer, manifest and corresponding sstate artifacts, where &quot;publishing&quot; just means copying the files from their output locations in DEPLOY_DIR / SSTATEDIR to a separate directory. The tool should compare the current SDK with the last published one, display the differences and then confirm before publishing the SDK.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>51248</commentid>
    <comment_count>1</comment_count>
    <who name="Chen Qi">Qi.Chen</who>
    <bug_when>2015-05-26 08:39:07 +0000</bug_when>
    <thetext>devtool sdk-publish &lt;sdk_to_publish&gt; &lt;destination_of_the_published_sdk&gt;

Hi, Paul, is it something like the above?

Below are some details I&apos;m think about. Please let me know your opinions. Thanks.

For the destination, it should support both a local destination and a remote ssh destination.

For the published SDK, as long as it&apos;s an extensible SDK, it should be valid.

For now, the SDK installer doesn&apos;t contain any manifest file. The manifest files are generated while preparing the build system at SDK installation time. My question is, should we copy necessary manifest files into the SDK at construction time?

//Chen Qi</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>51252</commentid>
    <comment_count>2</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2015-05-26 09:03:24 +0000</bug_when>
    <thetext>I don&apos;t think it would be a part of devtool - it&apos;s something that would be a separate script. Otherwise the syntax would be pretty much as you describe yes.

Local and remote support sounds like a good idea yes.

Regarding the manifest, we will need to extend what&apos;s written into the SDK at construction time yes - what we do there will really be to support the update mechanism under bug 6560.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54040</commentid>
    <comment_count>3</comment_count>
    <who name="Chen Qi">Qi.Chen</who>
    <bug_when>2015-09-15 02:30:25 +0000</bug_when>
    <thetext>Module: openembedded-core.git
Branch: master
Commit: c201ab826046b30281341107b3e6a35204f5c9d8
URL:    http://git.openembedded.org/?p=openembedded-core.git&amp;a=commit;h=c201ab826046b30281341107b3e6a35204f5c9d8

Author: Qi.Chen@windriver.com &lt;Qi.Chen@windriver.com&gt;
Date:   Mon Sep  7 13:42:26 2015 +0100

oe-publish-sdk: add script

Add a script to publish an extensible SDK that has previously been built
to a specified destination. This published SDK is intended to be
accessed by the devtool sdk-update command from an installed copy of the
extensible SDK.

e.g.
oe-publish-sdk &lt;ext-sdk&gt; &lt;destination&gt;

Signed-off-by: Chen Qi &lt;Qi.Chen@windriver.com&gt;
Signed-off-by: Paul Eggleton &lt;paul.eggleton@linux.intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55600</commentid>
    <comment_count>4</comment_count>
    <who name="Costin">costin.c.constantin</who>
    <bug_when>2015-10-22 13:56:27 +0000</bug_when>
    <thetext>Hello,

Tested this feature on latest master 505a82673ac2487df5ea343a6422c2fc47018831 on an Ubuntu machine.

Steps performed:
1) ensure a clean env. (i cloned a fresh poky)
2) set machine to one desired BSP in local.conf (I chose genericx86)
3) populate sdk:
bitbake core-image-minimal -c populate_sdk
4) oe-publish-sdk tmp/deploy/sdk/poky-glibc-x86_64-core-image-minimal-core2-32-toolchain-2.0.sh /tmp/pk/sdk
5) view results:
:/tmp/pk/sdk$ ls
environment-setup-core2-32-poky-linux  poky-glibc-x86_64-core-image-minimal-core2-32-toolchain-2.0.sh  sysroots
layers                                 site-config-core2-32-poky-linux                                 version-core2-32-poky-linux


I encountered a small issue here:
/bin/sh: 1: cd: can&apos;t cd to /tmp/pk/sdk/layers
ERROR: Failed to set up layer git repo
Managed to solve it by firstly creating the respective dir:

diff --git a/scripts/oe-publish-sdk b/scripts/oe-publish-sdk
index 1737c9f..c4c35bd 100755
--- a/scripts/oe-publish-sdk
+++ b/scripts/oe-publish-sdk
@@ -101,9 +101,9 @@ def publish(args):
 
     # Setting up the git repo
     if not is_remote:
-        cmd = &apos;set -e; cd %s/layers; if [ ! -e .git ]; ...
+        cmd = &apos;set -e; mkdir -p %s/layers; cd %s/layers; if [ ! -e .git ]; ...
     else:
-        cmd = &quot;ssh %s &apos;set -e; cd %s/layers; if [ ! -e .git ]; ...
+        cmd = &quot;ssh %s &apos;set -e; mkdir-p %s/layers; cd %s/layers; if [ ! -e .git ]; ...

Will submit a patch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55601</commentid>
    <comment_count>5</comment_count>
    <who name="Costin">costin.c.constantin</who>
    <bug_when>2015-10-22 13:57:17 +0000</bug_when>
    <thetext>awaiting for patch validation</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55603</commentid>
    <comment_count>6</comment_count>
    <who name="Costin">costin.c.constantin</who>
    <bug_when>2015-10-22 14:13:14 +0000</bug_when>
    <thetext>Also would like to add the &quot;Documentation change:&quot; is marked, but couldn&apos;t find anything related in mega manual</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55803</commentid>
    <comment_count>7</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2015-10-27 10:01:37 +0000</bug_when>
    <thetext>Costin&apos;s fix merged to master:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=369c53600e3faafa0111a8563af36ee46443d750

Yes, we did not have time unfortunately to provide documentation for this feature. We&apos;ll have to get to it early in the next release cycle.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>58775</commentid>
    <comment_count>8</comment_count>
    <who name="Costin">costin.c.constantin</who>
    <bug_when>2016-02-09 06:48:28 +0000</bug_when>
    <thetext>Hi Paul, 

Please let me know if you have an estimate when the documentation will be updated for this feature in order to mark it as verified.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>58776</commentid>
    <comment_count>9</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2016-02-09 07:20:34 +0000</bug_when>
    <thetext>It&apos;s a few weeks away yet - Scott and I are still only properly documenting basic devtool functionality at the moment.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>