| Submitter | Martyn Welch |
|---|---|
| Date | 2010-03-10 10:31:34 |
| Message ID | <20100310103133.14548.62608.stgit@ES-J7S4D2J.amer.consind.ge.com> |
| Download | mbox | patch |
| Permalink | /patch/1677/ |
| State | Superseded, archived |
| Headers | show |
Comments
On Wed, 2010-03-10 at 10:31 +0000, Martyn Welch wrote: > Spectrum-fw runs a script which uses curl, wget or ftp to pull an archive > rather than the archive being a part of the SRC_URI. Whilst it would > probably be preferable to pull this as part of the SRC_URI (incidentally, > if it was, the script wouldn't need to be modified), the "&" in the archive > name has foiled my attempts at doing that. > > This patch modifies the script to at least use the "FETCHCMD_wget" variable > which can be provided to help when accessing through a proxy. How about the recipe in Poky for this (meta/packages/orinoco/spectrum-fw.bb)? I think all these problems were addressed there. Cheers, Richard
Richard Purdie wrote: > On Wed, 2010-03-10 at 10:31 +0000, Martyn Welch wrote: > >> Spectrum-fw runs a script which uses curl, wget or ftp to pull an archive >> rather than the archive being a part of the SRC_URI. Whilst it would >> probably be preferable to pull this as part of the SRC_URI (incidentally, >> if it was, the script wouldn't need to be modified), the "&" in the archive >> name has foiled my attempts at doing that. >> >> This patch modifies the script to at least use the "FETCHCMD_wget" variable >> which can be provided to help when accessing through a proxy. >> > > How about the recipe in Poky for this > (meta/packages/orinoco/spectrum-fw.bb)? I think all these problems were > addressed there. > I tried exactly that first, wget keeps trying to download: "ftp://symstore.longisland.com/Symstore/services_download/wirless_prod/MC" not: "ftp://symstore.longisland.com/Symstore/services_download/wirless_prod/MC&DriverOnlyInstallers.zip" Has Bitbake been patched up in poky to handle "&" differently? Martyn
On Fri, 2010-03-12 at 09:00 +0000, Martyn Welch wrote: > Richard Purdie wrote: > > How about the recipe in Poky for this > > (meta/packages/orinoco/spectrum-fw.bb)? I think all these problems were > > addressed there. > > > I tried exactly that first, wget keeps trying to download: > > "ftp://symstore.longisland.com/Symstore/services_download/wirless_prod/MC" > > not: > > "ftp://symstore.longisland.com/Symstore/services_download/wirless_prod/MC&DriverOnlyInstallers.zip" > > Has Bitbake been patched up in poky to handle "&" differently? Ah, I remember this now. It is not a bitbake bug put a base.bbclass bug as something somewhere has incorrect quoting. Its been fixed in Poky but probably should be pushed into OE too. If you find the commit where I last touched the spectrum-fw driver you'll find the core class change too I suspect. It'd be good to get synced up on that. Cheers, Richard
Patch
diff --git a/recipes/orinoco/spectrum-fw.bb b/recipes/orinoco/spectrum-fw.bb index cedb0e3..0128115 100644 --- a/recipes/orinoco/spectrum-fw.bb +++ b/recipes/orinoco/spectrum-fw.bb @@ -8,6 +8,7 @@ SRC_URI = "file://get_symbol_fw \ S = "${WORKDIR}" do_configure() { + export FETCHCMD_wget="${FETCHCMD_wget}"; ./get_symbol_fw } diff --git a/recipes/orinoco/spectrum-fw/get_symbol_fw b/recipes/orinoco/spectrum-fw/get_symbol_fw index e7b0bf2..b15a60c 100755 --- a/recipes/orinoco/spectrum-fw/get_symbol_fw +++ b/recipes/orinoco/spectrum-fw/get_symbol_fw @@ -23,8 +23,13 @@ DRIVER1=symbol1.drv DRIVER2=symbol2.drv get_file() { + if [ "${FETCHCMD_wget}" == "" ] + then + FETCHCMD_wget="wget --passive-ftp" + fi + curl --remote-name "$1" || \ - wget --passive-ftp "$1" || \ + ${FETCHCMD_wget} "$1" || \ wget "$1" || \ ftp "$1" </dev/null || \ exit 1 @@ -40,4 +45,4 @@ unzip -p $DRIVER1 "$DL_INT2" >$DRIVER2 perl parse_symbol_fw $DRIVER2 spectrum_fw.h symbol_sp24t_prim_fw \ symbol_sp24t_sec_fw -rm -f $DRIVER1 $DRIVER2 \ No newline at end of file +rm -f $DRIVER1 $DRIVER2
Spectrum-fw runs a script which uses curl, wget or ftp to pull an archive rather than the archive being a part of the SRC_URI. Whilst it would probably be preferable to pull this as part of the SRC_URI (incidentally, if it was, the script wouldn't need to be modified), the "&" in the archive name has foiled my attempts at doing that. This patch modifies the script to at least use the "FETCHCMD_wget" variable which can be provided to help when accessing through a proxy. Signed-off-by: Martyn Welch <martyn.welch@ge.com> --- recipes/orinoco/spectrum-fw.bb | 1 + recipes/orinoco/spectrum-fw/get_symbol_fw | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) -- Martyn Welch (Principal Software Engineer) | Registered in England and GE Intelligent Platforms | Wales (3828642) at 100 T +44(0)127322748 | Barbirolli Square, Manchester, E martyn.welch@ge.com | M2 3AB VAT:GB 927559189