mirror of
https://github.com/coolsnowwolf/packages
synced 2025-01-09 04:37:41 +08:00
homeassistant: fix package depend
This commit is contained in:
parent
9ee2a1b83f
commit
03ebd36cba
76
lang/python/homeassistant/Makefile
Normal file
76
lang/python/homeassistant/Makefile
Normal file
@ -0,0 +1,76 @@
|
||||
#
|
||||
# Copyright (C) 2019 CZ.NIC, z. s. p. o. (https://www.nic.cz/)
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=homeassistant
|
||||
PKG_VERSION:=0.98.1
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://files.pythonhosted.org/packages/source/h/homeassistant
|
||||
PKG_HASH:=7f8a6a011cf1cf2254a471f0eae1bedaad6dba1dcf3ab67f453d9a80d73ee477
|
||||
|
||||
PKG_MAINTAINER:=Josef Schlehofer <pepe.schlehofer@gmail.com>
|
||||
PKG_LICENSE:=MIT
|
||||
PKG_LICENSE_FILES:=LICENSE.md
|
||||
PKG_CPE_ID:=cpe:/a:home-assistant:home-assistant
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include ../python3-package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=utils
|
||||
CATEGORY:=Utilities
|
||||
TITLE:=Home Assistant
|
||||
URL:=https://www.home-assistant.io/
|
||||
DEPENDS:= \
|
||||
+python3-aiohttp \
|
||||
+python3-aiohttp-cors \
|
||||
+python3-astral \
|
||||
+python3-async-timeout \
|
||||
+python3-attrs \
|
||||
+python3-bcrypt \
|
||||
+python3-certifi \
|
||||
+python3-cryptography \
|
||||
+python3-ifaddr \
|
||||
+python3-importlib-metadata \
|
||||
+python3-jinja2 \
|
||||
+python3-netdisco \
|
||||
+python3-pip \
|
||||
+python3-pyjwt \
|
||||
+python3-pyotp \
|
||||
+python3-pytz \
|
||||
+python3-slugify \
|
||||
+python3-sqlalchemy \
|
||||
+python3-requests \
|
||||
+python3-ruamel-yaml \
|
||||
+python3-voluptuous \
|
||||
+python3-voluptuous-serialize \
|
||||
+python3-yaml \
|
||||
+python3-zeroconf
|
||||
VARIANT:=python3
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description
|
||||
Home Assistant is a home automation platform running on Python 3.
|
||||
It is able to track and control all devices at home and offer a platform for automating control.
|
||||
|
||||
It requires a minimum of 1 GB of RAM.
|
||||
endef
|
||||
|
||||
define Py3Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) ./files/hass.init $(1)/etc/init.d/hass
|
||||
endef
|
||||
|
||||
$(eval $(call Py3Package,$(PKG_NAME)))
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)-src))
|
18
lang/python/homeassistant/files/hass.init
Normal file
18
lang/python/homeassistant/files/hass.init
Normal file
@ -0,0 +1,18 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
|
||||
USE_PROCD=1
|
||||
START=99
|
||||
STOP=10
|
||||
|
||||
PROG=/usr/bin/hass
|
||||
CONF=/srv/homeassistant
|
||||
|
||||
start_service() {
|
||||
mkdir -m 0755 -p "$CONF"
|
||||
procd_open_instance
|
||||
procd_set_param command "$PROG" -c "$CONF"
|
||||
procd_set_param respawn
|
||||
procd_set_param stdout 1
|
||||
procd_set_param stderr 1
|
||||
procd_close_instance
|
||||
}
|
@ -0,0 +1,41 @@
|
||||
From 465eafb111ba3d987f9821cf2af5c309479ceca7 Mon Sep 17 00:00:00 2001
|
||||
From: Josef Schlehofer <pepe.schlehofer@gmail.com>
|
||||
Date: Tue, 20 Aug 2019 21:41:10 +0200
|
||||
Subject: [PATCH] Upgrade ruamel_yaml to 0.15.100
|
||||
|
||||
https://github.com/home-assistant/home-assistant/pull/26095
|
||||
|
||||
---
|
||||
homeassistant/package_constraints.txt | 2 +-
|
||||
setup.py | 2 +-
|
||||
3 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/homeassistant/package_constraints.txt b/homeassistant/package_constraints.txt
|
||||
index 74ffb83f8..2bee5de79 100644
|
||||
--- a/homeassistant/package_constraints.txt
|
||||
+++ b/homeassistant/package_constraints.txt
|
||||
@@ -20,7 +20,7 @@ python-slugify==3.0.3
|
||||
pytz>=2019.01
|
||||
pyyaml==5.1.1
|
||||
requests==2.22.0
|
||||
-ruamel.yaml==0.15.99
|
||||
+ruamel.yaml==0.15.100
|
||||
sqlalchemy==1.3.5
|
||||
voluptuous-serialize==2.1.0
|
||||
voluptuous==0.11.5
|
||||
|
||||
diff --git a/setup.py b/setup.py
|
||||
index 01288c01b..5ab8d74c6 100755
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -48,7 +48,7 @@ REQUIRES = [
|
||||
"pytz>=2019.01",
|
||||
"pyyaml==5.1.1",
|
||||
"requests==2.22.0",
|
||||
- "ruamel.yaml==0.15.99",
|
||||
+ "ruamel.yaml==0.15.100",
|
||||
"voluptuous==0.11.5",
|
||||
"voluptuous-serialize==2.1.0",
|
||||
]
|
||||
--
|
||||
2.20.1
|
40
lang/python/python-importlib-metadata/Makefile
Normal file
40
lang/python/python-importlib-metadata/Makefile
Normal file
@ -0,0 +1,40 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=python-importlib_metadata
|
||||
PKG_VERSION:=0.18
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=importlib_metadata-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://files.pythonhosted.org/packages/source/i/importlib_metadata
|
||||
PKG_HASH:=cb6ee23b46173539939964df59d3d72c3e0c1b5d54b84f1d8a7e912fe43612db
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/importlib_metadata-$(PKG_VERSION)
|
||||
|
||||
PKG_MAINTAINER:=Paul Spooren <mail@aparcar.org>
|
||||
PKG_LICENSE:=Apache-2.0
|
||||
PKG_LICENSE_FILES:=LICENSE
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include ../python3-package.mk
|
||||
|
||||
define Package/python3-importlib-metadata
|
||||
SECTION:=lang
|
||||
CATEGORY:=Languages
|
||||
SUBMENU:=Python
|
||||
TITLE:=Read metadata from Python packages
|
||||
URL:=https://gitlab.com/python-devs/importlib_metadata
|
||||
DEPENDS=+python3-light +python3-zipp
|
||||
VARIANT:=python3
|
||||
endef
|
||||
|
||||
PYTHON3_PKG_SETUP_VARS:= \
|
||||
PKG_VERSION="$(PKG_VERSION)"
|
||||
|
||||
define Package/python3-importlib-metadata/description
|
||||
importlib_metadata is a library to access the metadata for a Python package.
|
||||
It is intended to be ported to Python 3.8.
|
||||
endef
|
||||
|
||||
$(eval $(call Py3Package,python3-importlib-metadata))
|
||||
$(eval $(call BuildPackage,python3-importlib-metadata))
|
||||
$(eval $(call BuildPackage,python3-importlib-metadata-src))
|
@ -0,0 +1,8 @@
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -1,3 +1,4 @@
|
||||
from setuptools import setup
|
||||
+import os
|
||||
|
||||
-setup(use_scm_version=True)
|
||||
+setup(version=os.getenv('PKG_VERSION'))
|
37
lang/python/python3-zipp/Makefile
Normal file
37
lang/python/python3-zipp/Makefile
Normal file
@ -0,0 +1,37 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=zipp
|
||||
PKG_VERSION:=0.5.2
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://files.pythonhosted.org/packages/source/z/zipp/
|
||||
PKG_HASH:=4970c3758f4e89a7857a973b1e2a5d75bcdc47794442f2e2dd4fe8e0466e809a
|
||||
|
||||
PKG_MAINTAINER:=Paul Spooren <mail@aparcar.org>
|
||||
PKG_LICENSE:=MIT
|
||||
PKG_LICENSE_FILES:=LICENSE
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include ../python3-package.mk
|
||||
|
||||
define Package/python3-zipp
|
||||
SECTION:=lang
|
||||
CATEGORY:=Languages
|
||||
SUBMENU:=Python
|
||||
TITLE:=Zipfile object wrapper
|
||||
URL:=https://github.com/jaraco/zipp
|
||||
DEPENDS:=+python3-light
|
||||
VARIANT:=python3
|
||||
endef
|
||||
|
||||
PYTHON3_PKG_SETUP_VARS:= \
|
||||
PKG_VERSION="$(PKG_VERSION)"
|
||||
|
||||
define Package/python3-zipp/description
|
||||
Backport of pathlib-compatible object wrapper for zip files
|
||||
endef
|
||||
|
||||
$(eval $(call Py3Package,python3-zipp))
|
||||
$(eval $(call BuildPackage,python3-zipp))
|
||||
$(eval $(call BuildPackage,python3-zipp-src))
|
11
lang/python/python3-zipp/patches/001-fix-scm-version.patch
Normal file
11
lang/python/python3-zipp/patches/001-fix-scm-version.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -1,6 +1,7 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
import setuptools
|
||||
+import os
|
||||
|
||||
if __name__ == "__main__":
|
||||
- setuptools.setup(use_scm_version=True)
|
||||
+ setuptools.setup(version=os.getenv('PKG_VERSION'))
|
Loading…
Reference in New Issue
Block a user