blob: e39714c0218c5d5c048c78c3ef5158c6920b0b73 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
#
# Copyright (C) 2007-2008 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:=psycopg
PKG_VERSION:=1.1.21
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=http://www.initd.org/pub/software/psycopg/
PKG_MD5SUM:=a31f79f68d6d32898d6f24e11369a106
PKG_BUILD_DEPENDS:=python
include $(INCLUDE_DIR)/package.mk
$(call include_mk, python-package.mk)
define Package/python-psycopg
SUBMENU:=Python
SECTION:=lang
CATEGORY:=Languages
TITLE:=PostgreSQL database adapter for Python
URL:=http://www.initd.org/
DEPENDS:=+python-mini +libpq +python-egenix-mx
endef
define Package/python-psycopg/description
This package contains is a PostgreSQL database adapter for the Python
programming language.
endef
CONFIGURE_ARGS += \
--with-python="$(PYTHON)" \
--with-postgres-libraries="$(STAGING_DIR)/usr/lib" \
--with-postgres-includes="$(STAGING_DIR)/usr/include" \
--with-mxdatetime-includes="$(STAGING_DIR)$(PYTHON_PKG_DIR)/mx/DateTime/mxDateTime" \
--with-python-prefix=$(STAGING_DIR)/usr
--with-python-exec-prefix=$(STAGING_DIR)/usr
define Build/Compile
$(if $(Build/Compile/PyMod),,@echo Python packaging code not found.; false)
$(MAKE) -C $(PKG_BUILD_DIR) \
OPT="$(TARGET_CFLAGS)"
endef
define PyPackage/python-psycopg/install
$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
$(INSTALL_BIN) $(PKG_BUILD_DIR)/psycopgmodule.so $(1)$(PYTHON_PKG_DIR)/
endef
$(eval $(call PyPackage,python-psycopg))
$(eval $(call BuildPackage,python-psycopg))
|