[oe] [PATCH] Allow spectrum fw to build behind a proxy
Martyn Welch
martyn.welch at ge.com
Wed Mar 10 10:31:34 UTC 2010
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 at ge.com>
---
recipes/orinoco/spectrum-fw.bb | 1 +
recipes/orinoco/spectrum-fw/get_symbol_fw | 9 +++++++--
2 files changed, 8 insertions(+), 2 deletions(-)
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
--
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 at ge.com | M2 3AB VAT:GB 927559189
More information about the Openembedded-devel
mailing list