Exclude unused libpython{python_version}.so to reduce the size of zipped Python executables (#772)
diff --git a/python/repositories.bzl b/python/repositories.bzl
index ca54ab7..f897904 100644
--- a/python/repositories.bzl
+++ b/python/repositories.bzl
@@ -170,6 +170,9 @@
allow_empty = True,
exclude = [
"**/* *", # Bazel does not support spaces in file names.
+ # Unused shared libraries. `python` executable and the `:libpython` target
+ # depend on `libpython{python_version}.so.1.0`.
+ "lib/libpython{python_version}.so",
# static libraries
"lib/**/*.a",
# tests for the standard libraries.