wok-6.x diff hardware-ibm-6272/receipt @ rev 13973

Up: xorg-xf86-video-intel (2.21.0)
author Alexander Medvedev <devl547@gmail.com>
date Wed Feb 06 02:13:32 2013 +0000 (2013-02-06)
parents
children 7bb096863642
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/hardware-ibm-6272/receipt	Wed Feb 06 02:13:32 2013 +0000
     1.3 @@ -0,0 +1,47 @@
     1.4 +# SliTaz package receipt.
     1.5 +
     1.6 +PACKAGE="hardware-ibm-6272"
     1.7 +VERSION="1.0"
     1.8 +CATEGORY="base-system"
     1.9 +MAINTAINER="devel@slitaz.org"
    1.10 +SHORT_DESC="IBM 300GL 6272/6282 (P75-233 ISA/PCI/USB/ETH desktop) hardware support"
    1.11 +WEB_SITE="http://www.slitaz.org/"
    1.12 +
    1.13 +DEPENDS="isapnptools"
    1.14 +
    1.15 +# Rules to gen a SliTaz package suitable for Tazpkg.
    1.16 +genpkg_rules()
    1.17 +{
    1.18 +	mkdir -p $fs/etc/init.d
    1.19 +	cat > $fs/etc/init.d/pnp.sh <<EOT
    1.20 +#!/bin/sh
    1.21 +
    1.22 +status="\\\\033[70G[ \\\\033[1;31mFailed\\\\033[0;39m ]"
    1.23 +echo -n "Switching on isa pnp ethernet card "
    1.24 +# io 0x360..0x250 by 0x10, irq 15 12 11 10 9 7 6 5 4 3
    1.25 +for io in \$(seq 360 -10 250); do for irq in 15 12 11 10; do
    1.26 +pnpdump | busybox awk "BEGIN {s=0} \\
    1.27 +/CONFIGURE CSC6040/ {s=1} { \\
    1.28 +  if (s==0) print; \\
    1.29 +  else if (/INT 0/) print \\"(INT 0 (IRQ \$irq (MODE +E)))\\"; \\
    1.30 +  else if (/IO 0/) print \\"(IO 0 (SIZE 16) (BASE 0x0\$io) (CHECK))\\"; \\
    1.31 +  else if (/ACT Y/) { s=0; print \\"(ACT Y)\\"} \\
    1.32 +  else print \\
    1.33 +}" > /etc/isapnp.conf
    1.34 +if isapnp /etc/isapnp.conf > /dev/null 2>&1 ; then
    1.35 +  modprobe cs89x0 io=0x\$io irq=\$irq > /dev/null 2>&1
    1.36 +  status="\\\\033[70G[ \\\\033[1;33mOK\\\\033[0;39m ]"
    1.37 +  break 2
    1.38 +fi
    1.39 +done ; done
    1.40 +echo -e "\$status"
    1.41 +EOT
    1.42 +	chmod +x $fs/etc/init.d/pnp.sh
    1.43 +}
    1.44 +
    1.45 +# Pre and post install commands for Tazpkg.
    1.46 +post_install()
    1.47 +{
    1.48 +	grep pnp.sh $1/etc/rcS.conf ||
    1.49 +	sed -i 's/RUN_SCRIPTS="/&pnp.sh /' $1/etc/rcS.conf
    1.50 +}