comp.lang.ada
 help / color / mirror / Atom feed
From: Maciej Sobczak <see.my.homepage@gmail.com>
Subject: GNAT 2009, Windows and system libraries
Date: Wed, 10 Feb 2010 03:13:11 -0800 (PST)
Date: 2010-02-10T03:13:11-08:00	[thread overview]
Message-ID: <690a26b0-70fd-4d0c-8169-fe803594938d@z17g2000yqh.googlegroups.com> (raw)

I have a problem writing a proper .gpr file for a project that is
composed of Ada and C++ code and that uses Windows socket API.
I have no problem linking Ada with the C++ library, the problem is
with system library known as Ws2_32.lib.

When compiling a similar project with a C++ compiler, it is enough to
add Ws2_32.lib to the compiler invocation command and it just works.
I cannot, however, find a proper way of doing it with Ada projects.

This is my try (Ws2_32.gpr):

project Ws2_32 is
   for Externally_Built use "true";
   for Source_Dirs use ();
   for Library_Dir use "C:\Program Files\Microsoft SDKs\Windows\v6.0A
\Lib";
   for Library_Name use "Ws2_32";
   for Library_Kind use "dynamic";
end Ws2_32;

This .gpr file is "withed" by the project file of the final Ada
program. This approach works for my own libraries, but is ineffective
with the system library and gnatlink reports zillions of unresolved
references.

Any feedback is welcome.

--
Maciej Sobczak * www.msobczak.com * www.inspirel.com



             reply	other threads:[~2010-02-10 11:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-10 11:13 Maciej Sobczak [this message]
2010-02-10 11:40 ` GNAT 2009, Windows and system libraries Hibou57 (Yannick Duchêne)
2010-02-10 15:21 ` Maciej Sobczak
2010-02-10 15:35   ` Maciej Sobczak
2010-02-10 15:45     ` Ludovic Brenta
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox