@@ -474,7 +474,6 @@ def __init__(self, *args, **kwargs):
474474 self .pylibdir = UNKNOWN
475475 self .all_pylibdirs = [UNKNOWN ]
476476
477- self .py_installopts = []
478477 self .install_cmd_output = ''
479478
480479 # make sure there's no site.cfg in $HOME, because setup.py will find it and use it
@@ -499,8 +498,6 @@ def __init__(self, *args, **kwargs):
499498 # figure out whether this Python package is being installed for multiple Python versions
500499 self .multi_python = 'Python' in self .cfg ['multi_deps' ]
501500
502- # determine install command
503- self .use_setup_py = False
504501 self .determine_install_command ()
505502
506503 # avoid that pip (ab)uses $HOME/.cache/pip
@@ -522,7 +519,9 @@ def determine_install_command(self):
522519 """
523520 Determine install command to use.
524521 """
522+ self .py_installopts = []
525523 if self .cfg .get ('use_pip' , True ) or self .cfg .get ('use_pip_editable' , False ):
524+ self .use_setup_py = False
526525 self .install_cmd = PIP_INSTALL_CMD
527526
528527 pip_verbose = self .cfg .get ('pip_verbose' , None )
@@ -551,8 +550,8 @@ def determine_install_command(self):
551550 else :
552551 self .use_setup_py = True
553552 self .install_cmd = SETUP_PY_INSTALL_CMD
554- install_target = self .cfg .get_ref ('install_target' )
555553
554+ install_target = self .cfg .get_ref ('install_target' )
556555 if install_target == EASY_INSTALL_TARGET :
557556 self .install_cmd += " %(loc)s"
558557 self .py_installopts .append ('--no-deps' )
0 commit comments