pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: django/python missing sqlite
On Sun, Apr 12, 2009 at 01:17:54PM +0200, Joerg Sonnenberger wrote:
> On Sun, Apr 12, 2009 at 12:17:52AM -0700, George Georgalis wrote:
> > Not sure what you're getting at here. As far as I can tell/tried. Can you
> > be more specific about what you want me to do?
>
> OK, let's make it simpler. Just apply the attached patch in
> www/py-django and rebuild. It should make it work without py-sqlite3.
>
> Joerg
Index: Makefile
===================================================================
RCS file: /home/joerg/repo/netbsd/pkgsrc/www/py-django/Makefile,v
retrieving revision 1.15
diff -u -p -r1.15 Makefile
--- Makefile 29 Jan 2009 09:35:54 -0000 1.15
+++ Makefile 12 Apr 2009 11:16:20 -0000
@@ -21,7 +21,7 @@ DEPENDS+= ${PYPKGPREFIX}-flup-[0-9]*:../
.include "options.mk"
-post-extract:
+pre-configure:
rm -r ${WRKSRC}/django/db/backends/oracle
.if empty(PKG_OPTIONS:Mmysql)
rm -r ${WRKSRC}/django/db/backends/mysql
Index: distinfo
===================================================================
RCS file: /home/joerg/repo/netbsd/pkgsrc/www/py-django/distinfo,v
retrieving revision 1.8
diff -u -p -r1.8 distinfo
--- distinfo 17 Dec 2008 19:55:38 -0000 1.8
+++ distinfo 12 Apr 2009 11:16:44 -0000
@@ -4,3 +4,4 @@ SHA1 (Django-1.0.2-final.tar.gz) = f2d90
RMD160 (Django-1.0.2-final.tar.gz) = 0cfea620df0831310da4ef51ef6ee4ef1b65974e
Size (Django-1.0.2-final.tar.gz) = 4649433 bytes
SHA1 (patch-aa) = 54a532d9c6761f80a10c633bb6192faccb5ab64b
+SHA1 (patch-ab) = 620e958ab3b4c3cf7ceb507b52ac64b522a6e4a8
Index: patches/patch-ab
===================================================================
RCS file: patches/patch-ab
diff -N patches/patch-ab
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-ab 12 Apr 2009 11:16:42 -0000
@@ -0,0 +1,25 @@
+$NetBSD$
+
+--- django/db/backends/sqlite3/base.py.orig 2009-04-11 22:01:24.000000000
+0200
++++ django/db/backends/sqlite3/base.py
+@@ -12,18 +12,11 @@ from django.db.backends.sqlite3.creation
+ from django.db.backends.sqlite3.introspection import DatabaseIntrospection
+
+ try:
+- try:
+- from sqlite3 import dbapi2 as Database
+- except ImportError, e1:
+- from pysqlite2 import dbapi2 as Database
++ from pysqlite2 import dbapi2 as Database
+ except ImportError, exc:
+ import sys
+ from django.core.exceptions import ImproperlyConfigured
+- if sys.version_info < (2, 5, 0):
+- module = 'pysqlite2'
+- else:
+- module = 'sqlite3'
+- exc = e1
++ module = 'pysqlite2'
+ raise ImproperlyConfigured, "Error loading %s module: %s" % (module, exc)
+
+ try:
Home |
Main Index |
Thread Index |
Old Index