From c7b88424c09da90c5514d1ebe5a79577a4505429 Mon Sep 17 00:00:00 2001 From: Stefan Saraev Date: Thu, 2 Jan 2014 19:27:25 +0200 Subject: [PATCH] Revert "remove package 'tbs-linux-drivers'" This reverts commit 244c8fab2da40588ed85383e362600ce9ff28a06. --- .../linux-drivers/tbs-linux-drivers/build | 35 +++++++++++++++++ .../linux-drivers/tbs-linux-drivers/install | 27 +++++++++++++ packages/linux-drivers/tbs-linux-drivers/meta | 34 +++++++++++++++++ .../linux-drivers/tbs-linux-drivers/unpack | 38 +++++++++++++++++++ 4 files changed, 134 insertions(+) create mode 100755 packages/linux-drivers/tbs-linux-drivers/build create mode 100755 packages/linux-drivers/tbs-linux-drivers/install create mode 100644 packages/linux-drivers/tbs-linux-drivers/meta create mode 100755 packages/linux-drivers/tbs-linux-drivers/unpack diff --git a/packages/linux-drivers/tbs-linux-drivers/build b/packages/linux-drivers/tbs-linux-drivers/build new file mode 100755 index 0000000000..123b626a63 --- /dev/null +++ b/packages/linux-drivers/tbs-linux-drivers/build @@ -0,0 +1,35 @@ +#!/bin/sh + +################################################################################ +# This file is part of OpenELEC - http://www.openelec.tv +# Copyright (C) 2009-2014 Stephan Raue (stephan@openelec.tv) +# +# OpenELEC 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. +# +# OpenELEC 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 OpenELEC. If not, see . +################################################################################ + +. config/options $1 + +cd $BUILD/${PKG_NAME}-${PKG_VERSION}/linux-tbs-drivers + +[ "$TARGET_ARCH" = "i386" ] && ./v4l/tbs-x86_r3.sh +[ "$TARGET_ARCH" = "x86_64" ] && ./v4l/tbs-x86_64.sh + +LDFLAGS="" make DIR=$(kernel_path) prepare + +# TODO: removee me after 3 or 4 tbs driver versions +#for cfg in CONFIG_VIDEO_SH_MOBILE_CEU CONFIG_VIDEO_SH_MOBILE_CSI2 ; do +# sed -i -e "s|^$cfg=.*$|# $cfg is not set|" v4l/.config +#done + +LDFLAGS="" make DIR=$(kernel_path) diff --git a/packages/linux-drivers/tbs-linux-drivers/install b/packages/linux-drivers/tbs-linux-drivers/install new file mode 100755 index 0000000000..f65bd2705e --- /dev/null +++ b/packages/linux-drivers/tbs-linux-drivers/install @@ -0,0 +1,27 @@ +#!/bin/sh + +################################################################################ +# This file is part of OpenELEC - http://www.openelec.tv +# Copyright (C) 2009-2014 Stephan Raue (stephan@openelec.tv) +# +# OpenELEC 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. +# +# OpenELEC 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 OpenELEC. If not, see . +################################################################################ + +. config/options $1 + +mkdir -p $INSTALL/lib/modules/`kernel_version`/updates/tbs +find $BUILD/${PKG_NAME}-${PKG_VERSION}/linux-tbs-drivers/ -name \*.ko -exec cp {} $INSTALL/lib/modules/`kernel_version`/updates/tbs \; + +mkdir -p $INSTALL/lib/firmware/ +cp $BUILD/${PKG_NAME}-${PKG_VERSION}/*.fw $INSTALL/lib/firmware/ diff --git a/packages/linux-drivers/tbs-linux-drivers/meta b/packages/linux-drivers/tbs-linux-drivers/meta new file mode 100644 index 0000000000..cdb96585e8 --- /dev/null +++ b/packages/linux-drivers/tbs-linux-drivers/meta @@ -0,0 +1,34 @@ +################################################################################ +# This file is part of OpenELEC - http://www.openelec.tv +# Copyright (C) 2009-2014 Stephan Raue (stephan@openelec.tv) +# +# OpenELEC 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. +# +# OpenELEC 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 OpenELEC. If not, see . +################################################################################ + +PKG_NAME="tbs-linux-drivers" +PKG_VERSION="130802" +PKG_REV="1" +PKG_ARCH="any" +PKG_LICENSE="GPL" +PKG_SITE="http://www.tbsdtv.com/english/Download.html" +PKG_URL="http://www.tbsdtv.com/download/document/common/tbs-linux-drivers_v${PKG_VERSION}.zip" +PKG_DEPENDS="" +PKG_BUILD_DEPENDS="toolchain linux" +PKG_NEED_UNPACK="$LINUX_DEPENDS" +PKG_PRIORITY="optional" +PKG_SECTION="driver" +PKG_SHORTDESC="Linux TBS tuner drivers" +PKG_LONGDESC="Linux TBS tuner drivers" +PKG_IS_ADDON="no" +PKG_AUTORECONF="no" diff --git a/packages/linux-drivers/tbs-linux-drivers/unpack b/packages/linux-drivers/tbs-linux-drivers/unpack new file mode 100755 index 0000000000..26cbf8b77c --- /dev/null +++ b/packages/linux-drivers/tbs-linux-drivers/unpack @@ -0,0 +1,38 @@ +#!/bin/sh + +################################################################################ +# This file is part of OpenELEC - http://www.openelec.tv +# Copyright (C) 2009-2014 Stephan Raue (stephan@openelec.tv) +# +# OpenELEC 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. +# +# OpenELEC 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 OpenELEC. If not, see . +################################################################################ + +. config/options $1 + +ZIP_PKG="`echo $PKG_URL | sed 's%.*/\(.*\)$%\1%'`" + +mkdir -p $BUILD/${PKG_NAME}-${PKG_VERSION} + +# unzip main archive +unzip $SOURCES/$1/$ZIP_PKG -d $BUILD/${PKG_NAME}-${PKG_VERSION} >/dev/null 2>&1 +# extract .tar.bz2 +tar xjf $BUILD/${PKG_NAME}-${PKG_VERSION}/linux-tbs-drivers.tar.bz2 -C $BUILD/${PKG_NAME}-${PKG_VERSION} +# fix permissions +chmod -R u+rwX $BUILD/${PKG_NAME}-${PKG_VERSION}/linux-tbs-drivers/* + +for patch in `ls $PKG_DIR/patches.upstream/*.patch`; do + cat $patch | patch -d \ + `echo $BUILD/$PKG_NAME-$PKG_VERSION | cut -f1 -d\ ` -p1 +done +