s3rvac / ssdeep-rs

A Rust wrapper for ssdeep.
GNU General Public License v3.0
8 stars 3 forks source link

"unsafe srcdir value" #1

Closed r3v2d0g closed 7 years ago

r3v2d0g commented 7 years ago

Hi!

So I'm trying to install the library (using cargo) but during the compilation of libfuzzy-sys it gives me the following logs:

   Compiling libfuzzy-sys v0.1.0
error: failed to run custom build command for `libfuzzy-sys v0.1.0`
process didn't exit successfully: `D:\lab\someproject\target\debug\build\libfuzzy-sys-e0a13e7f84cc17f8\build-script-build` (exit code: 101)
--- stdout
OPT_LEVEL = Some("0")
TARGET = Some("x86_64-pc-windows-msvc")
HOST = Some("x86_64-pc-windows-msvc")
TARGET = Some("x86_64-pc-windows-msvc")
TARGET = Some("x86_64-pc-windows-msvc")
HOST = Some("x86_64-pc-windows-msvc")
CC_x86_64-pc-windows-msvc = None
CC_x86_64_pc_windows_msvc = None
HOST_CC = None
CC = None
TARGET = Some("x86_64-pc-windows-msvc")
HOST = Some("x86_64-pc-windows-msvc")
CFLAGS_x86_64-pc-windows-msvc = None
CFLAGS_x86_64_pc_windows_msvc = None
HOST_CFLAGS = None
CFLAGS = None
PROFILE = Some("debug")
cargo:rustc-link-lib=static=fuzzy
cargo:rustc-link-search=D:\lab\someproject\target\debug\build\libfuzzy-sys-e07782e4dfe65e77\out/.libs
INFO: running command: "sh" "C:\\Users\\azastrael\\.cargo\\registry\\src\\github.com-1ecc6299db9ec823\\libfuzzy-sys-0.1.0\\libfuzzy/configure" "--enable-shared=no" "--enable-static=yes"
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane...
--- stderr
configure: error: unsafe srcdir value: 'C:\Users\azastrael\.cargo\registry\src\github.com-1ecc6299db9ec823\libfuzzy-sys-0.1.0\libfuzzy'
thread 'main' panicked at 'FAIL: command did not execute successfully: exit code: 1

build script failed', C:\Users\azastrael\.cargo\registry\src\github.com-1ecc6299db9ec823\libfuzzy-sys-0.1.0\build.rs:76
note: Run with `RUST_BACKTRACE=1` for a backtrace.

So I don't really know what's wrong and I would really appreciate your help.

Thank you, Matthieu.

r3v2d0g commented 7 years ago

Ok, so I think that the issue comes from the: INFO: running command: "sh" "C:\\Users\\azastrael\\.cargo\\registry\\src\\github.com-1ecc6299db9ec823\\libfuzzy-sys-0.1.0\\libfuzzy/configure" "--enable-shared=no" "--enable-static=yes"

So I used "Bash on Ubuntu on Windows" and it worked.

Thank you, Matthieu.