summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 27150c87b283a5f34407ecc7cc8354a4f34f6583 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# Maintainer: Justin Dray <justin@dray.be>
# Contributor: Carl George <arch <at> cgtx.us>

pkgname=couchpotato
_pkgname=CouchPotato
pkgver=2.6.3
_fullname=CouchPotatoServer-build-${pkgver}
pkgrel=3
pkgdesc="Automatic Movie Downloading via NZBs & Torrent"
arch=('any')
url="http://couchpota.to/"
license=('GPL3')
depends=('python2')
install='couchpotato.install'
source=("https://github.com/RuudBurger/CouchPotatoServer/archive/build/${pkgver}.tar.gz"
        "${pkgname}.service"
	"${pkgname}-confd.conf"
	"${pkgname}.sh"
	"${pkgname}-tmpfiles.conf"
	'journal-logging.patch')
md5sums=('a2a39b1807828fd515ee71babc5a935d'
         '8fc7c9021900d0fa1fed20465232e322'
         '42ec6846a96efdf6524d7905b3f03393'
         '48126ad1674d4679c2a645dfb9d5a2c2'
         '95ebd431433b87d88c7a48cf0a32be7d'
         '0ae6398c412aed1c8983b42098831acb')

build() {
	patch -Np1 -i journal-logging.patch
}

package() {
  install -d "${pkgdir}/usr/lib/${pkgname}"
  install -d "${pkgdir}/var/lib/${pkgname}"

  cp -r "${srcdir}/${_fullname}/"* "${pkgdir}/usr/lib/${pkgname}"

  find "${pkgdir}/usr/lib/${pkgname}" -type d -exec chmod 755 {} \;
  find "${pkgdir}/usr/lib/${pkgname}" -type f -exec chmod 644 {} \;
  chmod 755 "${pkgdir}/usr/lib/${pkgname}/${_pkgname}.py"

  install -Dm755 "${srcdir}/${pkgname}.sh" "${pkgdir}/usr/bin/${pkgname}"
  install -Dm640 "${srcdir}/${pkgname}-confd.conf" "${pkgdir}/etc/conf.d/${pkgname}"
  install -Dm644 "${srcdir}/${pkgname}.service" "${pkgdir}/usr/lib/systemd/system/${pkgname}.service"
  install -Dm644 "${srcdir}/${pkgname}-tmpfiles.conf" "${pkgdir}/usr/lib/tmpfiles.d/${pkgname}.conf"
}