fernandobatels / rsfbclient

Rust Firebird Client
MIT License
74 stars 10 forks source link

Crate r2d2 build fixed #126

Closed fernandobatels closed 2 years ago

fernandobatels commented 2 years ago

Fixed the release build of r2d2_firebird crate. Now we have a phantom option on simple connection/transaction enum's.

Without this fix, we cannot build the r2d2 on release mode.

Issue #125

coveralls commented 2 years ago

Pull Request Test Coverage Report for Build 2757615272


Totals Coverage Status
Change from base Build 2750544977: 0%
Covered Lines: 134
Relevant Lines: 2519

💛 - Coveralls
jairinhohw commented 2 years ago

I don't understand the problem, the crate can be built as long as one of the 3 main rsfbclient features are enables (linking, dynamic_loading, or pure_rust). If we merge this, it will allways pull the pure_rust implementation, even if not necessary (using linking for example).

fernandobatels commented 2 years ago

I don't understand the problem, the crate can be built as long as one of the 3 main rsfbclient features are enables (linking, dynamic_loading, or pure_rust). If we merge this, it will allways pull the pure_rust implementation, even if not necessary (using linking for example).

On master branch, running cargo build --release inside rd2d_firebird:

error[E0392]: parameter `'c` is never used
  --> src/transaction/simple.rs:19:30
   |
19 | pub struct SimpleTransaction<'c> {
   |                              ^^ unused parameter

The cargo publish build the crate on release mode. Without my fix, I cannot launch new versions of rd2d.

I agree with your commentary about always pull the pure_rust. I will find an alternative.

jairinhohw commented 2 years ago

Does it work if you do cargo publish --features rsfbclient/pure_rust ?

fernandobatels commented 2 years ago

cargo publish --features rsfbclient/pure_rust

It worked. Thanks. This PR is no longer needed.