Is there any precompiled release for Windows?
zhongsheng94 opened this issue · 8 comments
Hello, can this be used under windows, if so, how can I install it on windows?
Yes that should be possible. You need to install rust/cargo first (see here: https://www.rust-lang.org/tools/install (most likely some rustup-init.exe))
After adding cargo to path (normally the installation should handle that for you) you just need to run 'cargo install keepass-diff' and this gets compiled.
At the end you might need to add .cargo/bin also to your path (if the installation of rustup didn't) to run it from everywhere.
Hello @caemor
I tried the compilation and it failed.
I installed C++ build tools ( from vs 2019) and rust using rustup-init.
I then ran "cargo install keepass-diff"
Am I doing something wrong ?
==============================
Versions of rust/cargo:
C:\Users\admin>rustc --version
rustc 1.34.1 (fc50f328b 2019-04-24)
C:\Users\admin>cargo --version
cargo 1.34.0 (6789d8a0a 2019-04-01)
Compilation Log :
C:\Users\admin>cargo install keepass-diff
Updating crates.io index
Downloaded keepass-diff v0.1.0
Downloaded 1 crates (174.5 KB) in 1.69s
Installing keepass-diff v0.1.0
Downloaded termcolor v1.0.4
Downloaded clap v2.33.0
Downloaded wincolor v1.0.1
Downloaded rpassword v2.1.0
Downloaded bitflags v1.0.4
Downloaded strsim v0.8.0
Downloaded keepass v0.1.2
Downloaded atty v0.2.11
Downloaded textwrap v0.11.0
Downloaded vec_map v0.8.1
Downloaded byteorder v0.4.2
Downloaded flate2 v0.2.20
Downloaded unicode-width v0.1.5
Downloaded kernel32-sys v0.2.2
Downloaded winapi-util v0.1.2
Downloaded xml-rs v0.3.6
Downloaded winapi v0.3.7
Downloaded rust-crypto v0.2.36
Downloaded secstr v0.2.1
Downloaded winapi v0.2.8
Downloaded winapi-build v0.1.1
Downloaded rustc-serialize v0.3.24
Downloaded miniz-sys v0.1.11
Downloaded rand v0.3.23
Downloaded bitflags v0.7.0
Downloaded gcc v0.3.55
Downloaded time v0.1.42
Downloaded cc v1.0.35
Downloaded libc v0.2.53
Downloaded rand v0.4.6
Compiling winapi v0.3.7
Compiling cc v1.0.35
Compiling libc v0.2.53
Compiling winapi-build v0.1.1
Compiling gcc v0.3.55
Compiling winapi v0.2.8
Compiling bitflags v0.7.0
Compiling rustc-serialize v0.3.24
Compiling unicode-width v0.1.5
Compiling byteorder v0.4.2
Compiling bitflags v1.0.4
Compiling vec_map v0.8.1
Compiling strsim v0.8.0
Compiling kernel32-sys v0.2.2
Compiling xml-rs v0.3.6
Compiling miniz-sys v0.1.11
Compiling rust-crypto v0.2.36
Compiling textwrap v0.11.0
Compiling secstr v0.2.1
error[E0603]: function mlock
is private
--> C:\Users\admin.cargo\registry\src\github.com-1ecc6299db9ec823\secstr-0.2.1\src\lib.rs:62:18
|
62 | memlock::mlock(&cont);
| ^^^^^
error[E0603]: function munlock
is private
--> C:\Users\admin.cargo\registry\src\github.com-1ecc6299db9ec823\secstr-0.2.1\src\lib.rs:108:18
|
108 | memlock::munlock(&self.content);
| ^^^^^^^
error: aborting due to 2 previous errors
For more information about this error, try rustc --explain E0603
.
error: Could not compile secstr
.
warning: build failed, waiting for other jobs to finish...
error: failed to compile keepass-diff v0.1.0
, intermediate artifacts can be found at C:\Users\admin\AppData\Local\Temp\cargo-installRbJFK7
Caused by:
build failed
You are doing everything correctly.
It seems the old version of secstr was windows incompatible (https://github.com/myfreeweb/secstr/blob/v0.2.1/src/lib.rs#L165)
There is a new version avaibable which is included in a newer version of keepass. So keepass-diff needs to update it's keepass dependency.
So until someone patches keepass-diff it seems like it won't compile on anything not being unix, e.g. windows or mac.
You could either try my fork (https://github.com/caemor/keepass-diff/tree/fix-windows-comp-with-updating-dep) or wait until the PR i added, is accepted in here.
@caemor - How do I use your fork ?
Pardon my ignorance. I installed Rust only to get this tool.
git clone my fork : git clone https://github.com/caemor/keepass-diff.git
switch to that directory
checkout updated branch: git branch master origin/fix-windows-comp-with-updating-dep
and then install the local files with cargo: cargo install (you can also use cargo install --path .
)
if you don`t want to download it with git, you can directly download the files at https://github.com/caemor/keepass-diff/archive/fix-windows-comp-with-updating-dep.zip