1746bbf5de610a7414d2ed527a194023f56307e9
[openwrt/svn-archive/archive.git] / lang / pysqlite / 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 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=pysqlite
12 PKG_VERSION:=2.3.5
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=http://initd.org/pub/software/pysqlite/releases/2.3/2.3.5/
17 PKG_MD5SUM:=b4a185e936848370fcc1a5b17755b641
18
19 PKG_BUILD_DEPENDS:=python
20
21 include $(INCLUDE_DIR)/package.mk
22 -include $(if $(DUMP),,$(STAGING_DIR)/mk/python-package.mk)
23
24 define Package/python-sqlite
25 SUBMENU:=Python
26 SECTION:=lang
27 CATEGORY:=Languages
28 TITLE:=SQLite database adapter for Python
29 URL:=http://www.initd.org/tracker/pysqlite/wiki/pysqlite
30 DEPENDS:=python-core +libsqlite3
31 endef
32
33 define Package/python-sqlite/description
34 This package contains an SQLite database adapter for the Python
35 programming language.
36 endef
37
38 define PyPackage/python-sqlite/filespec
39 +|$(PYTHON_PKG_DIR)/pysqlite2
40 -|$(PYTHON_PKG_DIR)/pysqlite2/test
41 endef
42
43 define Build/Configure
44 cp ./files/setup.cfg.in $(PKG_BUILD_DIR)/setup.cfg
45 $(SED) \
46 's,@INCLUDE_DIRS@,$(STAGING_DIR)/usr/include,g' \
47 -e 's,@INCLUDE_DIRS@,$(STAGING_DIR)/usr/include,g' \
48 $(PKG_BUILD_DIR)/setup.cfg
49 endef
50
51 define Build/Compile
52 $(if $(Build/Compile/PyMod),,@echo Python packaging code not found.; false)
53 $(call Build/Compile/PyMod,., \
54 install --prefix="$(PKG_INSTALL_DIR)/usr", \
55 )
56 endef
57
58 $(eval $(call PyPackage,python-sqlite))
59 $(eval $(call BuildPackage,python-sqlite))