diff --git a/setup.py b/setup.py index 3ecfa17c6dca5..3a9bc6b157c16 100644 --- a/setup.py +++ b/setup.py @@ -3,6 +3,7 @@ from setuptools.command.build_py import build_py import subprocess import sys +import os def run_command(command, cwd=None): @@ -32,6 +33,9 @@ class CustomBuild(build_py): def run(self): super().run() + top_level_dir = os.path.abspath(os.path.dirname(__file__)) + os.environ['PYTHONPATH'] = top_level_dir + # Running GN to generate build files print('Generating build files with GN...') run_command(