<?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>3119</bug_id>
          
          <creation_ts>2012-09-14 16:17:28 +0000</creation_ts>
          <short_desc>Beta - default sanity checking fails if http proxy set but not git / SVN</short_desc>
          <delta_ts>2012-10-02 22:52:15 +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>BitBake</product>
          <component>bitbake</component>
          <version>1.3</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>major</bug_severity>
          <target_milestone>1.3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Dave Stewart">david.c.stewart</reporter>
          <assigned_to name="Paul Eggleton">bluelightning</assigned_to>
          <cc>andy.ross</cc>
    
    <cc>bluelightning</cc>
    
    <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>sgw</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>---</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>25285</commentid>
    <comment_count>0</comment_count>
    <who name="Dave Stewart">david.c.stewart</who>
    <bug_when>2012-09-14 16:17:28 +0000</bug_when>
    <thetext>I have my http and https proxies set and do 

$ bitbake -k core-image-sato

If you have your http proxy set correctly, we&apos;re supposed to default over to the mirrors. But there are two problems with this now:

1. The sanity test at the beginning fails because git isn&apos;t working.

2. When building eglibc, the do_fetch fails because svn is not accessible.

So the out-of-box experience with the command line isn&apos;t working as expected.

believe RP sent mail to the poky list about this behavior and I have not seen a reply.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>25287</commentid>
    <comment_count>1</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2012-09-14 16:30:35 +0000</bug_when>
    <thetext>The questions:

a) Do we add an svn sanity check?
b) Do we remove the git sanity check instead?
c) Why didn&apos;t the svn tarball come from the mirror? svn shouldn&apos;t have been necessary.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>25372</commentid>
    <comment_count>2</comment_count>
    <who name="Andy Ross">andy.ross</who>
    <bug_when>2012-09-18 17:51:48 +0000</bug_when>
    <thetext>I just hit what I assume is the same issue and was pointed here from #yocto.

What&apos;s happened is that the downloads.yoctoproject.org/mirrors/sources directory doesn&apos;t have a current mirror of the eglibc source code. The most recent svn revision it has is &quot;19383&quot;, but yocto commits 91746bab and 5b8e46db have since bumped that revision to &quot;19922&quot; and then &quot;20393&quot;.

So the build doesn&apos;t see a working mirror and tries to get the source from upstream.  But www.eglibc.org is unusably slow -- I can&apos;t seem to get a transfer rate of more than 1-200kbps ever, and over a day and a half of build attempts I haven&apos;t gotten through a working download. It uniformly fails with a timeout after a few hours.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>25707</commentid>
    <comment_count>3</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2012-09-25 15:47:50 +0000</bug_when>
    <thetext>Michael &amp; Beth have fixed the mirroring so we have up-to-date mirrors for eglibc, and I&apos;ve verified that the fetch from the mirror now works.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26060</commentid>
    <comment_count>4</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2012-10-02 16:56:48 +0000</bug_when>
    <thetext>Richard has now dropped the Git check as it only gets in the way rather than helping the uninitiated user as was originally intended:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=029a74407836390acc29201309130e3860caf072

I think that means we can resolve this bug as the two issues mentioned are now addressed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26063</commentid>
    <comment_count>5</comment_count>
    <who name="Evadeflow">evadeflow</who>
    <bug_when>2012-10-02 17:40:16 +0000</bug_when>
    <thetext>I may have been bitten by this (or Bug 3175, not sure whether they&apos;re the same). I&apos;m an inexperienced Yocto Project user trying hard to evolve into an experienced one, but my edit/run/debug cycle is really crippled by the restrictive firewall at work. I have 16 cores at my disposal there, but the machine they&apos;re in can only access the Internet via an HTTP proxy.  I have this in my .gitconfig:

&gt; [http]
&gt;     proxy=http://user:passwd@usaprox.lightning.com:8080

so you&apos;d think I&apos;d be able to access URLs like this one (from the meta-ti layer&apos;s linux-omap4_3.1.0.bb recipe):

&gt; SRC_URI = &quot;http://dev.omapzoom.org/pub/scm/integration/kernel-ubuntu.git;protocol=git;branch=ti-ubuntu-3.1-1282 \
&gt;            file://0001-Makefile.fwinst-fix-install-breakage-for-FW-images-r.patch \
&gt;            file://defconfig \
&gt;            &quot;

But, from what I can tell, bitbake never tries to fetch this, and the error I wind up getting isn&apos;t particularly helpful:

&gt; ERROR: Command Error: exit status: 1  Output:
&gt; Applying patch 0001-Makefile.fwinst-fix-install-breakage-for-FW-images-r.patch
&gt; patching file scripts/Makefile.fwinst
&gt; Hunk #1 FAILED at 27.
&gt; 1 out of 1 hunk FAILED -- rejects in file scripts/Makefile.fwinst
&gt; Patch 0001-Makefile.fwinst-fix-install-breakage-for-FW-images-r.patch does not apply (enforce with -f)
&gt; ERROR: Function failed: patch_do_patch


What&apos;s really frustrating is that I did a fetchall offsite into a mirrors folder on a USB hard drive, and then rsync&apos;ed that folder to the build server at work. Not only did I do &apos;fetchall core-image-sato&apos; and &apos;fetchall core-image-minimal&apos;, but I also did &apos;fetchall universe&apos; for good measure. Bitbake still decided, once behind the firewall, &quot;Oh, yeah---I&apos;m gonna need one more thing.&quot; (I&apos;m learning that Bitbake can be kind of a jerk that way.)

Here&apos;s my build configuration:


&gt; OE Build Configuration:
&gt; BB_VERSION        = &quot;1.15.2&quot;
&gt; TARGET_ARCH       = &quot;arm&quot;
&gt; TARGET_OS         = &quot;linux-gnueabi&quot;
&gt; MACHINE           = &quot;pandaboard&quot;
&gt; DISTRO            = &quot;poky&quot;
&gt; DISTRO_VERSION    = &quot;1.2.1&quot;
&gt; TUNE_FEATURES     = &quot;armv7a vfp neon cortexa9&quot;
&gt; TARGET_FPU        = &quot;vfp-neon&quot;
&gt; meta
&gt; meta-yocto        = &quot;denzil:65ffa7395055f7e012cb973f63f92380828eed0d&quot;
&gt; meta-ti           = &quot;(nobranch):30fb40ebc13614a74c2e237927c60ac43e01d1bc&quot;


Maybe some of this stuff has been fixed already, I&apos;m just relaying my experience as a new user. So far, it seems very, very difficult to either:

1) Get Bitbake to pull everything via HTTP
2) Set up a *complete* mirror in one go

I can understand #1, but #2 is vexing. I&apos;ve made a dozen trips to the local public library to download just &quot;one more package&quot; to my mirror. I&apos;ve considered writing a python script to go get all of the resources specified in *every single SRC_URI* in my Yocto tree, but then I thought: how silly is that? Bitbake knows about all of these, and it&apos;s written in python! Why can&apos;t it do this for me?

So, I guess that&apos;s a feature request for 1.4: add a command to Bitbake that&apos;s like &apos;fetchall&apos;, but actually fetches EVERYTHING, and builds NOTHING. (The current &apos;fetchall&apos; command actually builds quite a lot before downloading anything.)  I&apos;m not sure what to call such a command, maybe something like &quot;Hey, I&apos;m gonna be behind a Draconian firewall later today and I need you to download EVERY SINGLE RESOURCE required to build any of the images this build tree can possibly build, right now, while I&apos;m connected to the Internet. Okay, Bitbake?&quot;

Here are my mods to conf/local.conf, in case it&apos;s helpful:

&gt; MACHINE = &quot;pandaboard&quot;
&gt; BBMASK = &quot;meta-ti/recipes-misc&quot;
&gt; PACKAGE_CLASSES = &quot;package_ipk&quot;
&gt; CONNECTIVITY_CHECK_URIS=&quot;&quot;
&gt; BB_GENERATE_MIRROR_TARBALLS = &quot;1&quot; 
&gt; SOURCE_MIRROR_URL ?= &quot;file:///home/evadeflow/projects/poky-mirror/&quot;
&gt; INHERIT += &quot;own-mirrors&quot;

And this is my bblayers.conf:

&gt; # LAYER_CONF_VERSION is increased each time build/conf/bblayers.conf
&gt; # changes incompatibly
&gt; LCONF_VERSION = &quot;4&quot;
&gt; 
&gt; BBFILES ?= &quot;&quot;
&gt; BBLAYERS ?= &quot; \
&gt;   /home/dwolfe/projects/poky-git/meta \
&gt;   /home/dwolfe/projects/poky-git/meta-yocto \
&gt;   /home/dwolfe/projects/poky-git/meta-ti \
&gt;   &quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26085</commentid>
    <comment_count>6</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2012-10-02 22:52:15 +0000</bug_when>
    <thetext>So, a few notes in response:

1) The SRC_URI in the linux-omap recipe you quote is at least slightly if not completely wrong. From the suffix it looks like a git URI except bitbake will treat it as a standard http download because of the http:// prefix. Maybe that is the correct thing for fetching the source for this recipe, but I doubt it - if it&apos;s intended to fetch from a git repository, it needs to start with git:// even if you later specify protocol=http to use the http transport. If on the other hand the URI uses protocol=git it probably won&apos;t be fetchable at all from behind a firewall without a git proxy set up.

2) Unless something very very wrong is going on, the error you are indicating is an error from do_patch, not do_fetch (hence the error mentioning patch application failure). If the URI is broken as I mentioned above, I&apos;m not surprised the patch would fail to apply though as it won&apos;t have actually downloaded the kernel source.

3) We can&apos;t do a fetchall without building anything because we need to build some of the tools needed to do the fetching. fetchall should fetch everything needed to build whatever target you specify; if it does not that is a bug, but you didn&apos;t mention which item actually didn&apos;t get fetched assuming it was something other than the situation above...?

If there are still bugs by all means open up a new bug report with details and we&apos;ll investigate. Rest assured that what you are trying to do - i.e. create a local source mirror and then make that available to a machine without network access - is a fairly common use case and is supported.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>