package created using the webbuild interface [release 20150731git-1mamba;Fri Jul 31 2015]

This commit is contained in:
Silvan Calarco 2024-01-06 07:21:43 +01:00
parent 6846d119d5
commit 876a0befd6
3 changed files with 92 additions and 0 deletions

View File

@ -1,2 +1,4 @@
# mt7601
Linux driver for MT7601U with patch for stability and performance on recent kernel versions.

View File

@ -0,0 +1,10 @@
--- mt7601-20150731git/src/common/rtusb_dev_id.c.orig 2015-07-31 23:03:17.334358446 +0200
+++ mt7601-20150731git/src/common/rtusb_dev_id.c 2015-07-31 23:04:29.462448996 +0200
@@ -39,6 +39,7 @@
{USB_DEVICE(0x148f,0x6570)}, /* Ralink 6570 */
#endif /* RT6570 */
{USB_DEVICE(0x148f, 0x7650)}, /* MT7650 */
+ {USB_DEVICE(0x2001, 0x3d04)}, /* D-Link */
#ifdef MT7601U
{USB_DEVICE(0x148f,0x6370)}, /* Ralink 6370 */
{USB_DEVICE(0x148f,0x7601)}, /* MT 6370 */

80
mt7601.spec Normal file
View File

@ -0,0 +1,80 @@
Name: mt7601
Version: 20150731git
Release: 1mamba
Summary: Linux driver for MT7601U with patch for stability and performance on recent kernel versions
Group: System/Kernel and Hardware
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://github.com/porjo/mt7601.git
## GITSOURCE https://github.com/porjo/mt7601.git master
Source: https://github.com/porjo/mt7601.git/master/mt7601-%{version}.tar.bz2
Patch0: mt7601-20150731git-add_device_2001_3D04.patch
License: GPL
## AUTOBUILDREQ-BEGIN
## AUTOBUILDREQ-END
Requires(post):kernelheaders
Requires(post):dkms
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
Linux driver for MT7601U with patch for stability and performance on recent kernel versions.
%debug_package
%prep
%setup -q
%patch0 -p1
%build
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
# dkms for vboxvideo
install -d -m0755 %{buildroot}%{_prefix}/src/%{name}-%{version}
cp -a src/* %{buildroot}%{_prefix}/src/%{name}-%{version}/
cat > %{buildroot}%{_prefix}/src/%{name}-%{version}/dkms.conf << _EOF
PACKAGE_NAME=%{name}
PACKAGE_VERSION=%{version}
MAKE="make LINUX_SRC=\"\${kernel_source_dir}\""
CLEAN="make LINUX_SRC=\"\${kernel_source_dir}\" clean"
BUILT_MODULE_NAME=mt7601Usta
BUILT_MODULE_LOCATION=./os/linux/
DEST_MODULE_LOCATION=/extra/drivers/net/wireless/
REMAKE_INITRD=no
AUTOINSTALL=yes
_EOF
install -d -m 0755 %{buildroot}%{_sysconfdir}/Wireless/RT2870STA/
cp src/RT2870STA.dat %{buildroot}%{_sysconfdir}/Wireless/RT2870STA/
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%preun
# erase
if [ $1 -eq 0 ]; then
dkms remove -q -m %{name} -v %{version} --all
fi
:
%post
if [ $1 -ge 1 ]; then
dkms add -q -m %{name} -v %{version}
dkms install -q -m %{name} -v %{version} --force
fi
:
%files
%defattr(-,root,root)
%{_sysconfdir}/Wireless/RT2870STA/RT2870STA.dat
%{_prefix}/src/%{name}-%{version}/dkms.conf
%dir %{_prefix}/src/%{name}-%{version}/
%{_prefix}/src/%{name}-%{version}/*
%doc LICENSE
%changelog
* Fri Jul 31 2015 Silvan Calarco <silvan.calarco@mambasoft.it> 20150731git-1mamba
- package created using the webbuild interface