usbmuxd: Update to latest git
[feed/packages.git] / lang / python / python-mysql / Makefile
1 #
2 # Copyright (C) 2007-2018 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=python-mysql
11 PKG_VERSION:=1.3.14
12 PKG_RELEASE:=1
13 PKG_LICENSE:=GPL-2.0
14
15 PKG_SOURCE:=mysqlclient-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=https://files.pythonhosted.org/packages/source/m/mysqlclient
17 PKG_HASH:=3981ae9ce545901a36a8b7aed76ed02960a429f75dc53b7ad77fb2f9ab7cd56b
18 PKG_BUILD_DIR:=$(BUILD_DIR)/$(BUILD_VARIANT)-mysql-$(PKG_VERSION)
19
20 include $(INCLUDE_DIR)/package.mk
21 include ../python-package.mk
22 include ../python3-package.mk
23 # python-mysql needs iconv
24 include $(INCLUDE_DIR)/nls.mk
25
26 PKG_UNPACK:=$(HOST_TAR) -C $(PKG_BUILD_DIR) --strip-components=1 -xzf $(DL_DIR)/$(PKG_SOURCE)
27
28 define Package/python-mysql/Default
29 SUBMENU:=Python
30 SECTION:=lang
31 CATEGORY:=Languages
32 URL:=https://pypi.python.org/project/mysqlclient
33 MAINTAINER:=Gergely Kiss <mail.gery@gmail.com>
34 endef
35
36 define Package/python-mysql
37 $(call Package/python-mysql/Default)
38 TITLE:=MySQL database adapter for Python
39 DEPENDS:=+PACKAGE_python-mysql:python +libmysqlclient
40 VARIANT:=python
41 endef
42
43 define Package/python3-mysql
44 $(call Package/python-mysql/Default)
45 TITLE:=MySQL database adapter for Python3
46 DEPENDS:=+PACKAGE_python3-mysql:python3 +libmysqlclient
47 VARIANT:=python3
48 endef
49
50 define Package/python-mysql/description
51 MySQLdb is an thread-compatible interface to the popular MySQL database
52 server that provides the Python database API.
53 endef
54
55 define Package/python3-mysql/description
56 $(call Package/python-mysql/description)
57 .
58 (Variant for Python3)
59 endef
60
61 $(eval $(call PyPackage,python-mysql))
62 $(eval $(call BuildPackage,python-mysql))
63
64 $(eval $(call Py3Package,python3-mysql))
65 $(eval $(call BuildPackage,python3-mysql))