Installing Torch on Virtual Machine - ubuntu-14.04

I'm trying to install Torch on virtual machine which has OS as Ubuntu 14.04 desktop version. I followed the instructions as given in Getting started with Torch. There was no problem in cloning the torch folder from github. In the second step which install dependencies show the following error:
make[1]: *** [libs] Error 1
make[1]: Leaving directory `/tmp/OpenBLAS/kernel'
make: *** [libs] Error 1
Error. OpenBLAS could not be compiled
Please help me to solve the problem.

Ubuntu is missing a gfortran-dev package:
sudo apt-get install gfortran-4.9
Should solve your issue.
Reference

Related

Cannot make kernel .config

I'm setting up RTLinux on a Siemens machine. I cannot seem to generate the config file for the kernel.
I have been following this guide: Install RT Linux patch for Ubuntu and I get stuck at Step 4
I started by installing ubuntu 16.10. Then I installed the linux kernel (linux-5.2.19.tar.gz) and also the RTLinux patch (patch-5.2.19-rt10.patch.gz). I created a working irectory ~/kernel. I unzipped the kernel into this directory and successfully patched the kernel.
I now need to install ncurses:
sudo apt-get install libncurses-dev libssl-dev
When I do this I get a bunch of 404 errors like it cannot reach the archives.
Because of this I went and installed ncurses manually. I went to https://ftp.gnu.org/pub/gnu/ncurses/ncurses-6.1.tar.gz, downloaded the tar and performed the following steps.
cd ncurses-6.1
./configure --prefix=/opt/ncurses
make
sudo make install
ls -la /opt/ncurses
The final line verified the install was correct.
Now I navigate back to my ~/kernel/linux-5.2.19 directory and perform a make menuconfig
and receive the following errors:
*
* Unable to find the ncurses package.
* Install ncurses (ncurses-devel or libncurses-dev
* depending on your distribution).
*
scripts/kconfig/Makefile:206: recipe for target 'scripts/kconfig/mconf-cfg' failed
make[1]: *** [scripts/kconfig/mconf-cfg] Error 1
Makefile:559: recipe for target 'menuconfig' failed
make: *** [menuconfig] Error 2
I appreciate any responses/advice.

Can't install HTK on linux

I wan't to use ALIZE for speaker recognition and after the instalation there is one of the steps: feature extraction using SPRO or HTK So I downloaded zip file of HTK and using terminal I configured everything, but when entering make all I'm getting this error:
/usr/bin/ld: cannot find -lX11
collect2: error: ld returned 1 exit status
Makefile:56: recipe for target 'HSLab' failed
make[1]: *** [HSLab] Error 1
make[1]: Leaving directory '/home/username/Downloads/htk/HTKTools'
Makefile:108: recipe for target 'htktools' failed
make: *** [htktools] Error 1
what does it mean and how to fix this? I'm looking for answer for hours and can't find anything...
I'm using HTK 3.4.1 stable version and LInux ubuntu 16.10
The error cannot find -lX11 means that ld can't find the libraries for X11 (the X.Org display server). The required libraries can be found in the libx11-dev package which can be installed with:
sudo apt-get install libx11-dev
This should resolve your issue, as long as the libraries install in the LD_LIBRARY_PATH (which is likely if apt-get handles it).
On 64-bit systems, you might need to explicitly state the 32-bit version is required:
sudo apt-get install libx11-dev:i386

fatal error: opencv2/core/core.hpp caffe framework installation

I'm trying to install Caffe framework with this script: https://gist.github.com/jetsonhacks/acf63b993b44e1fb9528 and I'm getting opencv2/core/core.hpp error.
CXX src/caffe/layers/data_layer.cpp
src/caffe/layers/data_layer.cpp:2:33:
fatal error: opencv2/core/core.hpp: No such file or directory
#include <opencv2/core/core.hpp>
^
compilation terminated.
make: *** [.build_release/src/caffe/layers/data_layer.o] Error 1
In the documentation, OpenCV is optional. But that error tells me not.
Does such include have nothing to do with OpenCV installation?
Installing opencv for python is not sufficient.
You also need to do
sudo apt-get install libopencv-dev
I faced the same problem and solved it just by installing OpenCV. You will find other similar errors, unless you have installed all prerequisites.

How to install valgrind properly?

I'm installing valgrind now, until the ‘make install’ command it goes good.
The next command- ‘make regtest’ outputs the next error:
../../depcomp: line 689: exec: g++: not found
make[5]: *** [leak_cpp_interior.o] Error 127
make[5]: Leaving directory `/home/kbubuntu/valgrind-3.9.0/memcheck/tests'
make[4]: *** [check-am] Error 2
make[4]: Leaving directory `/home/kbubuntu/valgrind-3.9.0/memcheck/tests'
make[3]: *** [check-recursive] Error 1
make[3]: Leaving directory `/home/kbubuntu/valgrind-3.9.0/memcheck/tests'
make[2]: *** [check-recursive] Error 1
make[2]: Leaving directory `/home/kbubuntu/valgrind-3.9.0/memcheck'
make[1]: *** [check-recursive] Error 1
make[1]: Leaving directory `/home/kbubuntu/valgrind-3.9.0'
make: *** [check] Error 2
How can I solve it?
Thanks.
Short answer: Make from source.
How?
Uninstall the non working valgrind version with root rights (eg. sudo):
apt-get --purge valgrind
or
dpkg --remove valgrind
or
yum remove valgrind
Obtain sources from here.
Identify the latest version (for example 3.17.0)
Download sources : wget https://sourceware.org/pub/valgrind/valgrind-3.17.0.tar.bz2
Decompress archive tar xvf valgrind-3.17.0.tar.bz2
Go to uncompressed archive cd valgrind-3.17.0
Configure ./configure
Compile make
Install make install (with root rights, eg. sudo)
Note: very useful for Raspberry Pi 4 users - Default valgrind installation generate a lot of internal errors. See Valgrind reports hundreds of errors in Hello World program on RaspberryPi 4B
All major linux distributions will include valgrind in their repositories. You can find this on debian derived, apt based systems with:
apt search valgrind
But first just try:
apt install valgrind
It should work, and pull in any dependencies. Remember, if you are not the superuser, you'll need to preface those with sudo.
It's a great tool, have fun.
i think its due to dependency not met.
install g++
by
sudo apt-get install g++
then try again.
error is due to exec is unable to find any package named g++
When trying to install Valgrind in Ubuntu 20.04, you can use apt or snap (notice the version number):
:~/valgrind-3.18.1$ valgrind
Command 'valgrind' not found, but can be installed with:
sudo snap install valgrind # version 3.18.1, or sudo apt install
valgrind # version 1:3.15.0-1ubuntu9.1
Although snap provides the latest version, I preferred to install it natively by compiling the source code following the #g10guang instructions.

installing node.js v0.8.1 via nvm fails

While installing node 0.8.1 via nvm (newest from git) I get an error, that doesn't make any sense for me;
CXX(target) /home/ubuntu/.nvm/src/node-v0.8.1/out/Release/obj.target/v8_base/deps/v8/src/checks.o
g++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.6/README.Bugs> for instructions.
make[1]: *** [/home/ubuntu/.nvm/src/node- v0.8.1/out/Release/obj.target/v8_base/deps/v8/src/api.o] Error 4
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory `/home/ubuntu/.nvm/src/node-v0.8.1/out'
make: *** [node] Error 2
nvm: install v0.8.1 failed!
all previous installs with 0.6.18 were successful. Python is forced to python2 and libssl-dev is the newest on a ubuntu11.10. Does anybody have any advice? Thank you
I created a swapfile on my ec2 instance and voilà, compilation worked. Thanks Alan Curry for the memory hint. Was surprised that there wasn't any swap to start with..

Resources