Browse Source

Initial commit

pull/1/head
ektor5 10 years ago
commit
ed33b1429a
3 changed files with 66 additions and 0 deletions
  1. +43
    -0
      PKGBUILD
  2. +12
    -0
      init-headphone.install
  3. +11
    -0
      init-headphone.service

+ 43
- 0
PKGBUILD View File

@ -0,0 +1,43 @@
# Maintainer: Ettore Chimenti <ek5.chimenti @ gmail.com>
pkgname="init-headphone"
pkgver="0.2.0"
pkgrel=1
epoch=
pkgdesc="Re-enables headphone jack after sleep/suspend resume on VIA VT1802"
arch=("any")
url="https://bugs.launchpad.net/ubuntu/+source/alsa-driver/+bug/1313904/"
license=('GPL')
groups=()
depends=("dmidecode" "python2-smbus" "python")
makedepends=()
checkdepends=()
optdepends=()
provides=()
conflicts=()
replaces=()
backup=()
options=()
install=init-headphone.install
changelog=
source=("https://bugs.launchpad.net/ubuntu/+source/alsa-driver/+bug/1313904/+attachment/4361090/+files/${pkgname}_${pkgver}_all.deb"
"init-headphone.service"
"init-headphone.install"
)
noextract=()
md5sums=('37c830340c4ca077271a04b4436ea8fc'
'8eaf6ff36bfe0927aec5677cb17fbbcc'
'a47855a948f9684ea69db75f2cdd7398')
validpgpkeys=()
package() {
tar -xf data.tar.xz -C $pkgdir
mv $pkgdir/usr/{s,}bin
rm -r $pkgdir/etc/init
mkdir -p $pkgdir/etc/systemd/system
cp init-headphone.service $pkgdir/etc/systemd/system
}

+ 12
- 0
init-headphone.install View File

@ -0,0 +1,12 @@
post_install() {
echo ">>> Please enable the service unit via 'systemctl enable init-headphone.service' "
echo ">>> Also add 'acpi_enforce_resources=lax' to kernel bootargs and reboot"
}
post_upgrade() {
post_install
}
post_remove() {
post_install
}

+ 11
- 0
init-headphone.service View File

@ -0,0 +1,11 @@
[Unit]
Description=Reactivate headphones after sleep
After=sleep.target
[Service]
Type=oneshot
ExecStart=/usr/sbin/init-headphone
[Install]
WantedBy=sleep.target

Loading…
Cancel
Save