From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: Import Python library into an Ada package?
Date: Fri, 4 Dec 2020 11:23:21 +0100 [thread overview]
Message-ID: <rqd2mn$ori$1@gioia.aioe.org> (raw)
In-Reply-To: 7223f058-c593-4905-b9ba-0a5cb3e64de2n@googlegroups.com
On 2020-12-04 08:36, Roger Mc wrote:
> Is it possible to import a Python library, such as graphviz, into an Ada package?
> So far I have only been able to find information on exporting Ada to Python.
I am not sure what you mean. Python is not a compiled language, so
formally speaking a Python library is not a library and you cannot
import it in the sense of linking it to your application and calling
subprograms from it using certain calling conventions.
If you rather meant whether you could execute a Python script from Ada
while passing parameters to it and taking results from, yes you can. If
that script were a part of some Python module, yes you can load it and
once loaded call (interpret) functions from the module.
P.S. Before you proceed, Python is a huge mess and interfacing it is a
pain in the ... So you should consider if Graphviz worths the efforts.
If you find a GTK or Qt library that doing approximately same, that
would be a wiser choice, IMO.
--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
next prev parent reply other threads:[~2020-12-04 10:23 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-04 7:36 Import Python library into an Ada package? Roger Mc
2020-12-04 10:23 ` Dmitry A. Kazakov [this message]
2020-12-04 11:37 ` Roger Mc
2020-12-04 13:55 ` Simon Wright
2020-12-04 13:22 ` Niklas Holsti
2020-12-04 13:41 ` gautier...@hotmail.com
2020-12-04 18:32 ` Björn Lundin
2020-12-04 19:08 ` Roger Mc
2020-12-04 19:40 ` Niklas Holsti
2020-12-04 21:25 ` Björn Lundin
2020-12-04 23:33 ` Roger Mc
2020-12-04 21:09 ` Dmitry A. Kazakov
2020-12-04 21:15 ` Roger Mc
2020-12-04 21:12 ` Per Sandberg
2020-12-04 21:19 ` Roger Mc
2020-12-04 23:17 ` Dmitry A. Kazakov
2020-12-04 23:42 ` Roger Mc
2020-12-04 23:57 ` Roger Mc
2020-12-05 0:13 ` Roger Mc
2020-12-05 9:38 ` Dmitry A. Kazakov
[not found] ` <f185d71f-2217-4e1f-b6bc-bd854738999an@googlegroups.com>
2020-12-16 23:58 ` Roger Mc
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox