868643bb6498c199c55f720a256e322521a66ce1
[openwrt/svn-archive/archive.git] / lang / pymysql / Makefile
1 #
2 # Copyright (C) 2007 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=MySQL-python
12 PKG_VERSION:=1.2.2
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=@SF/mysql-python
17 PKG_MD5SUM:=532268f02870bea18c1d465e88afff30
18 PKG_BUILD_DEPENDS:=python
19
20 include $(INCLUDE_DIR)/package.mk
21 -include $(if $(DUMP),,$(STAGING_DIR)/mk/python-package.mk)
22 ifeq ($(DUMP)$(Build/Compile/PyMod),)
23 $(error Python packaging code not found.)
24 endif
25
26 define Package/python-mysql
27 SECTION:=lang
28 CATEGORY:=Languages
29 TITLE:=MySQL database adapter for Python
30 URL:=http://mysql-python.sourceforge.net/
31 DEPENDS:=python-core +libmysqlclient
32 endef
33
34 define Package/python-mysql/description
35 MySQLdb is an thread-compatible interface to the popular MySQL database
36 server that provides the Python database API.
37 endef
38
39 define PyPackage/python-mysql/filespec
40 +|$(PYTHON_PKG_DIR)/_mysql.so
41 +|$(PYTHON_PKG_DIR)/_mysql_exceptions.py*
42 +|$(PYTHON_PKG_DIR)/MySQLdb
43 endef
44
45 define Build/Compile
46 $(call Build/Compile/PyMod,., \
47 install --prefix="$(PKG_INSTALL_DIR)/usr", \
48 )
49 endef
50
51 $(eval $(call PyPackage,python-mysql))
52 $(eval $(call BuildPackage,python-mysql))