ajtulloch/caffe.rs

Can't compile this because of a bindgen issue

Closed this issue · 2 comments

iopq commented

I get:

failed to run custom build command for `caffe v0.1.0 (file:///home/iopq/caffe.rs-master)`
Process didn't exit successfully: `/home/iopq/caffe.rs-master/target/release/build/caffe-ce366d1c75b00976/build-script-build` (exit code: 101)
--- stderr
/home/iopq/caffe-caffe-ffi/include/caffe/ffi.hpp:1:10: fatal error: 'stddef.h' file not found
thread '<main>' panicked at 'called `Result::unwrap()` on an `Err` value: ()', ../src/libcore/result.rs:741

any idea for a work-around?

It seems the issue is filed to bindgen as:

https://github.com/crabtw/rust-bindgen/issues/85

I tried "-I /usr/lib/clang/3.5.0/include" in line 37, but it didn't solve my issue (maybe I put it in the wrong place?)

Weird, I wonder why you're not getting stddef.h? http://pubs.opengroup.org/onlinepubs/7908799/xsh/stddef.h.html

I got this working on my OS X system, FWIW, but I guess travis is getting it working on something Linux. What platform are you working on?

iopq commented

Because of the bindgen bug, it doesn't find /usr/lib/clang/3.5.0/include because it tries a relative path from the folder

I forked it to get it to work, but that's really a work-around until bindgen is fixed I guess