error occuring when use command make menuconfig - linux

The error displayed in the terminal is
make[1]: /bin/sh: Command not found
make[1]: *** [scripts/basic/fixdep] Error 127
make: *** [scripts_basic] Error 2
Can anyone tell me why and how to solve it

Use this..
sudo apt-get install patch
and then
sudo apt-get install build-essential
after this you can try your Makefile

Related

Redis - linux / Error when Installing redis on linux: `cc: command not found`

I wish to install redis on my red-hat environment. I do the following:
wget http://download.redis.io/redis-stable.tar.gz
tar xvzf redis-stable.tar.gz
cd redis-stable
make
I got the next error:
make[3]: *** [net.o] Error 127
make[3]: Leaving directory `/tmp/redis-stable/deps/hiredis'
make[2]: *** [hiredis] Error 2
make[2]: Leaving directory `/tmp/redis-stable/deps'
make[1]: [persist-settings] Error 2 (ignored)
CC adlist.o
/bin/sh: cc: command not found
make[1]: *** [adlist.o] Error 127
make[1]: Leaving directory `/tmp/redis-stable/src'
make: *** [all] Error 2
How can I fix it?
You are trying to install redis from source code. What this process do is to compile and create executable on your machine and then install it. For doing this you need various tools like gcc etc. Best way is to install all of them together by installing that group. Run this from terminal
yum grouplist
This will show all groups available and then choose group you want to install or run directly
yum groupinstall 'Development Tools'
This will save you from other problems which might come in future while installing from source.
for those of you who encounter this error
check this github issue
before make run this command
$ cd deps; make hiredis lua jemalloc linenoise
Install build essential first
sudo apt-get install build-essential
then install the dependencies
cd deps
make hiredis lua jemalloc linenoise
If you're not an advanced user maybe it is not a good idea to install REDIS from the source.
Instead you should install a packaged version. For example on Fedora / Centos / RHEL:
sudo yum install redis
Come out from your extracted folder/Dir and remove the extracted redis-x.x.x folder with rm -rf redis-x.x.x
now again extract the redis folder with tar xzf redis-x.x.x.tar.gz
go to redis directory again and run the make or make test again. it works for me.

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.

GCC installation Error

I am trying to install GCC 4.9.0, I got following errors for './configure' and 'make'.
I got following error for ./configure
checking for default BUILD_CONFIG... bootstrap-debug
checking for --enable-vtable-verify... no
/usr/bin/ld: crt1.o: No such file: No such file or directory
collect2: ld returned 1 exit status
configure: error: I suspect your system does not have 32-bit developement libraries (libc and headers). If you have them, rerun configure with --enable-multilib. If you do not have them, and want to build a 64-bit-only compiler, rerun configure with --disable-multilib.
Then I used ./configure --disable-multilib then configure completed with out any error.
After 'make'; i end with following error and i am not able to identify what is this error
checking for suffix of object files... configure: error: in `/root/dsk/gcc-4.9.0/x86_64-unknown-linux-gnu/libgcc':
configure: error: cannot compute suffix of object files: cannot compile
See `config.log' for more details.
make[2]: *** [configure-stage1-target-libgcc] Error 1
make[2]: Leaving directory `/root/dsk/gcc-4.9.0'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/root/dsk/gcc-4.9.0'
make: *** [all] Error 2
please help
It seems you are missing gcc-multilib.
Try installing it with sudo apt-get install gcc-multilib and then run ./configure again.
For Centos you need to install following libraries:
sudo yum install glibc-devel.i686
sudo yum install libgcc.i686

Something wrong when I compile and install vim7.4

when I compile and install vim 7.4,I have some error. Steps are as follows:
./configure --prefix=/home/user/.opt/vim74 --with-features=huge --enable-netbeans --enable-multibyte
make
make install
when I excute command 'make',I got the following error information.
make[1]: execvp: echo: Permission denied
make[1]: [auto/pathdef.c] Error 127 (ignored)
......
make[2]: Leaving directory `/home/user/src/vim74/src/po'
make[2]: Entering directory `/home/user/src/vim74/src/po'
make[2]: Nothing to be done for `converted'.
make[2]: Leaving directory `/home/user/src/vim74/src/po'
make[1]: Leaving directory `/home/user/src/vim74/src'
And the command 'make install' gave me the following errors.
......
installing /home/user/.opt/vim74/share/man/man1/vim.1
installing /home/user/.opt/vim74/share/man/man1/vimtutor.1
installing /home/user/.opt/vim74/share/man/man1/vimdiff.1
installing /home/user/.opt/vim74/share/man/man1/evim.1
make[1]: execvp: echo: Permission denied
make[1]: * [installrtbase] Error 127
make[1]: Leaving directory `/home/user/src/vim74/src'
make: * [install] Error 2
I have no root permission and I am also not a sudoer
How I can solve this problem?
is it ubuntu? If it is, just install
sudo apt-get install xorg-dev
./configure \
--enable-perlinterp=dynamic \
--enable-pythoninterp=dynamic \
--enable-rubyinterp=dynamic \
--enable-cscope \
--enable-gui=auto \
--enable-gtk2-check \
--enable-gnome-check \
--with-features=huge \
--with-x \
--with-python-config-dir=/usr/lib/python2.6/config
then
make && sudo make install
that should enable x11 and clipboard support, verified under ubuntu10.04.
when you use make install, try sudo make install instead.
Sorry, I do not know you are not in sudo list. Can you give more error context information?
sudo make
sudo make install
ensure you have enough permission

show "flock: Command not found" when install node.js on QNAP NAS

I want to install node.js on QNAP NAS, it's a linux OS I can use ipkg install package.
but ipkg not have node.js...
I reference web forum as http://forum.qnap.com/viewtopic.php?p=248556, installed V8 JavaScript Engine.
Then install node.js
When I'm typing make on /opt/node, that shows an error message as follows:
make -C out BUILDTYPE=Release V=1 make[1]: Entering directory
/share/HDA_DATA/.qpkg/Optware/node/out' flock
/share/HDA_DATA/.qpkg/Optware/node/out/Release/linker.lock g++
-pthread -rdynamic -o /share/HDA_DATA/.qpkg/Optware/node/out/Release/mksnapshot
-Wl,--start-group /share/HDA_DATA/.qpkg/Optware/node/out/Release/obj.target/mksnapshot/deps/v8/src/mksnapshot.o
/share/HDA_DATA/.qpkg/Optware/node/out/Release/obj.target/deps/v8/tools/gyp/libv8_base.a
/share/HDA_DATA/.qpkg/Optware/node/out/Release/obj.target/deps/v8/tools/gyp/libv8_nosnapshot.a
-Wl,--end-group make[1]: flock: Command not found make[1]: *** [/share/HDA_DATA/.qpkg/Optware/node/out/Release/mksnapshot] Error 127
make[1]: Leaving directory/share/HDA_DATA/.qpkg/Optware/node/out'
make: * [node] Error 2
The QNAP NAS(TS-119P2) does not have flock command line,
What can I do? Could somebody help me?
ipkg install util-linux
It contains flock command.
Goto node source dir.
./configure --prefix=/opt
...
LINK=g++ make
...
LINK=g++ make install
Worked for me.
I had to export CC as my compiler, and then run the commands babalooi suggested:
export CC=/opt/bin/gcc
./configure --prefix=/opt
...
LINK=g++ make
...
LINK=g++ make install

Resources