- Create a directory called TclSqlite under the Tcl /lib directory.
- Copy or move the TclSqlite library to the newly created directory.
- From Tcl, execute: "pkg_mkIndex -direct <tcl>/lib/TclSqlite *.<ext>" where <tcl> is the path to the /lib directory and <ext> is the library extension (dll or so).
Once you've done this, you'll have a pkgIndex.tcl file in the TclSqlite directory. Tcl will use that file to automatically locate the package. Now all you have to do is use:
package require sqlite
or
package require sqlite 2
or
package require sqlite 2.0
depending on how cautious you want to be--and assuming that you're using version 2 of the library! (The second and third choices are probably best in most cases. Use the first choice to find the most recent version you've installed.)
If you want to use tclSqlite with ActiveState Tcl under windows. All you need to do is "load" the .dll file
load C:\\Tcl\\lib\\tclsqlite3.dll sqlite3 sqlite3 db1 testdb db1 close
(I found this solution after a LONG search ... on the mailing list. The solution was given by Gerry Snyder. Thanks Gerry!)
This is not the cleanest install (and is very easy to break if you change the .dll location) but it works.