There is important information about booting non-ack images in docs/UPDATING. ack/aout-format images can't be built any more, and booting clang/ELF-format ones is a little different. Updating to the new boot monitor is recommended. Changes in this commit: . drop boot monitor -> allowing dropping ack support . facility to copy ELF boot files to /boot so that old boot monitor can still boot fairly easily, see UPDATING . no more ack-format libraries -> single-case libraries . some cleanup of OBJECT_FMT, COMPILER_TYPE, etc cases . drop several ack toolchain commands, but not all support commands (e.g. aal is gone but acksize is not yet). . a few libc files moved to netbsd libc dir . new /bin/date as minix date used code in libc/ . test compile fix . harmonize includes . /usr/lib is no longer special: without ack, /usr/lib plays no kind of special bootstrapping role any more and bootstrapping is done exclusively through packages, so releases depend even less on the state of the machine making them now. . rename nbsd_lib* to lib* . reduce mtree
52 lines
1 KiB
C
52 lines
1 KiB
C
/* $NetBSD: wcsncasecmp.c,v 1.2 2006/08/26 22:45:52 christos Exp $ */
|
|
|
|
/*
|
|
* Copyright (C) 2006 Aleksey Cheusov
|
|
*
|
|
* This material is provided "as is", with absolutely no warranty expressed
|
|
* or implied. Any use is at your own risk.
|
|
*
|
|
* Permission to use or copy this software for any purpose is hereby granted
|
|
* without fee. Permission to modify the code and to distribute modified
|
|
* code is also granted without any restrictions.
|
|
*/
|
|
|
|
#include <sys/cdefs.h>
|
|
#if defined(LIBC_SCCS) && !defined(lint)
|
|
__RCSID("$NetBSD: wcsncasecmp.c,v 1.2 2006/08/26 22:45:52 christos Exp $");
|
|
#endif /* LIBC_SCCS and not lint */
|
|
|
|
#include "namespace.h"
|
|
#include <assert.h>
|
|
#include <wchar.h>
|
|
#include <wctype.h>
|
|
|
|
__weak_alias(wcsncasecmp,_wcsncasecmp)
|
|
|
|
int
|
|
wcsncasecmp(const wchar_t *s1, const wchar_t *s2, size_t n)
|
|
{
|
|
int lc1 = 0;
|
|
int lc2 = 0;
|
|
int diff = 0;
|
|
|
|
_DIAGASSERT(s1);
|
|
_DIAGASSERT(s2);
|
|
|
|
while (n--) {
|
|
lc1 = towlower (*s1);
|
|
lc2 = towlower (*s2);
|
|
|
|
diff = lc1 - lc2;
|
|
if (diff)
|
|
return diff;
|
|
|
|
if (!lc1)
|
|
return 0;
|
|
|
|
++s1;
|
|
++s2;
|
|
}
|
|
|
|
return 0;
|
|
}
|