#
# Copyright (C) 2015-2016 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#

include $(TOPDIR)/rules.mk

PKG_NAME:=pydbus
VERSION_MAJOR:=0.6.0
PKG_VERSION:=$(VERSION_MAJOR)

PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://github.com/LEW21/pydbus/archive/refs/tags/v0.6.0.tar.gz
PKG_MD5SUM:=929cbae07aad76a709ff59be51f9e853
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)

PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE.rst
PKG_MAINTAINER:=Jeffery To <jeffery.to@gmail.com>

include $(INCLUDE_DIR)/package.mk
include $(TOPDIR)/feeds/packages/lang/python/python-package.mk

PKG_UNPACK:=$(HOST_TAR) -C $(PKG_BUILD_DIR) --strip-components=1 -xzf $(DL_DIR)/$(PKG_SOURCE)
TARGET_CFLAGS += -fpermissive

define Package/pydbus
	SECTION:=lang
	CATEGORY:=Languages
	SUBMENU:=Python
	TITLE:=pygattlib
	URL:=https://github.com/kjd/crcmod
	DEPENDS:=+python-light +glib2
	VARIANT:=python
endef

define Package/pydbus-src
	SECTION:=lang
	CATEGORY:=Languages
	SUBMENU:=Python
	TITLE:=pybluez src
	URL:=https://github.com/kjd/crcmod
	DEPENDS:=+python-light +glib2
	VARIANT:=python
endef

define Package/pydbus/description
A library to support the Internationalised Domain Names in Applications
(snap7) protocol as specified in RFC 5891. This version of the protocol
is often referred to as "snap72008" and can produce different results
from the earlier standard from 2003.
endef


$(eval $(call PyPackage,pydbus))
$(eval $(call BuildPackage,pydbus))
$(eval $(call BuildPackage,pydbus-src))
