PDA

View Full Version : Visual Studio 2008 c++ libpurple compile



nattsurf123
09-02-10, 12:46 PM
Hi,
I would simply want to compile lib purple in visual studio but I fear that would be difficult.
The big problem I have now is a config.h file.
The story to this is that I was following instructions posted in this url:
http:\\pidgin.im\pipermail\devel\2007-May\001041.html
It says:


2. Add version.h, and config.h from pidgin root

But in the pidgin root I found a version of config.h that undefined everything.
So when I compile I get errors like:


Error 84 error C2054: expected '(' to follow 'STATIC_PROTO_INIT' c:\users\admin\documents\visual studio 2008\projects\libpurple\libpurple\core.c 79 LibPurple

I realize this was not the config.h that I was supposed to add but instead a config.h with a crazy name like 'config.h.mingw'.
Of course I removed the old config.h and replaced it with this one.
This file would define the required constants. So I hit compile, but for some reason I get the same error.


Error 84 error C2054: expected '(' to follow 'STATIC_PROTO_INIT' c:\users\admin\documents\visual studio 2008\projects\libpurple\libpurple\core.c 79 LibPurple

So I had to make some wild tests in order to get more information.
I added the #define code in core.c.


#ifndef STATIC_PROTO_INIT
#define STATIC_PROTO_INIT static void static_proto_init(void) { }
#endif

That actually made the compile a bit more happy because the compiler triggered an error on another missing constant.
So I concluded that visual studio still uses the old config.h file.
What do you think?
What could I try?
What should I do?

P1raten
09-02-10, 01:02 PM
This is really wierd. Never seen anything like this. :S

nattsurf123
10-02-10, 09:06 AM
This is really wierd. Never seen anything like this. :S

I'm thinking of starting from scratch again.

P1raten
14-02-10, 06:33 AM
I'm thinking of starting from scratch again.
You should.