[racket] (sqlite3-connect) does not survive "raco distribute" on Windows, saying "sqlite3_open: implementation not found"

From: Dmitry Pavlov (dpavlov at ipa.nw.ru)
Date: Fri Sep 13 12:13:49 EDT 2013

Hello,

[I actually filed a bug report, but have not received
a confirmation, and decided to write here as well.]

A program does a call to (sqlite3-connect). The program works well 
itself, and it works well after being translated into an executable
by "raco exe", but "raco distribute" breaks it.

The bug reproduces only on Windows; on Linux everything works fine.


File mytable.rkt:

#lang racket

(require db)
(define path "mytable.db")

(when (file-exists? path)
   (delete-directory/files path))

(define conn (sqlite3-connect #:database path #:mode 'create))
(query-exec conn "create table MYTABLE (n integer primary key)")
(disconnect conn)
(printf "OK\n")


Steps to reproduce:

C:\Documents and Settings\dpavlov>raco exe mytable.rkt

C:\Documents and Settings\dpavlov>mytable.exe
OK

C:\Documents and Settings\dpavlov>raco distribute mytable-distr mytable.exe

C:\Documents and Settings\dpavlov>mytable-distr\mytable.exe
sqlite3_open: implementation not found; arguments: #"C:\\Documents and 
Settings\\dpavlov\\mytable.db" 6
   context...:
    c:\program files\racket\collects\db\private\sqlite3\main.rkt:11:0: 
sqlite3-connect13
    #%mzc:mytable: [running body]
    loop


Regards,

Dmitry


Posted on the users mailing list.