Hi All,

I'm trying to build a GAPI application using cegcc. As there doesn't 
seem to be a import library ready made for this, I have attempting to 
make one, but without much success.

My gx.def file looks like this:

   LIBRARY GX
   EXPORTS
   GXOpenDisplay
   GXCloseDisplay
   GXBeginDraw
   GXEndDraw
   GXOpenInput
   GXCloseInput
   GXGetDisplayProperties
   GXGetDefaultKeys
   GXSuspend
   GXResume
   GXSetViewport
   GXIsDisplayDRAMBuffer

And I'm using dlltool like this:

   $ arm-wince-cegcc-dlltool -d gx.def -l libgx.a
   $ cp libgx.a /opt/cegcc/arm-wince-cegcc/lib

My test program then simply looks like this:

   #include <windows.h>
   #include <gx.h>

   int WINAPI WinMain (HINSTANCE hInstance,
                       HINSTANCE hPrevInstance,
                       LPWSTR szCmdLine,
                       int iCmdShow)
   {
     MessageBox (NULL, TEXT("Hello"), TEXT("Hello Demo"), MB_OK);
     GXBeginDraw();
     return (0);
   }

I compile it like this:

   arm-wince-cegcc-g++ -Wall -D_WIN32_WCE=0x0420 -D_WIN32_IE=0x0400  -o 
test.exe test.c -lgx

But the resulting compiler output is this:

   Info: resolving _CRT_MT by linking to __imp__CRT_MT 
(auto-import/blah/Temp/cc9E2Xnc.o:test.c:(.text+0x34): undefined 
reference to `GXBeginDraw()'
collect2: ld returned 1 exit status
)

I suspected some kind of name mangling might be the cause, but whatever 
I have tried gives me the same result as above.

Where am I going wrong? Or am I barking up completely the wrong tree? :)

Hope someone can help.

Cheers,

--
Matt.

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Cegcc-devel mailing list
Cegcc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cegcc-devel

Reply via email to