-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(solution found) Cannot compile on CentOS7 3.10.0-1160.42.2.el7.x86_64 #86
Comments
Hello wimein, Thanks for the report. I took a look at make.log and the other information you provided. My conclusion: I need to convince you to replace CentOS7 with a supported OS. Kernel 3.10 went End of Life in 2017. To work on this issue I would need to install CentOS7 and I simply do not have time to do that given everything else that is on my to-do list. As a general rule, I do not work on issues that come up with kernels that are End of Life. If you would be so kind as to tell me what software you intend to use, what CPU, amount of RAM and amount of storage that your computer has, I can make a recommendation for a more modern Linux distro for you to install. Regards, Nick |
Hi Nick, Thank you very much for your reply. The 3.10 kernel is indeed old, but CentOS 7 is still supported and will be until 2024. As we are quite happy with CentOS we consider moving to CentOS 8 Stream. But even the current CentOS 8 kernel version (4.18.0) has reached end of life, so it seems there is no chance to get your driver running on any existing recent CentOS distribution? It would be great if your driver could be compiled on any of the recent CentOS family members. Regards, Winfried |
Winfried, I am pondering the situation. Let me throw out some thoughts to see what might be a good option in your eyes:
https://github.com/morrownr/USB-WiFi
Installing CentOS 7 and getting this driver going on it would take far more time than I have available but maybe I can help you find a solution. |
You could consider running a 5.4 or 5.14 kernel from the elrepo repository ( http://elrepo.org/tiki/HomePage ). The package names are kernel-lt and kernel-ml respectively. I've been using the elrepo kernels for years. It's hard to compile modules against the CentOS 7 kernels because of all the patches Redhat does to the kernel |
That explains a lot. The make.log was a mess. 5.4 is a LTS kernel so I would recommend it for a test if you decide to try the above suggestion. If the 5.4 kernel in the elrepo repo is generic or close to it, you might very well see a clean compile. |
Every time I have looked at the package source, they have been generic kernels and your code compiles cleanly against them. I have been using your code with the elrepo LTS kernel as the access point on my home router for a while now (since I got tired of trying to patch another Realtek adaptation to compile myself and found this one). Thanks for all your work by the way. |
Hey, I appreciate you stopping by to help the OP. Hopefully we can help him find a solution. Glad that this driver is working well for you. It keeps me busy working on this driver and 4 more plus the USB-WiFi repo. |
Thank you both for help and support. WLAN on that machine does work. Authentication via MSCHAPv2 against some Linux RADIUS server succeeds (tunneled TLS/MSCHAPv2/no certificate), authentication against a Windows 2019 RADIUS server succeeds, as well (authentication via PEAP/MSCHAPv2/no certificate). Thank you very much again. |
I forgot one important step for Centos 7. You need to install gcc 9. If you search for and install the packages: devtoolset-9-gcc devtoolset-9-binutils devtoolset-9-runtime, and activate it before compile with |
You can find the gcc 9 packages at https://centos.pkgs.org/7/centos-sclo-rh-x86_64/ |
Or |
Compiling the driver on CentOS7 using gcc 9 sounds great, but unfortunately doesn't fully work. [root@ms01 88x2bu]# yum install -y centos-release-scl [root@ms01 88x2bu]# ./install-driver.sh Running install-driver.sh version 20210725 Kernel preparation unnecessary for this kernel. Skipping... Building module: The machine is fully updated and is booted into kernel-mt kernel. |
Whew. That is a really messy make.log file. The pain level is growing. Let me reiterate an earlier suggestion. https://github.com/morrownr/USB-WiFi That repo has information and links to around 70 usb wifi adapters that are supported by in-kernel drivers. ALL adapters at that site are supported from kernel 4.19 on. There are adapters at that repo that are supported with kernel 3.10. Here is the deal. If Red Hat's patches had triggered compiler problems with the in-kernel drivers, those doing the patches would have known immediately and would have taken appropriate action. On the other hand, those doing the patches would not know that they are blowing up these Realtek drivers because these Realtek drivers are out-of-kernel. Additionally, these Realtek drivers are not Linux Wireless standards compliant and that is a BIG DEAL! I put warnings here in these Realtek repos warning Linux users that these Realtek repos are here to help those that are new to Linux and want to keep existing Realtek adapters going and I STRONGLY recommend users to not buy Realtek adapters. The USB-WiFi repo has more info on this subject. I'll turn rant mode off now. |
Those errors are consistent with compiling with gcc 4.8.5. From the module source directory try |
Enabling gcc 9 with @morrownr : Kudos for a great summary of supported devices, I probably would have been better off to buy a different stick. |
I have never used the install_driver.sh script or the dkms system. If you don't want to install the module by hand on each kernel update, I am using the akmods system which automatically recompiles the module and creates and installes a new rpm package containing the module on each kernel update. If anyone is interested, I will clean up the SPEC file and post it here. |
This is what I've done to make this work: yum install -y git centos-release-scl kernel-lt kernel-lt-devel --enablerepo=elrepo-kernel reboot into 5.4.148-1 kernel mkdir ~/WLAN reboot into 5.4.148-1 kernel. WLAN does work as expected. So in summary, I could successfully compile the 88x2bu driver on CentOS 7 and also get it running with the kernel-lt kernel. Thank you again for your support! |
I can't get it complied on my CentOS 7 box:
[root@lukas 88x2bu]# ./install-driver.sh
Running install-driver.sh version 20210725
Starting installation.
Copying source files to: /usr/src/rtl88x2bu-5.8.7.4
Copying 88x2bu.conf to: /etc/modprobe.d
Creating symlink /var/lib/dkms/rtl88x2bu/5.8.7.4/source -> /usr/src/rtl88x2bu-5.8.7.4
Kernel preparation unnecessary for this kernel. Skipping...
Building module:
cleaning build area...
'make' -j4 KVER=3.10.0-1160.42.2.el7.x86_64 KSRC=/lib/modules/3.10.0-1160.42.2.el7.x86_64/build......(bad exit status: 2)
Error! Bad return status for module build on kernel: 3.10.0-1160.42.2.el7.x86_64 (x86_64)
Consult /var/lib/dkms/rtl88x2bu/5.8.7.4/build/make.log for more information.
An error occurred. dkms build error = 10
Please report this error.
[root@lukas dkms]# uname -a
Linux lukas.box 3.10.0-1160.42.2.el7.x86_64 #1 SMP Tue Sep 7 14:49:57 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
[root@lukas dkms]# lsusb
...
Bus 003 Device 002: ID 2357:012d TP-Link Archer T3U [Realtek RTL8812BU]
...
[root@lukas dkms]#
###############################
/var/lib/dkms/rtl88x2bu/5.8.7.4/build/make.log
make.log
##############################
Please help ...
The text was updated successfully, but these errors were encountered: