Creating a Compiler-Independent Socket Library

Creating a Compiler-Independent Socket Library

The Ada Awards Committee has nominated for an award the task of creating a compiler-independent socket library named Sockets.

Motivation

Portability is an important aspect of Ada. Currently there is only GNAT.Sockets and AdaSockets, both GNAT specific and both bindings. The goals of the Ada Awards would be furthered by a compiler-independent library (not a binding). Sockets should cover at a minimum the functionality of GNAT.Sockets and GNAT.Sockets.Poll.

Goals

The final deliverables are the Sockets library, well documented in package specifications and any additional documentation needed, and a demonstration of its use in a modification of the Ada-GUI sample implementation that uses the library in place of GNAT.Sockets.

The library will conform to an existing, consistent, and well reasoned coding standard such as the PragmAda Coding Standard. All Ada will be Ada 12 and demonstrated on multiple Ada-12 compilers (currently GNAT and ObjectAda).

Milestones

Part 1 (Award: 150 EUR)

  • The library
  • The internal documentation
  • Any external documentation

Part 2 (Award: 150 EUR)

  • A version of the Ada-GUI sample implementation that uses the library
  • Versions of the Show_All test program created with multiple compilers

Guidelines and further indications

The general Ada Awards Guidelines apply to this proposal for those who want to participate. For open, technical discussions on this topic or project, feel free to open topics under the Active Projects forum category.

Best regards,
The Ada Awards Committee.

5 Likes

Just curious, does this mean an idiomatic Ada API doing its own interfacing to platform-specific C APIs, like I have done with Padlock?

Did you consider

  • raw sockets (used in diagnostics, security, field real-time protocols, based on the data link layer like EtherCAT, etc)
  • multicast sockets (used in streaming)

Me? I did ask whether the approach I took with Padlock is what is expected, not whether it’s a solution :slight_smile: