Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot compile on Arch Linux due to missing swig. #34

Closed
ghost opened this issue Nov 13, 2016 · 3 comments
Closed

Cannot compile on Arch Linux due to missing swig. #34

ghost opened this issue Nov 13, 2016 · 3 comments
Labels

Comments

@ghost
Copy link

ghost commented Nov 13, 2016

I installed bazel from the AUR, succesfully, created an empty project with tensorflow = "*" as the only dependency, did a cargo build -j 1 and this is the output.

ivegotasthma@dev irekt $ cargo build -j 1
    Updating registry `https://github.com/rust-lang/crates.io-index`
 Downloading tensorflow v0.1.0
 Downloading tensorflow-sys v0.5.0
 Downloading num-complex v0.1.35
   Compiling num-traits v0.1.36
   Compiling num-complex v0.1.35
   Compiling libc v0.2.17
   Compiling pkg-config v0.3.8
   Compiling tensorflow-sys v0.5.0
error: failed to run custom build command for `tensorflow-sys v0.5.0`
process didn't exit successfully: `/home/ivegotasthma/work/projects/irekt/target/debug/build/tensorflow-sys-f5d6b3977d411f10/build-script-build` (exit code: 101)
--- stdout
libtensorflow-sys/build.rs:31: output = "/home/ivegotasthma/work/projects/irekt/target/debug/build/tensorflow-sys-f5d6b3977d411f10/out"
libtensorflow-sys/build.rs:33: source = "/home/ivegotasthma/.cargo/registry/src/github.com-1ecc6299db9ec823/tensorflow-sys-0.5.0/target/source-0.10.0"
libtensorflow-sys/build.rs:35: lib_dir = "/home/ivegotasthma/work/projects/irekt/target/debug/build/tensorflow-sys-f5d6b3977d411f10/out/lib-0.10.0"
libtensorflow-sys/build.rs:39: Creating directory "/home/ivegotasthma/work/projects/irekt/target/debug/build/tensorflow-sys-f5d6b3977d411f10/out/lib-0.10.0"
libtensorflow-sys/build.rs:43: library_path = "/home/ivegotasthma/work/projects/irekt/target/debug/build/tensorflow-sys-f5d6b3977d411f10/out/lib-0.10.0/libtensorflow_c.so"
libtensorflow-sys/build.rs:48: target_path = "tensorflow/libtensorflow_c.so"
libtensorflow-sys/build.rs:102: Executing "git" "clone" "--branch=v0.10.0" "--recursive" "https://github.com/tensorflow/tensorflow.git" "/home/ivegotasthma/.cargo/registry/src/github.com-1ecc6299db9ec823/tensorflow-sys-0.5.0/target/source-0.10.0"
libtensorflow-sys/build.rs:106: Command "git" "clone" "--branch=v0.10.0" "--recursive" "https://github.com/tensorflow/tensorflow.git" "/home/ivegotasthma/.cargo/registry/src/github.com-1ecc6299db9ec823/tensorflow-sys-0.5.0/target/source-0.10.0" finished successfully
libtensorflow-sys/build.rs:77: Checking build file "/home/ivegotasthma/.cargo/registry/src/github.com-1ecc6299db9ec823/tensorflow-sys-0.5.0/target/source-0.10.0/tensorflow/BUILD"
libtensorflow-sys/build.rs:84: Patching build file "/home/ivegotasthma/.cargo/registry/src/github.com-1ecc6299db9ec823/tensorflow-sys-0.5.0/target/source-0.10.0/tensorflow/BUILD"
libtensorflow-sys/build.rs:102: Executing "./configure"
No Google Cloud Platform support will be enabled for TensorFlow
Can't find swig.  Ensure swig is in $PATH or set $SWIG_PATH.

--- stderr
Cloning into '/home/ivegotasthma/.cargo/registry/src/github.com-1ecc6299db9ec823/tensorflow-sys-0.5.0/target/source-0.10.0'...
Note: checking out 'c715c3102df1556fc0ce88fc987440a3c80e5380'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

thread 'main' panicked at 'failed to execute "./configure"', /home/ivegotasthma/.cargo/registry/src/github.com-1ecc6299db9ec823/tensorflow-sys-0.5.0/build.rs:104
note: Run with `RUST_BACKTRACE=1` for a backtrace.

ivegotasthma@dev irekt $ 
@adamcrume
Copy link
Contributor

Is SWIG installed? If not, install SWIG and try again. If it still doesn't work, make sure swig is on the $PATH.

@ghost
Copy link
Author

ghost commented Nov 13, 2016

@adamcrume compiles successfully with swig installed, would be worth while to mention this in the README

@adamcrume
Copy link
Contributor

I updated the README.

@adamcrume adamcrume added the bug label Nov 13, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant