Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ def finalize_options(self):


def get_shared_library_data_to_include():
# Return the correct uniffi C shared library extension for the given platform
# Return the correct uniffi C shared library extension for the given platform.
# Paths are relative to the onepassword package directory (src/onepassword/)
include_path = "lib"
machine_type = os.getenv("PYTHON_MACHINE_PLATFORM") or platform.machine().lower()
if machine_type in ["x86_64", "amd64"]:
Expand All @@ -42,7 +43,8 @@ def get_shared_library_data_to_include():
uniffi_bindings_file_name = "op_uniffi_core.py"
uniffi_bindings_file_name = os.path.join(include_path, uniffi_bindings_file_name)

return [c_shared_library_file_name, uniffi_bindings_file_name]
# Return paths relative to the onepassword package (package_dir 'onepassword')
return [os.path.join("onepassword", f) for f in [c_shared_library_file_name, uniffi_bindings_file_name]]


setup(
Expand Down
Loading