Shared library deployment

⚓ Rust    📅 2025-10-06    👤 surdeus    👁️ 5      

surdeus

Info

This post is auto-generated from RSS feed The Rust Programming Language Forum - Latest topics. Source: Shared library deployment

Hi, I am asking for advice how to deploy a rust application that needs shared libraries. My workflow often is as following:

  • write rust sys crate with binding for a given shared library, e.g. a *.so file. This file is contained in the git repo
  • write application that uses this sys crate as dependency
  • deploy application as debian package with cargo-deb

What is a good way to deploy the shared library? If I have the file, I can deploy it with the debian package but I do not see how I can access the file that is contained in the sys crate. I could copy it to the application directory, but whenever I update the shared library in the syscrate I would have to update the .so file in the application. Is there a way to access the dependency repos folder in the application build.rs, so I can always deploy the file from the sys crate?

2 posts - 2 participants

Read full topic

🏷️ Rust_feed