We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d4c0ade commit f7f3759Copy full SHA for f7f3759
package_rust.py
@@ -8,6 +8,7 @@
8
import os
9
import platform
10
import shutil
11
+import subprocess
12
import sys
13
import tarfile
14
@@ -91,6 +92,14 @@ def main():
91
92
93
BuildCrubit(args.build_mac_arm)
94
95
+ # Strip everything in bin/ to reduce the package size.
96
+ bin_dir_path = os.path.join(RUST_TOOLCHAIN_OUT_DIR, 'bin')
97
+ if sys.platform != 'win32' and os.path.exists(bin_dir_path):
98
+ for f in os.listdir(bin_dir_path):
99
+ file_path = os.path.join(bin_dir_path, f)
100
+ if not os.path.islink(file_path):
101
+ subprocess.call(['strip', file_path])
102
+
103
with tarfile.open(os.path.join(THIRD_PARTY_DIR,
104
RUST_TOOLCHAIN_PACKAGE_NAME),
105
'w:xz',
0 commit comments