# glib errors when compiling libIDL-0.6.8



## kilowatt (Jul 27, 2001)

Ok, I have strong hopes of compiling mozilla to run in os x under XDarwin. So obviously I have alot of work to do. Anyway, I have to have libIDL-0.6.8 in order to build mozilla, but I can't get libIDL to compile. I have a feeling that this is something stupid that I just don't see, here are my errors:
There are about 20 references to this error, each with a different line number:
/sw/include/glib.h:502: undefined type, found `gint32'
/sw/include/glib.h:503: undefined type, found `guint32'
/sw/include/glib.h:504: undefined type, found `guint32'
/sw/include/glib.h:505: undefined type, found `gint32'
/sw/include/glib.h:840: undefined type, found `guint8'

Then we see some of this:
/sw/include/glib.h:502: undefined type, found `gint32'
/sw/include/glib.h:503: undefined type, found `guint32'
/sw/include/glib.h:504: undefined type, found `guint32'
/sw/include/glib.h:505: undefined type, found `gint32'
/sw/include/glib.h:840: undefined type, found `guint8'

Then a few lines of this:
/sw/include/glib.h:2351: undefined type, found `GIOCondition'

A few more errors:
./IDL.h:113: warning: 64-bit integer type not available, using 32-bit instead
./IDL.h:586: undefined type, found `guint32'
cpp-precomp: warning: errors during smart preprocessing, retrying in basic mod

And there is more... (this is, once again, repeated several times)
In file included from ./util.h:35,
                 from ./parser.y:33:
/sw/include/glib.h:502: parse error before `gssize'
/sw/include/glib.h:502: warning: data definition has no type or storage class
/sw/include/glib.h:503: parse error before `gsize'
/sw/include/glib.h:503: warning: data definition has no type or storage class
/sw/include/glib.h:504: parse error before `GQuark'
/sw/include/glib.h:504: warning: data definition has no type or storage class
/sw/include/glib.h:505: parse error before `GTime'
/sw/include/glib.h:505: warning: data definition has no type or storage class
/sw/include/glib.h:769: parse error before `key_id'
/sw/include/glib.h:840: parse error before `guint8'
/sw/include/glib.h:840: warning: no semicolon at end of struct or union
/sw/include/glib.h:842: parse error before `}'
/sw/include/glib.h:1554: parse error before `mask'
/sw/include/glib.h:1572: parse error before `mask'
/sw/include/glib.h:1718: parse error before `*'
/sw/include/glib.h:1721: parse error before `*'
/sw/include/glib.h:1754: parse error before `g_quark_try_string'
/sw/include/glib.h:1754: warning: data definition has no type or storage class
/sw/include/glib.h:1755: parse error before `g_quark_from_static_string'
/sw/include/glib.h:1755: warning: data definition has no type or storage class
/sw/include/glib.h:1756: parse error before `g_quark_from_string'
/sw/include/glib.h:1756: warning: data definition has no type or storage class

Then some of this:
In file included from ./util.h:36,
                 from ./parser.y:33:
./IDL.h:586: parse error before `guint32'
./IDL.h:586: warning: no semicolon at end of struct or union
./IDL.h:588: parse error before `}'
./parser.y: In function `__IDL_parse':
./parser.y:332: invalid use of undefined type `struct _IDL_tree_node'
./parser.y:332: dereferencing pointer to incomplete type
<snip>
./parser.y: In function `IDL_ns_version':
./parser.y:1585: invalid use of undefined type `struct _IDL_tree_node'

It goes on and on... nearly evvery line of that file isn't too cool with my sistem... Here's the last of it:

./parser.y: In function `IDL_ns_version':
./parser.y:1585: invalid use of undefined type `struct _IDL_tree_node'

I've already had to explain where nearly every file is on my computer, now it appears that it does not like any of them. Well, a few things did compile from this package. Anyway, I got glib and gtk from the macgimp installer, I hope thats ok. 

As you all can see, I'm pretty lost. Any help would be appreciated. 

Thanks!


----------



## kilowatt (Jul 27, 2001)

I edited the file /sw/include/glib.h

arround line 66, I added the following:
#include /sw/lib/glib/include/glibconfig.h
and I completed the path (same file, next line).
it was:
#include glib.h
but now its:
#include /sw/include/glib.h
Those things have greater than and less than signs arround them, but I think that vbulliten would interperate them as html tags.
&gt &lt just a guess...

I'm now getting some different errors, though:
util.c:1304: bad macro argument list
(lkines 1304, 1298, and 1301).
And then I get some error at the end:
cpp-precomp: warning: errors during smart preprocessing, retrying in basic mode
make: *** [util.lo] Error 1

I'm going to work at this all day.  

Any help would be great!
Thanks!


----------



## gzmo (Jan 10, 2005)

try running the following command:
./configure --host=powerpc-apple-macos

-Hope it works


----------



## wadesworld (Jan 10, 2005)

You need to include the /sw/include path into your header search path.  Then you won't have to run around editing header files all over the place.

To add a search path, find the 

CC_FLAGS = 

line in the Makefile and add:

-I/sw/include

But this begs the question - I assume you've made sure that glib is installed via fink or manually?

Wade


----------

