TITLE : Tips on porting C source code to AIX OS LEVEL : AIX C Compiler DATE : 10/03/99 VERSION : 1.0 ---------------------------------------------------------------------------- 1, When using time.h and the tm structure (eg GMT->tm_year), fails to compile with errors simular to :- pom.c: In function `main': pom.c:91: warning: assignment makes pointer from integer without a cast pom.c:93: dereferencing pointer to incomplete type Check that you are using :- #include and not :- #include ---------------------------------------------------------------------------- 2, getcodi.c:39: sys/cdefs.h: No such file or directory Remove :- #include #ifndef lint #if 0 static char sccsid[] = "@(#)getcodi.c 8.1 (Berkeley) 5/31/93"; #else __RCSID("$NetBSD: getcodi.c,v 1.4 1997/10/12 21:24:49 christos Exp $"); #endif #endif /* not lint */ ---------------------------------------------------------------------------- 3, damage.c:49: err.h: No such file or directory Remove :- #include Change the lines using errx eg errx(1,"Error with program"); to use printf and exit eg printf("Error with program"); exit(1); ---------------------------------------------------------------------------- 4, arithmetic.c:81: parse error before `__P' Change :- int problem __P((void)); int problem (void); ---------------------------------------------------------------------------- 5, Comment out all (or delete) int argc __attribute__((unused)); ---------------------------------------------------------------------------- 6, Change :- #include to :- #include