make fails on Debian 11.7 Kernel 5.10.0-25-amd64 with error: redefinition of ‘eth_hw_addr_set’
m-bach opened this issue · 3 comments
m-bach commented
Mo 11. Sep 12:30:03 CEST 2023
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.10.0-25-amd64/build M=/var/lib/dkms/rtl8192eu/1.0/build modules
make[1]: Verzeichnis „/usr/src/linux-headers-5.10.0-25-amd64“ wird betreten
CC [M] /var/lib/dkms/rtl8192eu/1.0/build/core/rtw_cmd.o
In file included from /var/lib/dkms/rtl8192eu/1.0/build/include/osdep_service.h:45,
from /var/lib/dkms/rtl8192eu/1.0/build/include/drv_types.h:27,
from /var/lib/dkms/rtl8192eu/1.0/build/core/rtw_cmd.c:17:
/var/lib/dkms/rtl8192eu/1.0/build/include/osdep_service_linux.h:222:20: error: redefinition of ‘eth_hw_addr_set’
222 | static inline void eth_hw_addr_set(struct net_device *dev, const u8 *addr)
| ^~~~~~~~~~~~~~~
In file included from /var/lib/dkms/rtl8192eu/1.0/build/include/osdep_service_linux.h:45,
from /var/lib/dkms/rtl8192eu/1.0/build/include/osdep_service.h:45,
from /var/lib/dkms/rtl8192eu/1.0/build/include/drv_types.h:27,
from /var/lib/dkms/rtl8192eu/1.0/build/core/rtw_cmd.c:17:
/usr/src/linux-headers-5.10.0-25-common/include/linux/etherdevice.h:309:20: note: previous definition of ‘eth_hw_addr_set’ was here
309 | static inline void eth_hw_addr_set(struct net_device *dev, const u8 *addr)
| ^~~~~~~~~~~~~~~
make[3]: *** [/usr/src/linux-headers-5.10.0-25-common/scripts/Makefile.build:291: /var/lib/dkms/rtl8192eu/1.0/build/core/rtw_cmd.o] Fehler 1
make[2]: *** [/usr/src/linux-headers-5.10.0-25-common/Makefile:1856: /var/lib/dkms/rtl8192eu/1.0/build] Fehler 2
make[1]: *** [/usr/src/linux-headers-5.10.0-25-common/Makefile:192: __sub-make] Fehler 2
make[1]: Verzeichnis „/usr/src/linux-headers-5.10.0-25-amd64“ wird verlassen
make: *** [Makefile:2287: modules] Fehler 2
It looks like eth_hw_addr_set
is already defined in the kernel headers.
CGarces commented
There is code to avoid that
rtl8192eu-linux-driver/include/osdep_service_linux.h
Lines 220 to 226 in f2fc8af
Looks like the patch has been backported in debian?
Naoow commented
There is code to avoid that
rtl8192eu-linux-driver/include/osdep_service_linux.h
Lines 220 to 226 in f2fc8af
Looks like the patch has been backported in debian?
Hi, removing that code before building fixed it in debian. Thanks a lot!
jeremyb31 commented
The fix is to git checkout eth_hw_addr_set_fix after changing into the rtl8192eu-linux-driver directory