a SQLite devpak for dev-cpp --- template program compiles out of the box

http://www.ingmezzina.it/dev-packs/default.asp  


Jonathan Gennick wrote:
> I'm trying to compile SQLite, but, unfortunately, with very
> little joy. I'm running on Windows (sorry), and I'm using
> Bloodshed's C++ IDE, which appears to run some form of GNU's
> C++ compiler. Is anyone else using this particular
> combination?
> 
> Below my signature, I've pasted in the short program that
> I'm trying to compile. I've also pasted in the error
> messages that result. I'd be grateful for any help.
> 
> If not Bloodshed, is there some other Windows C++ compiler
> that is known to be able to compile SQLite?  I'd be happy to
> switch compilers, if that was the easiest way for me to get to some
> working code. 
> 
> Of course, it could be my code that is flawed, and not the
> compiler, but the errors all appear come from SQLite source
> files, so I tend to think I'm encountering some sort of
> mismatch between SQLite and the compiler that I'm using.
> 
> Best regards,
> 
> Jonathan Gennick
> Editor, O'Reilly & Associates
> 906.387.1698   mailto:[EMAIL PROTECTED]
> 
> 
> Here's the code I'm trying to compile:
> 
> #include <iostream>
> #include <stdlib.h>
> #include "main.c"
> 
> using namespace std;
> 
> int main(int argc, char *argv[])
> {
>   sqlite *db;
>   char *zErrMsg = 0;
>   int rc;
> 
>   printf("Opening the database...\n\n");
>   db =
> sqlite_open("c:\SQLite\Projects|FirstTest\FirstDatabase", 0,
>   &zErrMsg); if( db==0 ){
>     fprintf(stderr, "Can't open database: %s\n", zErrMsg);    
>     system("PAUSE"); exit(1);
>   }
> 
>   printf("Closing the database...\n\n");
>   sqlite_close(db);
> 
>   system("PAUSE");
>   return 0;
> }
> 
> 
> And here are the results:
> 
> #include <iostream>
> #include <stdlib.h>
> #include "main.c"
> 
> using namespace std;
> 
> int main(int argc, char *argv[])
> {
>   sqlite *db;
>   char *zErrMsg = 0;
>   int rc;
> 
>   printf("Opening the database...\n\n");
>   db =
> sqlite_open("c:\SQLite\Projects|FirstTest\FirstDatabase", 0,
>   &zErrMsg); if( db==0 ){
>     fprintf(stderr, "Can't open database: %s\n", zErrMsg);    
>     system("PAUSE"); exit(1);
>   }
> 
>   printf("Closing the database...\n\n");
>   sqlite_close(db);
> 
>   system("PAUSE");
>   return 0;
> }

reid

Reply via email to