You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

45 lines
1.4 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #!/usr/bin/env python
  2. # Copyright (c) 2017 The WebRTC project authors. All Rights Reserved.
  3. #
  4. # Use of this source code is governed by a BSD-style license
  5. # that can be found in the LICENSE file in the root of the source
  6. # tree. An additional intellectual property rights grant can be found
  7. # in the file PATENTS. All contributing project authors may
  8. # be found in the AUTHORS file in the root of the source tree.
  9. """This script sets up AppRTC and its dependencies.
  10. Requires that depot_tools is installed and in the PATH.
  11. It will put the result under <output_dir>/collider.
  12. """
  13. import os
  14. import sys
  15. import utils
  16. SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
  17. def main(argv):
  18. if len(argv) == 1:
  19. return 'Usage %s <output_dir>' % argv[0]
  20. output_dir = os.path.abspath(argv[1])
  21. download_apprtc_path = os.path.join(SCRIPT_DIR, 'download_apprtc.py')
  22. utils.RunSubprocessWithRetry([sys.executable, download_apprtc_path,
  23. output_dir])
  24. build_apprtc_path = os.path.join(SCRIPT_DIR, 'build_apprtc.py')
  25. apprtc_dir = os.path.join(output_dir, 'apprtc')
  26. go_dir = os.path.join(output_dir, 'go')
  27. collider_dir = os.path.join(output_dir, 'collider')
  28. utils.RunSubprocessWithRetry([sys.executable, build_apprtc_path,
  29. apprtc_dir, go_dir, collider_dir])
  30. if __name__ == '__main__':
  31. sys.exit(main(sys.argv))