SVR 4 header files

Guy Harris guy at auspex.auspex.com
Mon May 20 04:40:49 AEST 1991


>Version 4.1 of SunOS claims to be making strides towards SVR4 compatibility.
>Under previous releases of SunOS the definitions od to{upper,lower} were
>found in /usr/include/ctype.h. However under SunOS 4.1.1 these definitions
>are found in /usr/include/pcfs/pc_dir.h.

In SunOS 4.1[.x], they apparently decided to make "toupper()" and
"tolower()" be subroutines even in the BSD environment; they were always
subroutines in the S5 environment, because they're subroutines in S5
(because the S5 versions actually check whether what's being "toupper"ed
is a lower-case letter, and leave it alone if it isn't, and *vice
versa*).  Dunno if this was done to support character sets such as ISO
Latin #1 or not.

So the definitions are found in "/usr/lib/libc.{a,so.X.Y}" in the BSD
environment, and in "/usr/5lib/libc.{a,so.X.Y}" in the S5 environment
(for appropriate values of X and Y).

The versions in "/usr/include/pcfs/pc_dir.h" are there only for the
benefit of the kernel code in the PCFS file system (DOS file system);
they are *N*O*T* intended to be used by ordinary programs.

>Is this compatible with SVR4?

Yes.

S5R4, like other S5 systems, has "toupper()" and "tolower()" as
subroutines in the C library, not as macros.



More information about the Comp.unix.questions mailing list