summaryrefslogtreecommitdiff
path: root/wrappers/python/setup.py
diff options
context:
space:
mode:
authorjwijenbergh <jeroenwijenbergh@protonmail.com>2023-10-25 14:14:17 +0200
committerjwijenbergh <jeroenwijenbergh@protonmail.com>2023-10-25 16:34:13 +0200
commit67161ca7b0cbcd2a37a51c7fd8fcfdbe0c577293 (patch)
treebaeccb61d27e923d3db29bd870faa728bb25bf1f /wrappers/python/setup.py
parent7a4a4b9a648fb072d9641abac893731770d7f028 (diff)
Format: Run Black
Diffstat (limited to 'wrappers/python/setup.py')
-rwxr-xr-xwrappers/python/setup.py18
1 files changed, 14 insertions, 4 deletions
diff --git a/wrappers/python/setup.py b/wrappers/python/setup.py
index 1bc565a..eb0b8ab 100755
--- a/wrappers/python/setup.py
+++ b/wrappers/python/setup.py
@@ -12,6 +12,7 @@ from wheel.bdist_wheel import bdist_wheel as _bdist_wheel
_libname = "eduvpn_common"
__version__ = "1.1.2"
+
def getlibpath(plat_name: str) -> typing.Union[str, None]:
"""Get library path for plat_name relative to exports/lib/ folder."""
@@ -65,8 +66,15 @@ def getlibpath(plat_name: str) -> typing.Union[str, None]:
processed_os = os_map[plat_os]
return (
- processed_os + "/" + arch_map[plat_arch] + "/" +
- lib_prefixes[processed_os] + _libname + "-" + __version__ + lib_suffixes[processed_os]
+ processed_os
+ + "/"
+ + arch_map[plat_arch]
+ + "/"
+ + lib_prefixes[processed_os]
+ + _libname
+ + "-"
+ + __version__
+ + lib_suffixes[processed_os]
)
@@ -91,14 +99,16 @@ class bdist_wheel(_bdist_wheel):
print("Unknown platform:", self.plat_name)
sys.exit(1)
- print("Building wheel for platform:",self.plat_name)
+ print("Building wheel for platform:", self.plat_name)
# setuptools will only use paths inside the package for package_data, so we copy the library
p = "eduvpn_common/lib"
if os.path.isdir(p):
shutil.rmtree(p)
os.makedirs(p)
- shutil.copyfile(self.exports_lib_path + "/" + libpath, p+"/"+libpath.split("/")[-1])
+ shutil.copyfile(
+ self.exports_lib_path + "/" + libpath, p + "/" + libpath.split("/")[-1]
+ )
_bdist_wheel.run(self)
shutil.rmtree("eduvpn_common/lib/")