Skip to content

Commit

Permalink
Merge pull request #493 from bwoodsend/strip-binaries
Browse files Browse the repository at this point in the history
  • Loading branch information
hugovk committed Dec 17, 2021
2 parents e3ccc5a + c1d5b6d commit 682c660
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion setup.py
@@ -1,10 +1,13 @@
import platform
from glob import glob

from setuptools import Extension, setup

dconv_source_files = glob("./deps/double-conversion/double-conversion/*.cc")
dconv_source_files.append("./lib/dconv_wrapper.cc")

strip_flags = ["-Wl,--strip-all"] if platform.system() == "Linux" else []

module1 = Extension(
"ujson",
sources=dconv_source_files
Expand All @@ -17,7 +20,7 @@
],
include_dirs=["./python", "./lib", "./deps/double-conversion/double-conversion"],
extra_compile_args=["-D_GNU_SOURCE"],
extra_link_args=["-lstdc++", "-lm"],
extra_link_args=["-lstdc++", "-lm"] + strip_flags,
)

with open("python/version_template.h") as f:
Expand Down

0 comments on commit 682c660

Please sign in to comment.