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