I’d like to generate my own build of SQLite from the amalgamation source for use in a WP8 app, but I can’t figure out how to compile it successfully. Building for WinRT was as simple as defining SQLITE_OS_WINRT so I expected something similar for WP8, but no amount of searching has turned up anything like that. All I could find were a few unanswered questions on Stack Overflow[1][2] about people not even being able to build it for WP8 from the original sources and makefiles.
With no additional defines, compiling against the WP8 platform fails spectacularly, which is not surprising. If I define SQLITE_OS_WINRT then the errors are trimmed down to just three about undeclared Windows APIs related to file mapping (CreateFileMappingFromApp, MapViewOfFileFromApp, and UnmapViewOfFile). There appears to be some ambiguity about whether or not those functions are supposed to be supported by WP8; the documentation for the first two says that they are, but the actual SDK headers obviously don’t agree. There’s an MSDN thread[3] noting this mismatch which also notes that SQLite both uses these APIs and works on WP8. A reply there indicates that it may be possible to somehow be granted an exception to use those APIs even though the SDK doesn’t appear to support them. Has SQLite been granted such an exception? In any case, it’s clearly possible to build SQLite for WP8 because there’s an official distribution of such a build. What do I have to do to generate one myself? If SQLite has an exception to use APIs not generally available, then is it simply not possible for anyone other than an official distributor with inside info/headers/something? Thanks a lot! [1] http://stackoverflow.com/questions/14074821/build-sqlite-for-windows-phone-8 [2] http://stackoverflow.com/questions/14785506/compiling-sqlite-for-windows-phone-8 [3] http://social.msdn.microsoft.com/Forums/en-US/wpdevelop/thread/6114f2fe-1543-4121-bb4e-478c36207c5b _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users