cc <sourcefile.c> -o <executablename> -lppruntim -ltdusr -lcliv2 -lnsl
Red Hat Linux 3.0
A compilation error occurs if:
- an attempt is made to compile a PP2 application on Red Hat Linux 3.0
- PPCMain has been built on Red Hat Linux 7.3
Fixing the Compilation Error (RedHat 3.0)
- Add this code to the .pc file:
===================================================================== #include <ctype.h> __const unsigned short int *__ctype_b; __const __int32_t *__ctype_tolower; __const __int32_t *__ctype_toupper; void ctSetup() { __ctype_b = *(__ctype_b_loc()); } =====================================================================
- Call ctSetup from main() as first statement.