From: Marco Atzeri <marco.atzeri@gmail.com>
To: cygwin@cygwin.com
Subject: Re: ada gnat import library missing ?
Date: Thu, 02 Nov 2017 12:13:00 -0000 [thread overview]
Message-ID: <efc6df78-600b-6ae1-4fc2-b553dc319ac9@gmail.com> (raw)
In-Reply-To: <4296fc8c-6737-3a3f-02c8-6042a093c42d@gmail.com>
On 02/11/2017 11:28, JonY wrote:
> On 11/01/2017 04:07 PM, Marco Atzeri wrote:
>> On 31/10/2017 00:17, JonY wrote:
>>
>>> -2 with the appropriate import libraries should be coming along by the
>>> end of the week if all goes well.
>>
>> It is up but I see the same
>>
>> $ ./hello.exe
>> Â -bash: ./hello.exe: cannot execute binary file: Exec format error
>>
>> Does it work for you ?
>>
>
> I think I solved the mystery, this generates a dll instead of an exe,
> see the verbose output calling the compiler.
>
you are right; "-shared" should be used only on the 2nd step
not on the third.
$ gcc -c hello.adb
$ gnatbind -v -shared hello
gnatbind -v -shared hello
GNATBIND 6.4.0
Copyright (C) 1995-2016, Free Software Foundation, Inc.
Binding: hello.ali
No errors
$ gnatlink -v hello
GNATLINK 6.4.0
Copyright (C) 1995-2016, Free Software Foundation, Inc.
gcc -c -mtune=generic -march=x86-64 -gnatA -gnatWb -gnatiw -gnatws
/tmp/ada/b~hello.adb
/usr/bin/gcc.exe b~hello.o ./hello.o -o hello.exe -L./
-L/usr/lib/gcc/x86_64-pc-cygwin/6.4.0/adalib/ -lgnat-6
-Wl,--stack=0x2000000 -shared-libgcc
$ ./hello.exe
Hello WORLD!
$ cygcheck ./hello.exe |grep -v Windows
E:\cygwin64\tmp\ada\hello.exe
E:\cygwin64\bin\cygwin1.dll
E:\cygwin64\bin\cyggnat-6.dll
E:\cygwin64\bin\cyggcc_s-seh-1.dll
Thanks
Marco
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
next prev parent reply other threads:[~2017-11-02 12:13 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-28 14:37 Marco Atzeri
2017-10-30 9:56 ` JonY
2017-10-30 14:15 ` Marco Atzeri
2017-10-30 23:18 ` JonY
2017-10-31 6:30 ` Marco Atzeri
2017-11-01 16:07 ` Marco Atzeri
2017-11-02 10:28 ` JonY
2017-11-02 12:13 ` Marco Atzeri [this message]
2017-11-02 12:25 ` Arjen Markus
2017-11-06 5:22 ` Arjen Markus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=efc6df78-600b-6ae1-4fc2-b553dc319ac9@gmail.com \
--to=marco.atzeri@gmail.com \
--cc=cygwin@cygwin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).