When I compile my programme i point to the folder containing the libraries and include torch, torch_cpu and c10.
But i always get the following errors
ld: error: undefined symbol: torch::cuda::is_available()
ld: error: undefined symbol: torch::nn::Module::named_buffers(bool) const
ld: error: undefined symbol: torch::nn::Module::named_parameters(bool) const
ld: error: undefined symbol: torch::nn::Module::eval()
ld: error: undefined symbol: torch::nn::EmbeddingImpl::forward(at::Tensor const&)
ld: error: undefined symbol: torch::nn::detail::RNNImplBase<torch::nn::LSTMImpl>::flatten_parameters()
ld: error: undefined symbol: torch::nn::LSTMImpl::forward(at::Tensor const&,c10::optional<std::__ndk1::tuple<at::Tensor, at::Tensor> >)
ld: error: undefined symbol: typeinfo for torch::nn::Module

I’ve been told it’s because i’ve only compiled the JIT version of pytorch. But looking thought the build_android.sh file on the git repo, I can’t see any options that would not build the JIT version.