I'm trying to compile the driver provided with a Ralink 5370 usb wifi adapter I bought, for Lubuntu 14.4.1 (32bit version). I'm running 3.16.0-24-generic kernel.
The header file is giving a type conversion error when I try to compile using sudo make as per the general procedure here:
/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c: In function ‘rt_ioctl_giwscan’:
./arch/x86/include/asm/string_32.h:182:25: warning: array subscript is below array bounds [-Warray-bounds]
#define memcpy(t, f, n) __builtin_memcpy(t, f, n)
^
include/net/iw_handler.h:542:3: note: in expansion of macro ‘memcpy’
memcpy(stream + point_len, extra, iwe->u.data.length);
^
CC [M] /home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/rt_linux.o
/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/rt_linux.c: In function ‘__RtmpOSFSInfoChange’:
/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/rt_linux.c:1126:20: error: incompatible types when assigning to type ‘int’ from type ‘kuid_t’
pOSFSInfo->fsuid = current_fsuid();
^
/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/rt_linux.c:1127:20: error: incompatible types when assigning to type ‘int’ from type ‘kgid_t’
pOSFSInfo->fsgid = current_fsgid();
^
scripts/Makefile.build:257: recipe for target '/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/rt_linux.o' failed
make[2]: *** [/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/rt_linux.o] Error 1
Makefile:1345: recipe for target '_module_/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux' failed
make[1]: *** [_module_/home/username/wifidriver/2011_0719_RT3070_RT3370_RT5370_RT5372_Linux_STA_V2.5.0.3_DPO/os/linux] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-3.16.0-24-generic'
Makefile:356: recipe for target 'LINUX' failed
make: *** [LINUX] Error 2
Relevant output from lsusb
Bus 001 Device 002: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
How should I be approaching this? This compiler error looks odd enough for me to question whether I should be delving into it; i.e. if my time would be better spent some other way.