doy / rbw

unofficial bitwarden cli
https://git.tozt.net/rbw
Other
581 stars 83 forks source link

rbw fails to build due to crate `Region` failing to build #105

Closed nikkicoon closed 2 months ago

nikkicoon commented 1 year ago

I'm trying to package rbw for pkgsrc (I'm building on NetBSD/amd64, but it's a multi platform system PM).

It currently fails to build, I've reported this upstream at https://github.com/darfink/region-rs/issues/23 but it looks like after 1 year no commits that the crate has been abandoned by its developer.

Old log included in upstream link, new log:

   Compiling region v3.0.0
error[E0412]: cannot find type `QueryIter` in module `os`
 --> /usr/work/security/rbw/work/vendor/region-3.0.0/src/query.rs:7:24
  |
7 |   iterator: Option<os::QueryIter>,
  |                        ^^^^^^^^^ not found in `os`
  |
help: consider importing this struct
  |
1 | use crate::QueryIter;
  |
help: if you import `QueryIter`, refer to it directly
  |
7 -   iterator: Option<os::QueryIter>,
7 +   iterator: Option<QueryIter>,
  |

error[E0433]: failed to resolve: could not find `QueryIter` in `os`
  --> /usr/work/security/rbw/work/vendor/region-3.0.0/src/query.rs:15:9
   |
15 |     os::QueryIter::new(origin, size).map(|iterator| Self {
   |         ^^^^^^^^^ not found in `os`
   |
help: consider importing this struct
   |
1  | use crate::QueryIter;
   |
help: if you import `QueryIter`, refer to it directly
   |
15 -     os::QueryIter::new(origin, size).map(|iterator| Self {
15 +     QueryIter::new(origin, size).map(|iterator| Self {
   |

Some errors have detailed explanations: E0412, E0433.
For more information about an error, try `rustc --explain E0412`.
error: could not compile `region` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
*** Error code 101

Stop.
nikkicoon commented 1 year ago

The actual core issue might be that region needs to have a NetBSD implementation added? I haven't worked much with rust.

doy commented 12 months ago

yeah, it does look like the issue is a missing netbsd implementation. unfortunately, i don't have access to any netbsd machines, so i can't help here myself/:

pfr-dev commented 5 months ago

I'm getting the exact same error. Would love to use rbw on NetBSD. Might try rally some support in the BSD community.

0323pin commented 5 months ago

@pfr-dev this, https://github.com/darfink/region-rs/pull/14 fixes it but, it hasn't been merged.

0323pin commented 5 months ago

@nikkicoon and @pfr-dev, I've just pushed a package to the wip-repository, please do some testing.

pfr-dev commented 5 months ago

@nikkicoon and @pfr-dev, I've just pushed a package to the wip-repository, please do some testing.

Thanks! I can confirm this is working on NetBSD 9.3_Stable

0323pin commented 5 months ago

I've now merged the package into the main branch.

It would be good to get that commit merged into region, though. Carrying this workaround for a long time may turn out painful.

pfr-dev commented 4 months ago

It would be good to get that commit merged into region, though.

Patch has been merged and a new release tag v3.0.1 created.

Thanks @0323pin !

doy commented 2 months ago

i've bumped the region dependency in 5c47355, and this should be included in the 1.10 release. thanks for the work here!

0323pin commented 2 months ago

@doy Thanks! Is a new release planned?

doy commented 2 months ago

just released!