From: Christopher Croughton Message-Id: <97Aug5.091539gmt+0100.17042@internet01.amc.de> Subject: Re: "Missing" functions To: orly AT gibson DOT eee DOT upd DOT edu DOT ph (Orlando Andico) Date: Tue, 5 Aug 1997 08:18:34 +0100 Cc: crough45 AT amc DOT de, J DOT Bischoff AT airbus DOT dasa DOT de, djgpp AT delorie DOT com In-Reply-To: from "Orlando Andico" at Aug 5, 97 04:12:02 am Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk Orlando Andico wrote: > > strcasecmp() and its ilk are available to my experience on Linux (and all > other systems that use GNU libc), SGI IRIX 5.x/6.x, Digital UNIX v3.2, and ^^^^^^^^^^^^^^^^^ That's the point. It seems to be mainly the GNU version of libc which has them. If you have GNU libc installed for your system, you're OK. If you use the native one (the one which comes with the manufacturer's version of cc) it may well be missing. > "The index, rindex, strcasecmp, strncasecmp routines are from the > 4.3BSD or 4.3BSD-tahoe standard C library." Which is, of course, not 'standard' except on those sytems. The only standard is the ANSI one, and that doesn't mention it, so library manufacturers are free to not include nonstandard functions. > The manual page under Linux simply states that the function conforms to > BSD 4.3, while Solaris doesn't say anything. The Digital UNIX manual page > also adds that strncasecmp() can only be used for 7-bit ASCII and > shouldn't be used in internationalized applications. Ours seems to be missing. > Your statement surprised me because I have yet to come across a libc that > DOESN'T have strcasecmp() and company.. although I guess older System V > UNIX's might not have it. I've seen several over the years. Perhaps it's become more common now, but until another ANSI/ISO standard comes out including it or a replacement the only portable way to go is to ignore it. Chris C