[Asterisk-Dev] Looking at the * codebase, some standards need to be applied (! C99)

Andrew Paprocki andrew at ishiboo.com
Wed Nov 3 10:40:22 MST 2004


I've just started delving into * code in an attempt to see what is preventing it from being easily ported to other platforms.. It appears to me that no effort has been made to restrict the use of C99 language in the code. This is a major headache and block to getting this code to compile on any other platform using native compilers that either do not have C99 compatibility or it is not used for other reasons.

Two main offenders that have quickly caught my eye are the "inline" keyword being used in many places (18 in include/asterisk, 30 in ./*.c) and also the use of C++ style one-line comments EVERYWHERE:

//! This is such a silly idea to put in C code

--------------> My main reason for posting:

1) Can a concerted effort be made by active developers going forward to code in standard ANSI C89 to provide maximum portability to other operating systems?

2) Can a configure system be setup for the codebase to allow keywords such as "inline" only if the compiler supports it?

3) If patches were made available to remove the C99-ness of the * code, would they be incorporated into codebase?



More information about the asterisk-dev mailing list