diff options
Diffstat (limited to 'bitbake')
-rw-r--r-- | bitbake/lib/bb/fetch2/__init__.py | 46 |
1 files changed, 24 insertions, 22 deletions
diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py index ad898680ff..914fa5c024 100644 --- a/bitbake/lib/bb/fetch2/__init__.py +++ b/bitbake/lib/bb/fetch2/__init__.py | |||
@@ -808,6 +808,29 @@ def localpath(url, d): | |||
808 | fetcher = bb.fetch2.Fetch([url], d) | 808 | fetcher = bb.fetch2.Fetch([url], d) |
809 | return fetcher.localpath(url) | 809 | return fetcher.localpath(url) |
810 | 810 | ||
811 | # Need to export PATH as binary could be in metadata paths | ||
812 | # rather than host provided | ||
813 | # Also include some other variables. | ||
814 | FETCH_EXPORT_VARS = ['HOME', 'PATH', | ||
815 | 'HTTP_PROXY', 'http_proxy', | ||
816 | 'HTTPS_PROXY', 'https_proxy', | ||
817 | 'FTP_PROXY', 'ftp_proxy', | ||
818 | 'FTPS_PROXY', 'ftps_proxy', | ||
819 | 'NO_PROXY', 'no_proxy', | ||
820 | 'ALL_PROXY', 'all_proxy', | ||
821 | 'GIT_PROXY_COMMAND', | ||
822 | 'GIT_SSH', | ||
823 | 'GIT_SSL_CAINFO', | ||
824 | 'GIT_SMART_HTTP', | ||
825 | 'SSH_AUTH_SOCK', 'SSH_AGENT_PID', | ||
826 | 'SOCKS5_USER', 'SOCKS5_PASSWD', | ||
827 | 'DBUS_SESSION_BUS_ADDRESS', | ||
828 | 'P4CONFIG', | ||
829 | 'SSL_CERT_FILE', | ||
830 | 'AWS_ACCESS_KEY_ID', | ||
831 | 'AWS_SECRET_ACCESS_KEY', | ||
832 | 'AWS_DEFAULT_REGION'] | ||
833 | |||
811 | def runfetchcmd(cmd, d, quiet=False, cleanup=None, log=None, workdir=None): | 834 | def runfetchcmd(cmd, d, quiet=False, cleanup=None, log=None, workdir=None): |
812 | """ | 835 | """ |
813 | Run cmd returning the command output | 836 | Run cmd returning the command output |
@@ -816,28 +839,7 @@ def runfetchcmd(cmd, d, quiet=False, cleanup=None, log=None, workdir=None): | |||
816 | Optionally remove the files/directories listed in cleanup upon failure | 839 | Optionally remove the files/directories listed in cleanup upon failure |
817 | """ | 840 | """ |
818 | 841 | ||
819 | # Need to export PATH as binary could be in metadata paths | 842 | exportvars = FETCH_EXPORT_VARS |
820 | # rather than host provided | ||
821 | # Also include some other variables. | ||
822 | # FIXME: Should really include all export varaiables? | ||
823 | exportvars = ['HOME', 'PATH', | ||
824 | 'HTTP_PROXY', 'http_proxy', | ||
825 | 'HTTPS_PROXY', 'https_proxy', | ||
826 | 'FTP_PROXY', 'ftp_proxy', | ||
827 | 'FTPS_PROXY', 'ftps_proxy', | ||
828 | 'NO_PROXY', 'no_proxy', | ||
829 | 'ALL_PROXY', 'all_proxy', | ||
830 | 'GIT_PROXY_COMMAND', | ||
831 | 'GIT_SSH', | ||
832 | 'GIT_SSL_CAINFO', | ||
833 | 'GIT_SMART_HTTP', | ||
834 | 'SSH_AUTH_SOCK', 'SSH_AGENT_PID', | ||
835 | 'SOCKS5_USER', 'SOCKS5_PASSWD', | ||
836 | 'DBUS_SESSION_BUS_ADDRESS', | ||
837 | 'P4CONFIG', | ||
838 | 'AWS_ACCESS_KEY_ID', | ||
839 | 'AWS_SECRET_ACCESS_KEY', | ||
840 | 'AWS_DEFAULT_REGION'] | ||
841 | 843 | ||
842 | if not cleanup: | 844 | if not cleanup: |
843 | cleanup = [] | 845 | cleanup = [] |