Browse Source

python-psycopg2: added packages python-psycopg2 and python-egenix-mx-base as a dependency

Signed-off-by: Dmitrij Trefilov <the-alien@live.ru>
alien 9 years ago
parent
commit
6e7c45dc1c
2 changed files with 110 additions and 0 deletions
  1. 55
    0
      lang/python-egenix-mx-base/Makefile
  2. 55
    0
      lang/python-psycopg2/Makefile

+ 55
- 0
lang/python-egenix-mx-base/Makefile View File

@@ -0,0 +1,55 @@
1
+#
2
+# Copyright (C) 2015 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-egenix-mx-base
11
+PKG_VERSION:=3.2.8
12
+PKG_RELEASE:=1
13
+PKG_MAINTAINER:=Dmitry Trefilov <the-alien@live.ru>
14
+PKG_LICENSE:=eGenix.com Public License 1.1.0
15
+PKG_LICENSE_FILES:=LICENSE COPYRIGHT
16
+
17
+PKG_SOURCE:=egenix-mx-base-$(PKG_VERSION).tar.gz
18
+PKG_SOURCE_URL:=https://downloads.egenix.com/python/
19
+PKG_MD5SUM:=9d9d3a25f9dc051a15e97f452413423b
20
+
21
+PKG_BUILD_DIR:=$(BUILD_DIR)/egenix-mx-base-$(PKG_VERSION)
22
+PKG_BUILD_DEPENDS:=python
23
+
24
+include $(INCLUDE_DIR)/package.mk
25
+$(call include_mk, python-package.mk)
26
+
27
+define Package/python-egenix-mx-base
28
+  SUBMENU:=Python
29
+  SECTION:=lang
30
+  CATEGORY:=Languages
31
+  DEPENDS:=+USE_EGLIBC:librt +USE_UCLIBC:librt +python
32
+  TITLE:=Egenix mxBase
33
+  URL:=http://www.egenix.com/products/python/mxBase/
34
+endef
35
+
36
+define Package/python-egenix-mx-base/description
37
+ The eGenix.com mx Base Distribution for Python is a collection
38
+ of professional quality software tools which enhance Python's
39
+ usability in many important areas such as fast text searching,
40
+ date/time processing and high speed data types.
41
+endef
42
+
43
+define Build/Compile
44
+	$(call Build/Compile/PyMod,,install --prefix="$(PKG_INSTALL_DIR)/usr")
45
+endef
46
+
47
+define PyPackage/python-egenix-mx-base/install
48
+	$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
49
+	$(CP) \
50
+	    $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \
51
+	    $(1)$(PYTHON_PKG_DIR)
52
+endef
53
+
54
+$(eval $(call PyPackage,python-egenix-mx-base))
55
+$(eval $(call BuildPackage,python-egenix-mx-base))

+ 55
- 0
lang/python-psycopg2/Makefile View File

@@ -0,0 +1,55 @@
1
+#
2
+# Copyright (C) 2015 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-psycopg2
11
+PKG_VERSION:=2.6.1
12
+PKG_RELEASE:=1
13
+PKG_MAINTAINER:=Dmitry Trefilov <the-alien@live.ru>
14
+PKG_LICENSE:=LGPL-3.0+
15
+PKG_LICENSE_FILES:=LICENSE
16
+
17
+PKG_SOURCE:=psycopg2-$(PKG_VERSION).tar.gz
18
+PKG_SOURCE_URL:=http://initd.org/psycopg/tarballs/PSYCOPG-2-6/
19
+PKG_MD5SUM:=842b44f8c95517ed5b792081a2370da1
20
+
21
+PKG_BUILD_DIR:=$(BUILD_DIR)/psycopg2-$(PKG_VERSION)
22
+PKG_BUILD_DEPENDS:=python libpq python-setuptools
23
+
24
+include $(INCLUDE_DIR)/package.mk
25
+$(call include_mk, python-package.mk)
26
+
27
+define Package/python-psycopg2
28
+  SUBMENU:=Python
29
+  SECTION:=lang
30
+  CATEGORY:=Languages
31
+  TITLE:=PostgreSQL database adapter for Python
32
+  URL:=http://www.initd.org/
33
+  DEPENDS:=+python +libpq +python-egenix-mx-base
34
+endef
35
+
36
+define Package/python-psycopg2/description
37
+ This package contains is a PostgreSQL database adapter for the Python
38
+ programming language.
39
+endef
40
+
41
+define Build/Compile
42
+	$(call Build/Compile/PyMod,.,build_py)
43
+	$(call Build/Compile/PyMod,,build_ext --pg-config="$(STAGING_DIR)/usr/bin/pg_config")
44
+	$(call Build/Compile/PyMod,.,install --prefix=/usr --root=$(PKG_INSTALL_DIR))
45
+endef
46
+
47
+define Package/python-psycopg2/install
48
+	$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
49
+	$(CP) \
50
+	    $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \
51
+	    $(1)$(PYTHON_PKG_DIR)
52
+endef
53
+
54
+$(eval $(call PyPackage,python-psycopg2))
55
+$(eval $(call BuildPackage,python-psycopg2))