Can't install TPLINK wireless adapter driver on Linux - linux

I have a TP-LINK Archer T2UH wireless adapter and i'm trying to install its driver by typing these commands:
sudo apt-get install git build-essential
git clone https://github.com/Myria-de/mt7610u_wifi_sta_v3002_dpo_20130916.git
cd mt7610u_wifi_sta_v3002_dpo_20130916
make
sudo make install
sudo mkdir -p /etc/Wireless/RT2870STA
sudo cp RT2870STA.dat /etc/Wireless/RT2870STA/RT2870STA.dat
But when I type the make command:
make -C tools
make[1]: Entering directory '/quidam/mt7610u_wifi_sta_v3002_dpo_20130916/tools'
gcc -g bin2h.c -o bin2h
make[1]: Leaving directory '/quidam/mt7610u_wifi_sta_v3002_dpo_20130916/tools'
/quidam/mt7610u_wifi_sta_v3002_dpo_20130916/tools/bin2h
chipset = mt7610u
cp -f os/linux/Makefile.6 /quidam/mt7610u_wifi_sta_v3002_dpo_20130916/os/linux/Makefile
make -C /lib/modules/4.17.0-kali3-amd64/build SUBDIRS=/quidam/mt7610u_wifi_sta_v3002_dpo_20130916/os/linux modules
make[1]: *** /lib/modules/4.17.0-kali3-amd64/build: No such file or directory. Stop.
make: *** [Makefile:404: LINUX] Error 2

Related

Unable to install node via nvm in Cygwin

When I try to use the "nvm install" command, it seems to run fine but at the very end I get the following long error message:
Warning: unrecognized setting VCCLCompilerTool/MultiProcessorCompilation
Warning: Missing input files:
/home/Dinghy/.nvm/.cache/src/node-v10.20.1/files/tools\msvs\genfiles\node_etw_provider.rc
/home/Dinghy/.nvm/.cache/src/node-v10.20.1/files/tools\msvs\genfiles\node_etw_provider.h
/home/Dinghy/.nvm/.cache/src/node-v10.20.1/files/deps/v8/gypfiles/..\src\parsing\preparse-data-format.h
/home/Dinghy/.nvm/.cache/src/node-v10.20.1/files/tools\msvs\genfiles\node_perfctr_provider.rc
/usr/bin/python2.7 tools/gyp_node.py -f make
make -C out BUILDTYPE=Release V=1
touch 7943452e36215487f7a1b8edf63ca06ddfd83538.intermediate
LD_LIBRARY_PATH=/home/Dinghy/.nvm/.cache/src/node-v10.20.1/files/out/Release/lib.host:/home/Dinghy/.nvm/.cache/src/node-v10.20.1/files/out/Release/lib.target:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH; cd ../.; mkdir -p tools/msvs/genfiles; "mc src/res/node_etw_provider.man -h tools/msvs/genfiles -r tools/msvs/genfiles"
/bin/sh: mc src/res/node_etw_provider.man -h tools/msvs/genfiles -r tools/msvs/genfiles: No such file or directory
make[1]: *** [node_etw.target.mk:17: 7943452e36215487f7a1b8edf63ca06ddfd83538.intermediate] Error 127
rm 7943452e36215487f7a1b8edf63ca06ddfd83538.intermediate
make: *** [Makefile:99: node] Error 2
nvm: install v10.20.1 failed!
I've also tried installing it manually but haven't had any success that way either. This worked fine on an old install of cygwin I had, so I'm not sure what the problem is on this new install.

Ndless makefile/make install error linux

I have read up here about how to install the Ndless SDK on Linux, and I have followed as much as I could, like installing packages via terminal with:
sudo apt-get install [package]
all goes well until I reach the root "make" command. I do as the directions say, in ~/Ndless, and run "make" in the terminal. I receive this error each time I try to do this:
make -C ndless-sdk
make[1]: Entering directory '/home/pi/Ndless/ndless-sdk'
make -C libsyscalls
make[2]: Entering directory '/home/pi/Ndless/ndless-sdk/libsyscalls'
arm-none-eabi-gcc -mcpu=arm926ej-s -std=c11 -nostdlib -O3 -fPIE -mlong-calls -Wall -Werror -I ../include/ -I ../thirdparty/nspire-io/include/ -D_TINSPIRE -ffunction-sections -fdata-sections -c realpath.c -o realpath.o
realpath.c: In function 'realpath1':
realpath.c:50:12: error: 'PATH_MAX' undeclared (first use in this function)
char left[PATH_MAX], next_token[PATH_MAX];
^
realpath.c:50:12: note: each undeclared identifier is reported only once for each function it appears in
realpath.c:50:23: error: unused variable 'next_token' [-Werror=unused-variable]
char left[PATH_MAX], next_token[PATH_MAX];
^
realpath.c:50:7: error: unused variable 'left' [-Werror=unused-variable]
char left[PATH_MAX], next_token[PATH_MAX];
^
realpath.c: In function 'realpath':
realpath.c:159:25: error: 'PATH_MAX' undeclared (first use in this function)
m = resolved = malloc(PATH_MAX);
^
cc1: all warnings being treated as errors
Makefile:21: recipe for target 'realpath.o' failed
make[2]: *** [realpath.o] Error 1
make[2]: Leaving directory '/home/pi/Ndless/ndless-sdk/libsyscalls'
Makefile:14: recipe for target 'build-libsyscalls' failed
make[1]: *** [build-libsyscalls] Error 2
make[1]: Leaving directory '/home/pi/Ndless/ndless-sdk'
Makefile:19: recipe for target 'build-ndless-sdk' failed
make: *** [build-ndless-sdk] Error 2
Also, I created a .bash_profile in my home directory, and added this to it, as shown in the directions:
export PATH="/home/pi/Ndless/ndless-sdk/toolchain/install/bin:/home/pi/Ndless/ndless-sdk/bin:${PATH}"
When the directions displayed PATH environment variable as bold, I took to the web and found that .bashrc was the PATH, so I added the same above code to it.
LAST EDIT
https://pastebin.com/C7rWJp5Y
make[4]: Entering directory '/home/pi/Ndless/ndless/src/tools/MakeSyscalls'
php ./mkSyscalls.php "idc" "../../../../ndless-sdk/include/syscall-addrs.h"
/bin/sh: 1: php: not found
Makefile:9: recipe for target '../../../../ndless-sdk/include/syscall-addrs.h' failed
make[4]: *** [../../../../ndless-sdk/include/syscall-addrs.h] Error 127
make[4]: Leaving directory '/home/pi/Ndless/ndless/src/tools/MakeSyscalls'
Makefile:10: recipe for target 'build-MakeSyscalls' failed
make[3]: *** [build-MakeSyscalls] Error 2
make[3]: Leaving directory '/home/pi/Ndless/ndless/src/tools'
Makefile:9: recipe for target 'build-tools' failed
make[2]: *** [build-tools] Error 2
make[2]: Leaving directory '/home/pi/Ndless/ndless/src'
Makefile:9: recipe for target 'build-src' failed
make[1]: *** [build-src] Error 2
make[1]: Leaving directory '/home/pi/Ndless/ndless'
Makefile:19: recipe for target 'build-ndless' failed
make: *** [build-ndless] Error 2
Anywhere the string user appears in the below commands for changing directories, just replace that with your username in Linux.
Update apt-get
sudo apt-get update
If this fails make sure you temporarily disable your VPN connection; it did for me.
Install packages
sudo apt-get -y install git && sudo apt-get -y install gcc && sudo apt-get -y install binutils && sudo apt-get -y install libmpfr-dev && sudo apt-get -y install libmpc-dev && sudo apt-get -y install zlib1g-dev && sudo apt-get -y install libboost-program-options-dev && sudo apt-get -y install wget && sudo apt-get -y install texinfo && sudo apt-get -y install python2.7 && sudo apt-get -y install python2.7-dev && sudo apt-get -y install python3 && sudo apt-get -y install python3-dev && sudo apt-get -y install php && sudo apt-get -y install libboost-dev && sudo apt-get -y install build-essential && sudo apt-get -y install gcc-arm-none-eabi && sudo apt-get -y install python
Clone Ndless into home
git clone --recursive https://github.com/ndless-nspire/Ndless.git
Run build_toolchain
cd Ndless/ndless-sdk/toolchain && ./build_toolchain.sh
Ndless command path
export PATH="/home/user/Ndless/ndless-sdk/toolchain/install/bin:/home/user/Ndless/ndless-sdk/bin:${PATH}"
Ndless Makefile
cd /home/user/Ndless && make
All of this will take a long time (took 5 hours for me), depending on your hardware and maybe internet connection.
Notes
Lets try building this simple file:
// main.cpp
#include <libndls.h>
#include <SDL/SDL.h>
#include <SDL/SDL_config.h>
int main() {
SDL_Surface *screen;
nSDL_Font *font;
SDL_Init(SDL_INIT_VIDEO);
screen = SDL_SetVideoMode(320, 240, has_colors ? 16 : 8, SDL_SWSURFACE);
font = nSDL_LoadFont(NSDL_FONT_TINYTYPE, 29, 43, 61);
SDL_FillRect(screen, NULL, SDL_MapRGB(screen->format, 255, 0, 0));
nSDL_DrawString(screen, font, 10, 10, "Hello, world! \x1");
SDL_Flip(screen); // update screen
SDL_Delay(3000); // wait for 3 seconds
SDL_Quit(); // get out of SDL screen, returns to normal nspire
return 0;
}
To generate the makefile:
nspire-tools new main
Then run:
make
The output should look something like this:
user#DESKTOP-6IBLUJD:/mnt/d/NdlessSDK/workspace/cpp/test$ make
nspire-g++ -Wall -W -marm -Os -c main.cpp -o main.o
mkdir -p .
nspire-ld main.o -o main.cpp.elf
genzehn --input main.cpp.elf --output main.cpp.tns.zehn --name "main.cpp"
make-prg main.cpp.tns.zehn main.cpp.tns
rm main.cpp.tns.zehn
I did this in WSL, so I had to do cd cd /mnt to reach my main drives to compile.
You can also try running that in Firebird Emulator with Ndless installed!
If you skip ahead, and decide to run make without fully completing the ./build_toolchain command (probably resulting from an error), don't be surprised if the make command fails. The output for the failure will be something about a
undeclared PATH_MAX
But, if you install all the necessary packages, and fully build the commands with success, Ndless should compile and function without issue.
If you get a nspire-gcc: Command not found while building the SDK, make sure you set the PATH variable correctly. I did echo "$PWD" which shows my current directory, which I used for Ndless path.

I got error in 'make' gcc-5.3.0 package as referred in Linux from scratch

I get the following error when making gcc:
Makefile:2154: recipe for target 's-attrtab' failed
make[2]: *** [s-attrtab] Killed
make[2]: Leaving directory '/mnt/lfs/sources/gcc-5.3.0/build/gcc'
Makefile:4105: recipe for target 'all-gcc' failed
make[1]: *** [all-gcc] Error 2
make[1]: Leaving directory '/mnt/lfs/sources/gcc-5.3.0/build'
Makefile:858: recipe for target 'all' failed
make: *** [all] Error 2
I had exactly the same issue1. The reason for this error is the fact the system is running out of memory. In my case it was caused because I ran make -j 48 and these 48 jobs were too much.
Decreasing the job number to 24 fixed this problem. In other words:
increase your memory or
reduce the jobs using the -j make switch
1 This post helped me then to fix the problem: http://dustint.com/post/669/gentoo-gcc-recipe-for-target-s-attrtab-failed
This is how i installed it on ubuntu 14.04 (gcc 5)
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install gcc-5 g++-5
sudo update-alternatives
sudo update-alternatives --remove-all gcc
sudo update-alternatives --remove-all g++
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 20
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-5 20
sudo update-alternatives --config gcc
sudo update-alternatives --config g++
The most common errors with the LFS gcc are caused by using a wrong shell. /bin/sh must be a link to bash !
If the wrong shell was used : Start from scratch with binutils.
"Askforhelp" : http://www.linuxfromscratch.org/lfs/view/stable/chapter01/askforhelp.html → 1.5.1. → the essential things to include in any request for help are → ... The host distribution and version being used to create LFS.
Please show the output from $ bash version-check.sh

Caffe compilation fails: make: *** [.build_release/src/caffe/data_transformer.o] Error 1

I am trying to build caffe after the instructions on http://caffe.berkeleyvision.org/installation.html#prerequisites
When compiling i get the following error:
(I use Fedora 22)
$make all
CXX src/caffe/data_transformer.cpp
In file included from ./include/caffe/blob.hpp:8:0,
from ./include/caffe/data_transformer.hpp:6,
from src/caffe/data_transformer.cpp:6:
./include/caffe/common.hpp:5:27: fatal error: gflags/gflags.h: No such file or directory
compilation terminated.
Makefile:516: recipe for target '.build_release/src/caffe/data_transformer.o' failed
make: *** [.build_release/src/caffe/data_transformer.o] Error 1
What am i doin wrong?
You have to install missing dependencies (gflags).
Fedora/RHEL/CentOS: sudo yum install gflags-devel
Ubuntu: sudo apt-get install libgflags-dev
There are also instructions for other dependencies:
Fedora/RHEL/CentOS :http://caffe.berkeleyvision.org/install_yum.html
Ubuntu: http://caffe.berkeleyvision.org/install_apt.html
To install missing gflag dependencies
wget https://github.com/schuhschuh/gflags/archive/master.zip
unzip master.zip
cd gflags-master
mkdir build && cd build
export CXXFLAGS="-fPIC" && cmake .. && make VERBOSE=1
make
sudo make install

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

Resources