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=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,d54630460ea6a38e,start X-Google-Attributes: gid103376,public From: Ken Raeburn Subject: q: pkg for network/UNIX programming; system dependencies Date: 1997/05/29 Message-ID: #1/1 X-Deja-AN: 244873825 Organization: Cygnus Support, Cambridge MA Newsgroups: comp.lang.ada Date: 1997-05-29T00:00:00+00:00 List-Id: I'm thinking about working on a couple small spare-time UNIX projects in Ada95 to help familiarize myself with the language. Most such projects I'm considering right now make use of networking, both TCP and UDP. I'm looking for a package to help me deal with UNIX system-defined types, socket- and network-related types and functionality, domain name service, etc. I've looked at the "paradise" package, which seems to have some of what I want, but the latest version I could find is about 3 years old, only works on SunOS and HP-UX and with three specific compilers (none of which is GNAT), and is specifically conditionalized in various places for those systems and compilers. If that's the closest thing available, I'll go with it; I just wanted to know if there's anything else. Oh and a general question: How do you usually deal with OS or configuration dependencies in Ada? For example, some systems have the utmpx functions, some don't; some have wait4, some don't. Maybe I'm building a package with a backwards-compatibility option enabled; maybe it's disabled. In C and UNIX, I'd use #ifdef and maybe an autoconf-generated script to test the system characteristics and user-provided options, and define some macros for conditional compilation. The conditionally-compiled region can be very small. Of course, there are times when it's large, and when it seems worthwhile to use a separate source file. But there are times when it isn't and it doesn't.... TIA, Ken