brektrou / rtl8821CU

Realtek RTL8811CU/RTL8821CU USB Wi-Fi adapter driver for Linux
GNU General Public License v2.0
1.59k stars 461 forks source link

Compile failed on kali linux 5.6.0 #80

Closed mk7120 closed 3 years ago

mk7120 commented 3 years ago

When I used 'make' command, it returned error like this. I'm new to linux and have tried to search on google but nothing works. Please help me. I'm using 5.6.0-kali2-amd64

/bin/sh: 1: bc: not found make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.6.0-kali2-amd64/build M=/root/build/rtl8821CU modules make[1]: Entering directory '/usr/src/linux-headers-5.6.0-kali2-amd64' /bin/sh: 1: bc: not found CC [M] /root/build/rtl8821CU/core/rtw_debug.o In file included from /root/build/rtl8821CU/include/drv_types.h:30, from /root/build/rtl8821CU/core/rtw_debug.c:17: /root/build/rtl8821CU/include/wifi.h:1032: warning: "IEEE80211_MAX_AMPDU_BUF" redefined 1032 #define IEEE80211_MAX_AMPDU_BUF 0x40
In file included from /root/build/rtl8821CU/include/osdep_service_linux.h:83, from /root/build/rtl8821CU/include/osdep_service.h:50, from /root/build/rtl8821CU/include/drv_types.h:27, from /root/build/rtl8821CU/core/rtw_debug.c:17: /usr/src/linux-headers-5.6.0-kali2-common/include/linux/ieee80211.h:1460: note: this is the location of the previous definition 1460 #define IEEE80211_MAX_AMPDU_BUF 0x100

/root/build/rtl8821CU/core/rtw_debug.c: In function ‘dump_drv_version’: /root/build/rtl8821CU/core/rtw_debug.c:45:62: error: macro "DATE" might prevent reproducible builds [-Werror=date-time] 45 | RTW_PRINT_SEL(sel, "build time: %s %s\n", DATE, TIME); | ^ In file included from /root/build/rtl8821CU/include/drv_types.h:60, from /root/build/rtl8821CU/core/rtw_debug.c:17: /root/build/rtl8821CU/core/rtw_debug.c:45:44: error: macro "TIME" might prevent reproducible builds [-Werror=date-time] 45 | RTW_PRINT_SEL(sel, "build time: %s %s\n", DATE, TIME); | ^~~~ /root/build/rtl8821CU/include/rtw_debug.h:114:34: note: in definition of macro ‘RTW_PRINT’ 114 | _dbgdump(DRIVER_PREFIX fmt, ##arg);\ | ^~~ /root/build/rtl8821CU/core/rtw_debug.c:45:2: note: in expansion of macro ‘RTW_PRINT_SEL’ 45 | RTW_PRINT_SEL(sel, "build time: %s %s\n", DATE, TIME); | ^~~~~ /root/build/rtl8821CU/core/rtw_debug.c:45:54: error: macro "DATE" might prevent reproducible builds [-Werror=date-time] 45 | RTW_PRINT_SEL(sel, "build time: %s %s\n", DATE, TIME); | ^~~~ /root/build/rtl8821CU/include/rtw_debug.h:114:34: note: in definition of macro ‘RTW_PRINT’ 114 | _dbgdump(DRIVER_PREFIX fmt, ##arg);\ | ^~~ /root/build/rtl8821CU/core/rtw_debug.c:45:2: note: in expansion of macro ‘RTW_PRINT_SEL’ 45 | RTW_PRINT_SEL(sel, "build time: %s %s\n", DATE, TIME); | ^~~~~ /root/build/rtl8821CU/core/rtw_debug.c:45:44: error: macro "TIME" might prevent reproducible builds [-Werror=date-time] 45 | RTW_PRINT_SEL(sel, "build time: %s %s\n", DATE, TIME); | ^~~~ /root/build/rtl8821CU/include/rtw_debug.h:224:25: note: in definition of macro ‘RTW_PRINT_SEL’ 224 | _seqdump(sel, fmt, ##arg) /rtw_warn_on(1)/; \ | ^~~ cc1: some warnings being treated as errors make[3]: [/usr/src/linux-headers-5.6.0-kali2-common/scripts/Makefile.build:273: /root/build/rtl8821CU/core/rtw_debug.o] Error 1 make[2]: [/usr/src/linux-headers-5.6.0-kali2-common/Makefile:1704: /root/build/rtl8821CU] Error 2 make[1]: [/usr/src/linux-headers-5.6.0-kali2-common/Makefile:180: sub-make] Error 2 make[1]: Leaving directory '/usr/src/linux-headers-5.6.0-kali2-amd64' make: [Makefile:2213: modules] Error 2

mk7120 commented 3 years ago

I just added bc by 'apt-get install bc' and it worked~~