Skip to content

Commit 7593f9d

Browse files
authored
Proxy environment variables passthrough to recipes (#3126)
* pass common proxy env vars to recipe env to fix pip build issues on corporate networks * remove whitespace on blank lines
1 parent 9611266 commit 7593f9d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pythonforandroid/recipe.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -535,6 +535,11 @@ def get_recipe_env(self, arch=None, with_flags_in_cc=True):
535535
if arch is None:
536536
arch = self.filtered_archs[0]
537537
env = arch.get_env(with_flags_in_cc=with_flags_in_cc)
538+
539+
for proxy_key in ['HTTP_PROXY', 'http_proxy', 'HTTPS_PROXY', 'https_proxy']:
540+
if proxy_key in environ:
541+
env[proxy_key] = environ[proxy_key]
542+
538543
return env
539544

540545
def prebuild_arch(self, arch):

0 commit comments

Comments
 (0)