mingw-cross-env-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Mingw-cross-env-list] OpenCSG again


From: René Berber
Subject: Re: [Mingw-cross-env-list] OpenCSG again
Date: Mon, 19 Sep 2011 05:11:36 -0500
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.19) Gecko/20081209 Lightning/0.9 Thunderbird/2.0.0.19 Mnenhy/0.7.6.0

On 18 Sep 2011 15:58:57, Brad Pitcher  wrote:
[snip]
> release/main.o:main.cpp:(.text+0x29f): undefined reference to
> address@hidden'
[snip]

That means the linker is looking for dynamic libraries.

> I hope this is a really obvious stupid mistake.

No, the problem is that OpenCSG is not configured to build with static
libraries.

Additional to making src.pro produce a static library you have to add:

DEFINES     += FREEGLUT_STATIC GLEW_STATIC

(from looking at the header files) this is necessary to use the
available static libraries (or you can build the dynamic ones).  Another
detail is in INCLUDEPATH, the glew part is not needed and it could cause
problems (the one included is a different version).

Same thing in example.pro, needs the DEFINES part.

I still was unable to build the example, but at least its looking for
the correct (static) library.

The problem I ran into should be fixed with the parameter
"-Wl,-enable-stdcall-fixup" used, but its not.

First error is now:

release/main.o:main.cpp:(.text+0x2a2): undefined reference to
`_glutSolidTorus'

the function is where it should be:

$ i686-pc-mingw32-nm ../../usr/i686-pc-mingw32/lib/libglut.a | grep
glutSolidTorus
         U address@hidden
00001bb0 T address@hidden

the extra @24 in the name is usually not a problem (that's what the
parameter to the linker fixes).  I stopped there, and I have no idea why
it doesn't link.
-- 
René Berber




reply via email to

[Prev in Thread] Current Thread [Next in Thread]