# Maintainer: Fabian Affolter pkgname=home-assistant _pkgname=homeassistant pkgver=0.33.3 pkgrel=0 pkgdesc="A Home automation platform" url="https://home-assistant.io" arch="all" license="MIT" depends="py3-requests py3-yaml py3-tz py3-jinja2 py3-voluptuous py3-async-timeout" makedepends="python3-dev" subpackages="$pkgname-aiohttp" pkgusers="hass" pkggroups="hass" install="$pkgname.pre-install" source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz update-deps.patch $pkgname.initd $pkgname.confd" builddir="$srcdir"/$_pkgname-$pkgver # NOTE: https://github.com/home-assistant/home-assistant/issues/4288 # hass needs aiohttp at older version then available in aports # this should be fixed upstream after which this can be moved to community _ver_aiohttp=1.0.5 _builddir_aiohttp="$srcdir/aiohttp-$_ver_aiohttp" depends="$depends $pkgname-aiohttp" source="$source https://files.pythonhosted.org/packages/source/a/aiohttp/aiohttp-$_ver_aiohttp.tar.gz" build() { cd "$builddir" python3 setup.py build || return 1 cd "$_builddir_aiohttp" python3 setup.py build || return 1 } package() { cd "$builddir" python3 setup.py install \ --root="$pkgdir" --prefix=/usr --optimize=1 || return 1 install -Dm 755 "$srcdir/$pkgname".initd \ "$pkgdir"/etc/init.d/hass || return 1 install -Dm 644 "$srcdir/$pkgname".confd \ "$pkgdir"/etc/conf.d/hass || return 1 } aiohttp() { pkgdesc="$pkgdesc (aiohttp dependency)" depends="python3 py3-async-timeout py3-chardet py3-multidict py3-yarl !py3-aiohttp" cd "$_builddir_aiohttp" python3 setup.py install \ --root="$subpkgdir" --prefix=/usr --optimize=1 || return 1 } md5sums="967d4c16becbdd99ef0fb34d718b7efc homeassistant-0.33.3.tar.gz 14cd39ae5fc2e0ecd744022963554a0c update-deps.patch f98b4840a76b5cee70b2f825cfb26103 home-assistant.initd c0e33f27528af255c50c3bdfdf22098f home-assistant.confd 488026a1c1e716741842403b7b9f030a aiohttp-1.0.5.tar.gz" sha256sums="87e09608a98eebc532d079c9894fd6a123070b53b6f608542abab4e201486e86 homeassistant-0.33.3.tar.gz dc19ea6037f6a738d3614a122e55fe0b6c2a55686855372e659de9bb25e7d97e update-deps.patch 3518ebc275eee3041ff2821a83b7bb6151990b37c4512b0497874a9eb6b28cc8 home-assistant.initd bff3fc8c883662661646e17d3c46e5a01bded42b67cf6ef60242a1c7dca8de96 home-assistant.confd c3e1897726f97d40e067e8b658b2dbdfe216f32b801c5c589212e1b1f9aa8388 aiohttp-1.0.5.tar.gz" sha512sums="8191d38653897ef978f7bb262b555a468e51fd924781bd223420ea47eb7d3d21014f84f00d2ae9d071eead6bb0b1bf65433ae5e12b58af4241b5991e063b29bd homeassistant-0.33.3.tar.gz 0c3287e9861e67ff97a9ccea60d57c6a772707a43cfa016f056832688bf776cc3df92c34e2f0dfb017a0566792331c1e6f4318db4845e283435f7422b4df6cdc update-deps.patch 34b8387836490228d94f6836bd0222812285d0a1161225b47b03c1398526f235c2ef2180ebaf0a81fe59165230467b5ad75eb06b3349175ef655da9bd00acd8e home-assistant.initd 3cba0923944c01557d99baee2bdd906d198c831ab34c77242574ed6bcc4545326a42133983ec6bd18b7ae15e4329355cc604fdf016a9324d85d6e8e527691f41 home-assistant.confd db5661b77b90eaecf04d80cebc1023ec7930bd639aed075d24291f897784d040ccc3fc5f9db310a3886f1661a0d163aaf42a8c5549b566027e890df42bb1bc0d aiohttp-1.0.5.tar.gz"