Skip to content
This repository has been archived by the owner on Apr 24, 2019. It is now read-only.

Commit

Permalink
Merge pull request #2321 from mbedmicro/revert-2257-install-deps
Browse files Browse the repository at this point in the history
Revert "Force installation of dependencies in entry points"
  • Loading branch information
sg- committed Jul 29, 2016
2 parents ea78ed1 + c84e5d3 commit 4b50628
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 44 deletions.
7 changes: 0 additions & 7 deletions tools/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,6 @@
ROOT = abspath(join(dirname(__file__), ".."))
sys.path.insert(0, ROOT)

from tools.utils import install_from_pip
with open(join(ROOT, "requirements.txt")) as reqs:
for req in reqs:
install_from_pip(req)

import site
reload(site)

from tools.toolchains import TOOLCHAINS
from tools.toolchains import mbedToolchain
Expand Down
9 changes: 0 additions & 9 deletions tools/make.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,6 @@
ROOT = abspath(join(dirname(__file__), ".."))
sys.path.insert(0, ROOT)

from tools.utils import install_from_pip
with open(join(ROOT, "requirements.txt")) as reqs:
for req in reqs:
install_from_pip(req)

import site
reload(site)

from tools.utils import args_error
from tools.paths import BUILD_DIR
from tools.paths import RTOS_LIBRARIES
Expand All @@ -58,7 +50,6 @@
from tools.toolchains import mbedToolchain
from tools.settings import CLI_COLOR_MAP


if __name__ == '__main__':
# Parse Options
parser = get_default_options_parser()
Expand Down
8 changes: 0 additions & 8 deletions tools/project.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,6 @@
ROOT = abspath(join(dirname(__file__), ".."))
sys.path.insert(0, ROOT)

from tools.utils import install_from_pip
with open(join(ROOT, "requirements.txt")) as reqs:
for req in reqs:
install_from_pip(req)

import site
reload(site)

from shutil import move, rmtree
from argparse import ArgumentParser
from os import path
Expand Down
8 changes: 0 additions & 8 deletions tools/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,6 @@
ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), ".."))
sys.path.insert(0, ROOT)

from tools.utils import install_from_pip
with open(os.path.join(ROOT, "requirements.txt")) as reqs:
for req in reqs:
install_from_pip(req)

import site
reload(site)

from tools.test_api import test_path_to_name, find_tests, print_tests, build_tests, test_spec_from_test_builds
from tools.options import get_default_options_parser
from tools.build_api import build_project, build_library
Expand Down
12 changes: 0 additions & 12 deletions tools/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,15 +338,3 @@ def parse_type(not_parent):
else:
return not_parent
return parse_type

def install_from_pip(package):
import pkg_resources
try:
pkg_resources.working_set.require(package)
except (pkg_resources.DistributionNotFound, pkg_resources.VersionConflict):
import pip
try:
pip.main(['install', '--user', '-q', package])
except IOError as exc:
if exc.errno == 13:
print "please retry with sudo"

0 comments on commit 4b50628

Please sign in to comment.