mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-18 22:06:04 +01:00
system/ipheth-driver: Added (iPhone USB Ethernet Driver)
Signed-off-by: dsomero <xgizzmo@slackbuilds.org>
This commit is contained in:
parent
6e01e00a8a
commit
c7088581e9
8 changed files with 161 additions and 0 deletions
14
system/ipheth-driver/README
Normal file
14
system/ipheth-driver/README
Normal file
|
@ -0,0 +1,14 @@
|
|||
This is a Linux Kernel driver that adds support for iPhone tethering through
|
||||
USB cables. Unlike other solutions out there, you don't need to jailbreak your
|
||||
phone or install third-party proxy applications.
|
||||
|
||||
Attention: The ipheth kernel module has been accepted upstream as of Apr 21
|
||||
2010 for kernel 2.6.34.
|
||||
|
||||
This module is still useful if you're running the stock Slackware kernel or
|
||||
the 2.6.33 tree. You still need an iPhone pairing program: this package will
|
||||
configure by default a modprobe helper based on ipheth-pair, an optional
|
||||
helper based on idevicepair from latest libimobiledevice releases is also
|
||||
provided.
|
||||
|
||||
This package requires ipheth-pair.
|
6
system/ipheth-driver/README.SLACKWARE
Normal file
6
system/ipheth-driver/README.SLACKWARE
Normal file
|
@ -0,0 +1,6 @@
|
|||
By default, this package will install a modprobe configuration which uses
|
||||
ipheth-pair as pairing program. Latest libimobiledevice releases ship with a
|
||||
copy of idevicepair. An alternate modprobe configuration file for the newer
|
||||
program is shipped too in this folder. If you're going to use it, you may also
|
||||
want to modify /etc/udev/rules.d/90-iphone-tether.rules and just keep in mind
|
||||
that this method hasn't been fully tested so YMMV :)
|
16
system/ipheth-driver/doinst.sh
Normal file
16
system/ipheth-driver/doinst.sh
Normal file
|
@ -0,0 +1,16 @@
|
|||
config() {
|
||||
NEW="$1"
|
||||
OLD="$(dirname $NEW)/$(basename $NEW .new)"
|
||||
# If there's no config file by that name, mv it over:
|
||||
if [ ! -r $OLD ]; then
|
||||
mv $NEW $OLD
|
||||
elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
|
||||
# toss the redundant copy
|
||||
rm $NEW
|
||||
fi
|
||||
# Otherwise, we leave the .new copy for the admin to consider...
|
||||
}
|
||||
|
||||
config etc/modprobe.d/ipheth.conf.new
|
||||
|
||||
chroot . /sbin/depmod -a @KERNEL@
|
81
system/ipheth-driver/ipheth-driver.SlackBuild
Normal file
81
system/ipheth-driver/ipheth-driver.SlackBuild
Normal file
|
@ -0,0 +1,81 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Slackware build script for ipheth-driver.
|
||||
#
|
||||
# Copyright 2010-2011 Marco Bonetti <sid77@slackware.it>
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use of this script, with or without modification, is
|
||||
# permitted provided that the following conditions are met:
|
||||
#
|
||||
# 1. Redistributions of this script must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED
|
||||
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
|
||||
# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
|
||||
# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
|
||||
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
|
||||
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
PRGNAM=ipheth-driver
|
||||
VERSION=${VERSION:-1.0}
|
||||
BUILD=${BUILD:-1}
|
||||
TAG=${TAG:-_SBo}
|
||||
|
||||
KERNEL=${KERNEL:-$(uname -r)}
|
||||
PKG_VERS=${VERSION}_$(echo $KERNEL | tr - _)
|
||||
|
||||
# Automatically determine the architecture we're building on:
|
||||
if [ -z "$ARCH" ]; then
|
||||
case "$( uname -m )" in
|
||||
i?86) ARCH=i486 ;;
|
||||
arm*) ARCH=arm ;;
|
||||
# Unless $ARCH is already set, use uname -m for all other archs:
|
||||
*) ARCH=$( uname -m ) ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
CWD=$(pwd)
|
||||
TMP=${TMP:-/tmp/SBo}
|
||||
PKG=${PKG:-$TMP/package-$PRGNAM}
|
||||
OUTPUT=${OUTPUT:-/tmp}
|
||||
|
||||
DOCS="$CWD/README.SLACKWARE $CWD/ipheth.conf.idevicepair"
|
||||
|
||||
set -e
|
||||
|
||||
rm -rf $PKG
|
||||
mkdir -p $TMP $PKG $OUTPUT
|
||||
cd $TMP
|
||||
rm -rf $PRGNAM-$VERSION
|
||||
tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
|
||||
cd $PRGNAM-$VERSION
|
||||
chown -R root:root .
|
||||
find . \
|
||||
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
|
||||
-exec chmod 755 {} \; -o \
|
||||
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
|
||||
-exec chmod 644 {} \;
|
||||
|
||||
make
|
||||
|
||||
mkdir -p $PKG/lib/modules/$KERNEL/extra
|
||||
install -m 0644 ipheth.ko $PKG/lib/modules/$KERNEL/extra/
|
||||
mkdir -p $PKG/etc/modprobe.d/
|
||||
install -m 0644 $CWD/ipheth.conf.ipheth-pair $PKG/etc/modprobe.d/ipheth.conf.new
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$PKG_VERS
|
||||
install -m 0644 $DOCS $PKG/usr/doc/$PRGNAM-$PKG_VERS
|
||||
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$PKG_VERS/$PRGNAM.SlackBuild
|
||||
|
||||
mkdir -p $PKG/install
|
||||
cat $CWD/slack-desc > $PKG/install/slack-desc
|
||||
sed "s%@KERNEL@%$KERNEL%" $CWD/doinst.sh > $PKG/install/doinst.sh
|
||||
|
||||
cd $PKG
|
||||
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$PKG_VERS-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
|
10
system/ipheth-driver/ipheth-driver.info
Normal file
10
system/ipheth-driver/ipheth-driver.info
Normal file
|
@ -0,0 +1,10 @@
|
|||
PRGNAM="ipheth-driver"
|
||||
VERSION="1.0"
|
||||
HOMEPAGE="http://giagio.com/wiki/moin.cgi/iPhoneEthernetDriver"
|
||||
DOWNLOAD="http://slackbuilds.org/sources/13.1/ipheth-driver-1.0.tar.bz2"
|
||||
MD5SUM="cb6a3358da60aa2c94b21ba258aa03a0"
|
||||
DOWNLOAD_x86_64=""
|
||||
MD5SUM_x86_64=""
|
||||
MAINTAINER="Marco Bonetti"
|
||||
EMAIL="sid77@slackware.it"
|
||||
APPROVED="dsomero"
|
8
system/ipheth-driver/ipheth.conf.idevicepair
Normal file
8
system/ipheth-driver/ipheth.conf.idevicepair
Normal file
|
@ -0,0 +1,8 @@
|
|||
# iPhone USB Ethernet Driver
|
||||
#
|
||||
# This configuration forces modprobe to execute device pairing after loading
|
||||
# the driver and device unpairing before removing it.
|
||||
|
||||
install ipheth /sbin/modprobe --ignore-install ipheth && /usr/bin/idevicepair pair
|
||||
remove ipheth /usr/bin/idevicepair unpair && /sbin/modprobe -r --ignore-remove ipheth
|
||||
|
7
system/ipheth-driver/ipheth.conf.ipheth-pair
Normal file
7
system/ipheth-driver/ipheth.conf.ipheth-pair
Normal file
|
@ -0,0 +1,7 @@
|
|||
# iPhone USB Ethernet Driver
|
||||
#
|
||||
# This configuration forces modprobe to execute device pairing after loading
|
||||
# the driver.
|
||||
|
||||
install ipheth /sbin/modprobe --ignore-install ipheth && /lib/udev/ipheth-pair
|
||||
|
19
system/ipheth-driver/slack-desc
Normal file
19
system/ipheth-driver/slack-desc
Normal file
|
@ -0,0 +1,19 @@
|
|||
# HOW TO EDIT THIS FILE:
|
||||
# The "handy ruler" below makes it easier to edit a package description. Line
|
||||
# up the first '|' above the ':' following the base package name, and the '|'
|
||||
# on the right side marks the last column you can put a character in. You must
|
||||
# make exactly 11 lines for the formatting to be correct. It's also
|
||||
# customary to leave one space after the ':'.
|
||||
|
||||
|-----handy-ruler------------------------------------------------------|
|
||||
ipheth-driver: ipheth-driver (iPhone USB Ethernet Driver)
|
||||
ipheth-driver:
|
||||
ipheth-driver: This is a Linux Kernel driver that adds support for iPhone tethering
|
||||
ipheth-driver: through USB cables. Unlike other solutions out there, you don't need
|
||||
ipheth-driver: to jailbreak your phone or install third-party proxy applications.
|
||||
ipheth-driver:
|
||||
ipheth-driver: This driver has been accepted into 2.6.34+ kernels so it's only useful
|
||||
ipheth-driver: if you're running on older versions.
|
||||
ipheth-driver:
|
||||
ipheth-driver: http://giagio.com/wiki/moin.cgi/iPhoneEthernetDriver
|
||||
ipheth-driver:
|
Loading…
Reference in a new issue