pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: django/python missing sqlite
On Mon 13 Apr 2009 at 03:13:52 PM -0700, George Georgalis wrote:
>On Sun 12 Apr 2009 at 01:27:42 PM +0200, Joerg Sonnenberger wrote:
>>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.
>
>...not sure what happened to my prior reply, thats GMT -0700:
>Apr 12 13:37:22 host=smtp.gmail.com tls=on auth=on
>user=george%galis.org@localhost from=geo%fuji.galis.org@localhost
>recipients=pkgsrc-users%netbsd.org@localhost,galis%galis.org@localhost
>mailsize=5051 smtpstatus=250 smtpmsg='250 2.0.0 OK 1239568644
>b8sm8789878rvf.22' exitcode=EX_OK
>
>anyway, it doesn't solve the problem. after cleaning and
>reinstalling with the patch, in /var/db/pkg I find, (in reverse
>time order)
>
>drwxr-xr-x 2 root root 4096 Apr 13 13:09 libffi-3.0.8
>drwxr-xr-x 2 root root 4096 Apr 13 13:09 db4-4.7.25.3
>drwxr-xr-x 2 root root 4096 Apr 13 13:09 py25-setuptools-0.6c9
>drwxr-xr-x 2 root root 4096 Apr 13 13:11 py25-mxDateTime-2.0.6nb1
>drwxr-xr-x 2 root root 4096 Apr 13 13:11 postgresql82-client-8.2.13
>drwxr-xr-x 2 root root 4096 Apr 13 13:14 sqlite3-3.6.11
>drwxr-xr-x 2 root root 4096 Apr 13 14:34 python25-2.5.2nb5
>drwxr-xr-x 2 root root 4096 Apr 13 14:34 py25-sqlite2-2.5.0a
>drwxr-xr-x 2 root root 4096 Apr 13 14:34 py25-psycopg-1.1.21nb3
>drwxr-xr-x 2 root root 4096 Apr 13 14:34 py25-flup-2311
>drwxr-xr-x 2 root root 4096 Apr 13 14:34 py25-django-1.0.2nb1
>-rw-r--r-- 1 root root 2310144 Apr 13 14:34 pkgdb.byfile.db
>
>and the error persists:
>
>File
>"/usr/pkg/lib/python2.5/site-packages/django/db/backends/sqlite3/base.py",
>line 27, in <module>
> raise ImproperlyConfigured, "Error loading %s module: %s" % (module, exc)
>django.core.exceptions.ImproperlyConfigured: Error loading sqlite3 module: No
>module named _sqlite3
>
># find /usr/pkg -maxdepth 2 -iname \*sqlite\*
>/usr/pkg/include/sqlite3ext.h
>/usr/pkg/include/sqlite3.h
>/usr/pkg/bin/sqlite3
>/usr/pkg/lib/libsqlite3.a
>/usr/pkg/lib/libsqlite3.so
>/usr/pkg/lib/libsqlite3.so.0
>/usr/pkg/lib/libsqlite3.so.0.8.6
>/usr/pkg/lib/libsqlite3.la
>
>seems the django deps installed sqlite3 but is looking for lib
>installed by py-sqlite3
Ooops, maxdepth shouldn't have been there, here is another data point after a
py-sqlite3 install.
# ls -rltd `find /usr/pkg -iname \*sqlite\*`
-r--r--r-- 1 root root 532 Apr 13 13:08
/usr/pkg/lib/python2.5/test/test_sqlite.py
-rw-r--r-- 1 root root 885 Apr 13 13:08
/usr/pkg/lib/python2.5/test/test_sqlite.pyc
drwxr-xr-x 3 root root 4096 Apr 13 13:08 /usr/pkg/lib/python2.5/sqlite3
-rw-r--r-- 1 root root 885 Apr 13 13:08
/usr/pkg/lib/python2.5/test/test_sqlite.pyo
-r--r--r-- 1 root root 6786 Apr 13 13:13 /usr/pkg/man/man1/sqlite3.1
-rw-r--r-- 1 root root 291 Apr 13 13:13 /usr/pkg/lib/pkgconfig/sqlite3.pc
-rwxr-xr-x 1 root root 698343 Apr 13 13:13 /usr/pkg/lib/libsqlite3.so.0.8.6
lrwxrwxrwx 1 root root 19 Apr 13 13:13 /usr/pkg/lib/libsqlite3.so.0 ->
libsqlite3.so.0.8.6
lrwxrwxrwx 1 root root 19 Apr 13 13:13 /usr/pkg/lib/libsqlite3.so ->
libsqlite3.so.0.8.6
-rwxr-xr-x 1 root root 886 Apr 13 13:13 /usr/pkg/lib/libsqlite3.la
-rw-r--r-- 1 root root 1016030 Apr 13 13:13 /usr/pkg/lib/libsqlite3.a
-rw-r--r-- 1 root root 323624 Apr 13 13:13 /usr/pkg/include/sqlite3.h
-rw-r--r-- 1 root root 20754 Apr 13 13:13 /usr/pkg/include/sqlite3ext.h
-rwxr-xr-x 1 root root 49149 Apr 13 13:13 /usr/pkg/bin/sqlite3
-rwxr-xr-x 1 root root 1975171 Apr 13 13:14
/usr/pkg/lib/python2.5/site-packages/pysqlite2/_sqlite.so
drwxr-xr-x 2 root root 4096 Apr 13 15:04
/usr/pkg/lib/python2.5/site-packages/django/db/backends/sqlite3
-rwxr-xr-x 1 root root 1966433 Apr 13 15:24
/usr/pkg/lib/python2.5/site-packages/_sqlite3.so
drwxr-xr-x 3 root root 4096 Apr 13 15:38
/usr/pkg/lib/python2.5/site-packages/pysqlite2
-G
>>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:
>
--
George Georgalis <george%galis.org@localhost>, Information Systems <IXOYE><
SEEKING EMPLOYMENT OPPORTUNITIES, specialties: BSD/Linux, HPC,
security/VPN, data warehousing, virtualization, validation,
decision tree analysis, unit testing and change control.
Home |
Main Index |
Thread Index |
Old Index