Hello,
I face the same problem here.
I have compiled and installed the newest pytorch 1.6.0a0 on raspberry pi 4 4GB all by myself (I might change some choices in CMakeLists.txt) (Operating System: raspbian, armv7l)
but… I failed to compile it on ubuntu server on raspberry pi.
The building and installing procedure is just
python3 setup.py bdist_wheel

to get pytorch, and
python3 tools/build_libtorch.py

to build libtorch. (P.S. cmake+make is not recommended)
Now I give up building from myself. Perhaps it is the hardware that counts? (no SWAP partition in my OS?)
Use built wheel from others might be a good choice.
If you just want to use Libtorch? …
You can find TorchConfig.cmake, which is very essential. And that is the key to using libtorch.
image1920×979 98.9 KB
image1920×979 63.7 KB
The two clip above shows an pytorch installed on anaconda3 on my Microsoft Windows 10. Other operating systems (Linux, or some others) may be a little different.
For more instructions on using libtorch, see the libtorch’s turtorial.