Skip to content

Commit 6956b7c

Browse files
committed
Replace /usr/bin/python with /usr/env/python
/usr/bin/python doesn't exist on ubuntu 20.04 causing tests to fail. I've updated the shebangs everywhere to use `/usr/bin/env python` instead.
1 parent 79375b7 commit 6956b7c

File tree

11 files changed

+12
-12
lines changed

11 files changed

+12
-12
lines changed

Diff for: benchmark/scripts/compare_perf_tests.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
# -*- coding: utf-8 -*-
33

44
# ===--- compare_perf_tests.py -------------------------------------------===//

Diff for: benchmark/scripts/test_Benchmark_Driver.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
# -*- coding: utf-8 -*-
33

44
# ===--- test_Benchmark_Driver.py ----------------------------------------===//

Diff for: benchmark/scripts/test_compare_perf_tests.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
# -*- coding: utf-8 -*-
33

44
# ===--- test_compare_perf_tests.py --------------------------------------===//

Diff for: benchmark/scripts/test_utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
# -*- coding: utf-8 -*-
33

44
# ===--- test_utils.py ---------------------------------------------------===//

Diff for: test/ScanDependencies/Inputs/CommandRunner.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22

33
import subprocess
44
import sys

Diff for: utils/jobstats/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
#
33
# ==-- jobstats - support for reading the contents of stats dirs --==#
44
#

Diff for: utils/jobstats/jobstats.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
#
33
# ==-- jobstats - support for reading the contents of stats dirs --==#
44
#

Diff for: utils/process-stats-dir.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
#
33
# ==-- process-stats-dir - summarize one or more Swift -stats-output-dirs --==#
44
#

Diff for: utils/rusage.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22
# utils/rusage.py - Utility to measure resource usage -*- python -*-
33
#
44
# This source file is part of the Swift.org open source project

Diff for: validation-test/ParseableInterface/verify_all_overlays.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python
22

33
# Note that this test should still "pass" when no swiftinterfaces have been
44
# generated.

Diff for: validation-test/SIL/verify_all_overlays.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python
1+
#!/usr/bin/env python3
22
# RUN: ${python} %s %target-swiftmodule-name %platform-sdk-overlay-dir \
33
# RUN: %target-sil-opt -sdk %sdk -enable-sil-verify-all \
44
# RUN: -F %sdk/System/Library/PrivateFrameworks \
@@ -39,7 +39,7 @@
3939

4040
# llvm-bcanalyzer | not grep Unknown
4141
bcanalyzer_output = subprocess.check_output(["llvm-bcanalyzer",
42-
module_path])
42+
module_path]).decode("utf-8")
4343
if "Unknown" in bcanalyzer_output:
4444
print(bcanalyzer_output)
4545
sys.exit(1)

0 commit comments

Comments
 (0)