Skip to content

Conversation

@dae
Copy link
Contributor

@dae dae commented Oct 21, 2021

While building directly with cargo is possible (#467), a lot of the convenience that pyoxidizer provides is lost - you need to construct rather long command lines, and manually bundle files up separately (#466). What if instead of an all-or-nothing approach, pyoxidizer provided limited support for building from an existing Rust crate?

With this PR, the user can build a project created with init-rust-project with a single short command line:

$ PYOXIDIZER_CRATE_FOLDER=$(pwd) pyoxidizer build

It also happens to be somewhat faster, as crates like jemalloc don't get recompiled each time.

It would come with caveats:

  • The user would be responsible for ensuring their crate sources are appropriate for the pyoxidizer version they are invoking
  • It may not work with more elaborate embedding use cases - but then, the user is still free to drop back to raw cargo.
  • I didn't encounter it in testing, but perhaps there might be cases where a stale build product could require the user to manually clear out their build folder?

What do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant