On Tue, Apr 08, 2008 at 08:22:38AM -0400, P Kishor scratched on the wall:
> I want to add an extension or two to the amalgamation so I don't have
> to load the extension manually. Can someone kindly explain or point me
> to a clear tutorial on how to do so?
Depends on what you're trying to add. If you want to add your own
user functions or aggregation functions, search for the function
"sqlite3RegisterBuiltinFunctions()" (and other
sqlite3Register*Functions() functions). If you're looking to add a
collation, search for the function "openDatabase()" and scroll down a
bit to see where the NOCASE collation is registered.
If you want to have a custom build with your own functions, just add
the correct lines to the setup structs in these areas. Depending on
how you want to setup your headers and source files, you can add the
actual C function to the amalgamation file or keep them in your own
source files and let the linker figure things out. I guess which you
do depends on if you want maximum ease of compiling or minimum changes
to the amalgamation (which makes it easier to replicate the changes
if/when you need to upgrade).
-j
--
Jay A. Kreibich < J A Y @ K R E I B I.C H >
"'People who live in bamboo houses should not throw pandas.' Jesus said that."
- "The Ninja", www.AskANinja.com, "Special Delivery 10: Pop!Tech 2006"
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users