We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 751fa1b commit 26456a0Copy full SHA for 26456a0
1 file changed
pyoxidizer.bzl
@@ -0,0 +1,21 @@
1
+# pyoxidizer.bzl
2
+def make_python_distribution():
3
+ dist = default_python_distribution()
4
+
5
+ # Optimizations
6
+ policy = dist.make_python_packaging_policy()
7
+ policy.strip_all_shared_libraries = True # Strip unnecessary shared libraries
8
+ policy.optimize_bytecode = True # Optimize Python bytecode
9
+ policy.optimize_for_size = True # Reduce the binary size
10
11
+ # Embed the Python standard library into the binary
12
+ dist = dist.to_python_executable(
13
+ name="dfetch",
14
+ packaging_policy=policy,
15
+ )
16
17
+ return dist
18
19
20
+def make_application():
21
+ return make_python_distribution()
0 commit comments