From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=BAYES_00,FROM_ADDR_WS, INVALID_MSGID,REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9db1a24e84200ccd X-Google-Attributes: gid103376,public From: Jan Mulder Subject: Re: GNAT301a, SDK & WIN32ADA problems Date: 1996/05/06 Message-ID: <4mlnqk$rjk@altrade.nijmegen.inter.nl.net>#1/1 X-Deja-AN: 153355607 references: <4mgi01$3k4@altrade.nijmegen.inter.nl.net> <4mieuhINN9sf@RA.DEPT.CS.YALE.EDU> organization: Home reply-to: JM newsgroups: comp.lang.ada Date: 1996-05-06T00:00:00+00:00 List-Id: griest-tom@cs.yale.edu (Tom Griest) wrote: >In article <4mgi01$3k4@altrade.nijmegen.inter.nl.net> JM writes: >>I'am using the gnat301a (fix2..fix4) and the win32ada bindings. When >>building the win32ada test programs I receive the following error >>message: >> >>c:\ada\win32ada\lib\win32-assert.obj: in function >>'_win32__assert__fail_assertion': >>win32-assert.adb:41: undefined reference to '__assert' >>c:\ada\gnat301a\gnatmake.exe: *** link failed. >> >>I also have the SDK installed, by reading the installation notes this >>should be enough. >> >>What is wrong? >You have to link with the win32ada.lib library that is included with >the bindings. If you are using "ld" you could add the file (with >full path) to the beginning of the libs.ld file. >-Tom Tom, thanks for answering so quickly. I have tried several places for the win32ada.lib at the libs.ld and still no results. The mktest uses the following commands: gcc -c test_assert.adb gnatbl test_assert.ali ..\lib\win32ada.lib -o test_ass.exe So I think the win32ada.lib was referenced too by the linker. I even placed the win32ada.a at the beginning of the libs.ld file (you never know). When trying to build the test_stdio.adb (for the experiments I focus on test_assert.adb) I even got more errors, meaning undefined references to: _fscanf __snprintf _sprintf _vfprintf __vsnprintf __assert _vsprintf __iob The gnat301a examples programs are working just fine. After installing fix2 the cal test program worked also. my libs.ld looks like this: SECTIONS { .text 0x401000 : { c:\ada\win32ada\lib\win32ada.lib C:\ADA\gnat301a\lib\libgcc.a C:\ADA\gnat301a\lib\libada_c.a C:\MSTOOLS\lib\user32.lib C:\MSTOOLS\lib\kernel32.lib }} and winlibs.ld looks like this: SECTIONS { .text 0x401000 : { C:\MSTOOLS\lib\comdlg32.lib C:\MSTOOLS\lib\advapi32.lib C:\MSTOOLS\lib\gdi32.lib }} the setpath.bat for both gnat301a and win32ada are as provided and are run in this order. There must be a library missing. Waiting for more, Jan.