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.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,4d1b41004c1d217c X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!feeder3.cambriumusenet.nl!feed.tweaknews.nl!193.141.40.65.MISMATCH!npeer.de.kpn-eurorings.net!npeer-ng0.de.kpn-eurorings.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsfeed.arcor.de!newsspool1.arcor-online.net!news.arcor.de.POSTED!not-for-mail From: "Dmitry A. Kazakov" Subject: Re: How to interface in ADA with Microsoft joystick? Newsgroups: comp.lang.ada User-Agent: 40tude_Dialog/2.0.15.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Reply-To: mailbox@dmitry-kazakov.de Organization: cbb software GmbH References: <2edbcdab-8ff5-40e6-9ac0-44be6cb93621@m15g2000yqm.googlegroups.com> <1cd6pmbvbsnkb$.uwz2048291is.dlg@40tude.net> <3a82f59a-129f-46b1-bd0c-eae124136590@26g2000yqv.googlegroups.com> <0402e3f7-151c-4a51-bd61-44f4fc32a9d1@l20g2000yqm.googlegroups.com> <1thnsl7r3l217.1g1mvpwzjokvr.dlg@40tude.net> <1ntdrf2b9blvx.1qzgqdxqb9jvn$.dlg@40tude.net> Date: Tue, 12 Oct 2010 09:25:46 +0200 Message-ID: <1lj7ed5rhng0p.5cwwj78z71lz.dlg@40tude.net> NNTP-Posting-Date: 12 Oct 2010 09:25:46 CEST NNTP-Posting-Host: 0d915abd.newsspool2.arcor-online.net X-Trace: DXC=nJ`^B8U5jT]\9P[:DUn00QA9EHlD;3YcR4Fo<]lROoRQ8kF On Mon, 11 Oct 2010 13:24:33 -0700 (PDT), tolkamp wrote: > Now the compilation of my project is error free. > I have tried to build an executable of my project, but again an error: > > gnatmake -d -PC:\\GNAT\\bin\\joystick.gpr joystick_main.adb > gnatbind -I- -x C:\GNAT\joystick_main.ali > gnatlink C:\GNAT\joystick_main.ali -o C:\GNAT\joystick_main.exe > c:/gnat/2009/bin/../libexec/gcc/i686-pc-mingw32/4.3.4/ld.exe: cannot > find -lwin32ada > collect2: ld returned 1 exit status > gnatlink: error when calling C:\GNAT\2009\bin\gcc.exe > gnatmake: *** link failed. > > > Here the contents of the project file (joystick.gpr): > > project Joystick is > for Source_Dirs use (".", "..\2009\include\win32ada"); > for Object_Dir use "..\"; > for Main use ("joystick_main.adb"); > for Library_Dir use "..\2009\lib\win32ada"; > end Joystick; You must use 'with "win32ada.gpr";' in your project: with "win32ada.gpr"; project Joystick is for Source_Dirs use ("."); for Main use ("joystick_main.adb"); package Linker is for Default_Switches ("ada") use ("-mwindows"); end Linker; end Joystick; [ And you should never use absolute paths and just any paths to any external directories. ] -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de