Guest User

Untitled

a guest
Oct 10th, 2021
71
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. diff --git a/PKGBUILD b/PKGBUILD
  2. index 48b081b..34f648c 100644
  3. --- a/PKGBUILD
  4. +++ b/PKGBUILD
  5. @@ -9,33 +9,33 @@ url='https://github.com/linux-surface/surface-control'
  6.  license=('MIT')
  7.  arch=('x86_64')
  8.  depends=('gcc-libs' 'systemd-libs')
  9. -makedepends=('rust' 'cargo' 'systemd-libs')
  10. +makedepends=('rust' 'cargo' 'systemd')
  11.  
  12.  
  13.  source=(
  14. -    "${pkgname}::git+https://github.com/linux-surface/surface-control.git#tag=v${pkgver}-${_pkgrel}"
  15. +    "${pkgname}-${pkgver}-${_pkgrel}.tar.gz::https://github.com/linux-surface/surface-control/archive/refs/tags/v${pkgver}-${_pkgrel}.tar.gz"
  16.  )
  17.  
  18.  sha256sums=('SKIP')
  19.  
  20.  build(){
  21. -    cd "${srcdir}/${pkgname}"
  22. +    cd "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}"
  23.      env CARGO_TARGET_DIR="target" CARGO_INCREMENTAL=0 cargo build --release --locked
  24.      strip --strip-all "target/release/surface"
  25.  }
  26.  
  27.  package() {
  28. -    install -D -m755 "${srcdir}/${pkgname}/target/release/surface" "$pkgdir/usr/bin/surface"
  29. +    install -D -m755 "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}/target/release/surface" "$pkgdir/usr/bin/surface"
  30.  
  31.      # copy system files
  32. -    install -D -m644 "${srcdir}/${pkgname}/etc/sysusers/surface-control.conf" "${pkgdir}/usr/lib/sysusers.d/surface-control.conf"
  33. -    install -D -m644 "${srcdir}/${pkgname}/etc/udev/40-surface-control.rules" "${pkgdir}/usr/lib/udev/rules.d/40-surface-control.rules"
  34. +    install -D -m644 "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}/etc/sysusers/surface-control.conf" "${pkgdir}/usr/lib/sysusers.d/surface-control.conf"
  35. +    install -D -m644 "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}/etc/udev/40-surface-control.rules" "${pkgdir}/usr/lib/udev/rules.d/40-surface-control.rules"
  36.  
  37.      # completion files
  38. -    install -D -m644 "${srcdir}/${pkgname}/target/surface.bash" "$pkgdir/usr/share/bash-completion/completions/surface"
  39. -    install -D -m644 "${srcdir}/${pkgname}/target/_surface" "$pkgdir/usr/share/zsh/site-functions/_surface"
  40. -    install -D -m644 "${srcdir}/${pkgname}/target/surface.fish" "$pkgdir/usr/share/fish/completions/surface.fish"
  41. +    install -D -m644 "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}/target/surface.bash" "$pkgdir/usr/share/bash-completion/completions/surface"
  42. +    install -D -m644 "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}/target/_surface" "$pkgdir/usr/share/zsh/site-functions/_surface"
  43. +    install -D -m644 "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}/target/surface.fish" "$pkgdir/usr/share/fish/completions/surface.fish"
  44.  
  45.      # license
  46. -    install -Dm644 "${srcdir}/${pkgname}/LICENSE" "${pkgdir}/usr/share/licenses/surface-control/LICENSE"
  47. +    install -Dm644 "${srcdir}/${pkgname}-${pkgver}-${_pkgrel}/LICENSE" "${pkgdir}/usr/share/licenses/surface-control/LICENSE"
  48.  }
RAW Paste Data