Merge pull request #2253 from adamg-xda/le90_rtl8189fs_driver

RTL8189FS: new driver package
This commit is contained in:
MilhouseVH 2017-11-27 01:24:00 +00:00 committed by GitHub
commit b2b4133326
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -0,0 +1,55 @@
################################################################################
# This file is part of LibreELEC - https://libreelec.tv
# Copyright (C) 2017-present Team LibreELEC
#
# LibreELEC is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of the License, or
# (at your option) any later version.
#
# LibreELEC is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with LibreELEC. If not, see <http://www.gnu.org/licenses/>.
################################################################################
PKG_NAME="RTL8189FS"
PKG_VERSION="ab83abd"
PKG_SHA256="fab9511aaaa95e9764c76847ec418745bbb52f0751f3e17a51f84a6e3d4533cc"
PKG_ARCH="any"
PKG_LICENSE="GPL"
PKG_SITE="https://github.com/khadas/android_hardware_wifi_realtek_drivers_8189ftv"
PKG_URL="https://github.com/khadas/android_hardware_wifi_realtek_drivers_8189ftv/archive/$PKG_VERSION.tar.gz"
PKG_SOURCE_DIR="android_hardware_wifi_realtek_drivers_8189ftv-$PKG_VERSION*"
PKG_DEPENDS_TARGET="toolchain linux"
PKG_NEED_UNPACK="$LINUX_DEPENDS"
PKG_SECTION="driver"
PKG_SHORTDESC="Realtek RTL8189FS Linux 3.x driver"
PKG_LONGDESC="Realtek RTL8189FS Linux 3.x driver"
PKG_IS_KERNEL_PKG="yes"
PKG_TOOLCHAIN="manual"
post_unpack() {
sed -i 's/-DCONFIG_CONCURRENT_MODE//g; s/^CONFIG_POWER_SAVING.*$/CONFIG_POWER_SAVING = n/g; s/^CONFIG_RTW_DEBUG.*/CONFIG_RTW_DEBUG = n/g' $PKG_BUILD/*/Makefile
sed -i 's/^#define CONFIG_DEBUG.*//g' $PKG_BUILD/*/include/autoconf.h
}
pre_make_target() {
unset LDFLAGS
}
make_target() {
make -C $(kernel_path) M=$PKG_BUILD/rtl8189FS \
ARCH=$TARGET_KERNEL_ARCH \
KSRC=$(kernel_path) \
CROSS_COMPILE=$TARGET_PREFIX \
USER_EXTRA_CFLAGS="-fgnu89-inline"
}
makeinstall_target() {
mkdir -p $INSTALL/$(get_full_module_dir)/$PKG_NAME
cp $PKG_BUILD/rtl8189FS/*.ko $INSTALL/$(get_full_module_dir)/$PKG_NAME
}