summaryrefslogtreecommitdiff
path: root/packages/net/homeassistant/homeassistant-0.51.2.exheres-0
diff options
context:
space:
mode:
Diffstat (limited to 'packages/net/homeassistant/homeassistant-0.51.2.exheres-0')
-rw-r--r--packages/net/homeassistant/homeassistant-0.51.2.exheres-0242
1 files changed, 242 insertions, 0 deletions
diff --git a/packages/net/homeassistant/homeassistant-0.51.2.exheres-0 b/packages/net/homeassistant/homeassistant-0.51.2.exheres-0
new file mode 100644
index 0000000..d637b92
--- /dev/null
+++ b/packages/net/homeassistant/homeassistant-0.51.2.exheres-0
@@ -0,0 +1,242 @@
+# Copyright 2016-2017 Timo Gurr <tgurr@exherbo.org>
+# Distributed under the terms of the GNU General Public License v2
+
+require pypi setup-py [ import=setuptools has_bin=true multibuild=false blacklist="2 3.3" test=pytest ] \
+ systemd-service
+
+SUMMARY="Open-source home automation platform running on Python 3"
+DESCRIPTION="
+The goal of Home Assistant is to be able to track and control all devices at home and offer a
+platform for automating control.
+"
+HOMEPAGE+=" https://home-assistant.io"
+
+LICENCES="Apache-2.0"
+SLOT="0"
+PLATFORMS="~amd64"
+MYOPTIONS=""
+
+# Need to figure out
+RESTRICT="test"
+
+DEPENDENCIES="
+ build+run:
+ group/${PN}
+ user/${PN}
+ dev-python/Jinja2[>=2.9.5][python_abis:*(-)?]
+ dev-python/PyYAML[>=3.11&<4][python_abis:*(-)?]
+ dev-python/aiohttp[>=2.2.5][python_abis:*(-)?]
+ dev-python/astral[>=1.4][python_abis:*(-)?]
+ dev-python/async-timeout[>=1.2.1][python_abis:*(-)?]
+ dev-python/chardet[>=3.0.4][python_abis:*(-)?]
+ dev-python/pip[>=8.0.3][python_abis:*(-)?]
+ dev-python/pytz[>=2017.2][python_abis:*(-)?]
+ dev-python/requests[>=2.14.2&<3][python_abis:*(-)?]
+ dev-python/voluptuous[>=0.10.5][python_abis:*(-)?]
+ python_abis:3.4? (
+ dev-python/typing[>=3&<4][python_abis:3.4]
+ )
+ run:
+ dev-python/SQLAlchemy[>=1.1.13][python_abis:*(-)?]
+ dev-python/aiohttp-cors[>=0.5.3][python_abis:*(-)?]
+ dev-python/distro[>=1.0.4][python_abis:*(-)?]
+ dev-python/fuzzywuzzy[>=0.15.1][python_abis:*(-)?]
+ dev-python/netdisco[>=1.1.0][python_abis:*(-)?]
+ dev-python/xmltodict[>=0.11.0][python_abis:*(-)?]
+ suggestion:
+ app-speech/svox [[
+ description = [ Required for Home Assistant component: tts.picotts ]
+ ]]
+ dev-python/PyChromecast[>=0.8.2][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: media_player.cast ]
+ ]]
+ dev-python/beautifulsoup4[>=4.6.0][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: device_tracker.linksys_ap, sensor.geizhals, sensor.scrape ]
+ ]]
+ dev-python/jsonrpc-async[>=0.6][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: media_player.kodi, notify.kodi ]
+ ]]
+ dev-python/jsonrpc-websocket[>=0.5][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: media_player.kodi ]
+ ]]
+ dev-python/limitlessled[>=1.0.8][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: light.limitlessled ]
+ ]]
+ dev-python/mutagen[>=1.38][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: tts ]
+ ]]
+ dev-python/paho-mqtt[>=1.3.0][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: mqtt, shiftr ]
+ ]]
+ dev-python/psutil[>=5.2.2][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: sensor.systemmonitor ]
+ ]]
+ dev-python/pylast[>=1.9.0][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: sensor.lastfm ]
+ ]]
+ dev-python/python-mpd2[>=0.5.5][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: media_player.mpd ]
+ ]]
+ dev-python/python-nmap[>=0.6.1][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: device_tracker.nmap_tracker ]
+ ]]
+ dev-python/snapcast[>=2.0.6][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: media_player.snapcast ]
+ ]]
+ dev-python/spotipy[>=2.4.4][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: media_player.spotify ]
+ ]]
+ dev-python/wakeonlan[>=0.2.2][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: media_player.panasonic_viera, media_player.samsungtv, media_player.webostv, switch.wake_on_lan ]
+ ]]
+ dev-python/zeroconf[>=0.19.1][python_abis:*(-)?] [[
+ description = [ Required for Home Assistant component: zeroconf ]
+ ]]
+ sys-apps/net-tools [[
+ description = [ Required for Home Assistant component: device_tracker.nmap_tracker ]
+ ]]
+ net-misc/iputils [[
+ description = [ Required for Home Assistant component: switch.wake_on_lan ]
+ ]]
+"
+
+src_prepare() {
+ setup-py_src_prepare
+
+ # Setup
+ # typing is included in Python >= 3.5
+ if [[ $(python_get_abi) == 3.5 ]] || [[ $(python_get_abi) == 3.6 ]] ; then
+ edo sed \
+ -e "/typing/d" \
+ -i setup.py
+ fi
+ # can be more recent
+ edo sed \
+ -e 's:requests==2.14.2:requests>=2.14.2:g' \
+ -e 's:voluptuous==0.10.5:voluptuous>=0.10.5:g' \
+ -e 's:aiohttp==2.2.5:aiohttp>=2.2.5:g' \
+ -e 's:async_timeout==1.2.1:async_timeout>=1.2.1:g' \
+ -e 's:chardet==3.0.4:chardet>=3.0.4:g' \
+ -e 's:astral==1.4:astral>=1.4:g' \
+ -i homeassistant/package_constraints.txt \
+ -i setup.py
+
+ # Core components
+ # homeassistant.components.recorder
+ # homeassistant.scripts.db_migrator
+ edo sed \
+ -e 's:sqlalchemy==1.1.13:sqlalchemy>=1.1.13:g' \
+ -i homeassistant/components/recorder/__init__.py
+ # homeassistant.components.emulated_hue
+ # homeassistant.components.http
+ edo sed \
+ -e 's:aiohttp_cors==0.5.3:aiohttp_cors>=0.5.3:g' \
+ -i homeassistant/components/__init__.py
+ # homeassistant.components.updater
+ edo sed \
+ -e 's:distro==1.0.4:distro>=1.0.4:g' \
+ -i homeassistant/components/updater.py
+ # homeassistant.components.sensor.swiss_hydrological_data
+ # homeassistant.components.sensor.ted5000
+ # homeassistant.components.sensor.yr
+ edo sed \
+ -e 's:xmltodict==0.11.0:xmltodict>=0.11.0:g' \
+ -i homeassistant/components/sensor/{swiss_hydrological_data,ted5000,yr}.py
+ # homeassistant.components.conversation
+ edo sed \
+ -e 's:fuzzywuzzy==0.15.1:fuzzywuzzy>=0.15.1:g' \
+ -i homeassistant/components/conversation.py
+ # homeassistant.components.discovery
+ edo sed \
+ -e 's:netdisco==1.1.0:netdisco>=1.1.0:g' \
+ -i homeassistant/components/discovery.py
+
+ # Additional components
+ # homeassistant.components.media_player.cast
+ edo sed \
+ -e 's:pychromecast==0.8.2:pychromecast>=0.8.2:g' \
+ -i homeassistant/components/media_player/cast.py
+ # homeassistant.components.device_tracker.linksys_ap
+ # homeassistant.components.sensor.scrape
+ edo sed \
+ -e 's:beautifulsoup4==4.6.0:beautifulsoup4>=4.6.0:g' \
+ -i homeassistant/components/device_tracker/linksys_ap.py \
+ -i homeassistant/components/sensor/scrape.py
+ # homeassistant.components.media_player.kodi
+ # homeassistant.components.notify.kodi
+ edo sed \
+ -e 's:jsonrpc-async==0.6:jsonrpc-async>=0.6:g' \
+ -i homeassistant/components/media_player/kodi.py
+ # homeassistant.components.media_player.kodi
+ edo sed \
+ -e 's:jsonrpc-websocket==0.5:jsonrpc-websocket>=0.5:g' \
+ -i homeassistant/components/media_player/kodi.py
+ # homeassistant.components.light.limitlessled
+ edo sed \
+ -e 's:limitlessled==1.0.8:limitlessled>=1.0.8:g' \
+ -i homeassistant/components/light/limitlessled.py
+ # homeassistant.components.tts
+ edo sed \
+ -e 's:mutagen==1.38.0:mutagen>=1.38.0:g' \
+ -i homeassistant/components/tts/__init__.py
+ # homeassistant.components.mqtt
+ # homeassistant.components.shiftr
+ edo sed \
+ -e 's:paho-mqtt==1.3.0:paho-mqtt>=1.3.0:g' \
+ -i homeassistant/components/mqtt/__init__.py \
+ -i homeassistant/components/shiftr.py
+ # homeassistant.components.sensor.systemmonitor
+ edo sed \
+ -e 's:psutil==5.2.2:psutil>=5.2.2:g' \
+ -i homeassistant/components/sensor/systemmonitor.py
+ # homeassistant.components.sensor.lastfm
+ edo sed \
+ -e 's:pylast==1.9.0:pylast>=1.9.0:g' \
+ -i homeassistant/components/sensor/lastfm.py
+ # homeassistant.components.media_player.mpd
+ edo sed \
+ -e 's:python-mpd2==0.5.5:python-mpd2>=0.5.5:g' \
+ -i homeassistant/components/media_player/mpd.py
+ # homeassistant.components.device_tracker.nmap_tracker
+ edo sed \
+ -e 's:python-nmap==0.6.1:python-nmap>=0.6.1:g' \
+ -i homeassistant/components/device_tracker/nmap_tracker.py
+ # homeassistant.components.media_player.snapcast
+ edo sed \
+ -e 's:snapcast==2.0.6:snapcast>=2.0.6:g' \
+ -i homeassistant/components/media_player/snapcast.py
+ # homeassistant.components.media_player.spotify
+ edo sed \
+ -e "s:.*REQUIREMENTS.*:REQUIREMENTS = ['spotipy>=2.4.4']:g" \
+ -e '/spotipy==2.4.4/d' \
+ -i homeassistant/components/media_player/spotify.py
+ # homeassistant.components.wake_on_lan
+ # homeassistant.components.media_player.panasonic_viera
+ # homeassistant.components.media_player.samsungtv
+ # homeassistant.components.media_player.webostv
+ # homeassistant.components.switch.wake_on_lan
+ edo sed \
+ -e 's:wakeonlan==0.2.2:wakeonlan>=0.2.2:g' \
+ -i homeassistant/components/wake_on_lan.py \
+ -i homeassistant/components/media_player/{panasonic_viera,samsungtv,webostv}.py \
+ -i homeassistant/components/switch/wake_on_lan.py
+ # homeassistant.components.zeroconf
+ edo sed \
+ -e 's:zeroconf==0.19.1:zeroconf>=0.19.1:g' \
+ -i homeassistant/components/zeroconf.py
+}
+
+src_install() {
+ setup-py_src_install
+
+ keepdir /var/lib/homeassistant
+ edo chown homeassistant:homeassistant "${IMAGE}"/var/lib/homeassistant
+
+ install_systemd_files
+}
+
+pkg_postinst() {
+ einfo "After upgrading Home Assistant to a newer version run the database migrator:"
+ einfo "su -c \"hass --script db_migrator --config /var/lib/homeassistant\" -s /bin/bash homeassistant"
+}
+