1073 Commits

Author SHA1 Message Date
rafan
8ab5e45a8f - Back out previous ctype(3) fix for UTF-8 locale due to forward ABI
compatibility is still broken as we add new symbols to libc. Those
  symboles are __sbmaskrune, __sbistype, __sbtoupper and __sbtolower.
  The latter three are directly referred by binaries use ctype(3) family
  functions (see include/ctype.h for details). This means if a binary
  built on 6.3, it uses these symbols that are not available on older
  system.
- As this has been in 6 for a month, I intentionally leave these symbols
  in libc but map them to original version. So binary built after 602113
  will not be broken after this commit.
- Bump __FreeBSD_version for this back-out

PR:		116363
Discussed with:	kris, kensmith
Approved by:	re (kensmith)
2007-11-21 01:31:49 +00:00
rafan
2b868cc2c2 Restore ctype(3) ABI forward compatibility in 6.x world. This was broken
with last ctype(3) single-byte and multi-byte separation for fixing
operating on UTF-8 locale. To be specific, we introduced a new symbol in
libc. And this symbol is referred via inline functions here. So, you can
not run a binary built with this version of libc on an older system. To
restore the compatibility, make these functions built as non-inlined
form (see lib/libc/nomarco.c) and MFC rev 1.32 which drops the usage of
that symbol in question for __isctype(). As this may impact performance,
I only intend to fix in 6.x, but not 7 (not yet released) and 8 (it's HEAD).

Discussed on:	cvs-src
Requested by:	scottl
Reviewed by:	ache, delphij
Approved by:	re (kensmith)
2007-10-30 01:30:42 +00:00
rafan
428444e563 MFC ctype(3) fix for UTF-8 locale. See original commit log for details.
PR:		116363
Reported by:	Petr Hroudny <petr.hroudny at gmail.com>
Patched by:	ache
Reviewed by:	i18n@
Approved by:	re (kensmith)
OK-ed by:	portmgr
2007-10-24 14:32:33 +00:00
ticso
287974ed2d MFC: rev 1.6
declare struct tftphdr and embedded union as beeing packed, which is
required for arm.
2007-10-11 17:32:20 +00:00
schweikh
4c38c81a18 MFC rev. 1.3 from HEAD,
Comment the token after #endif, like we do everywhere else.
  Static analyzers like FlexeLint complain about it.
2007-02-09 14:24:48 +00:00
schweikh
e0c0e0c65f MFC rev. 1.5. from HEAD,
Properly parenthesize the __tg_is_complex() macro by moving a closing
  paren to where it belongs.
2007-02-09 14:21:54 +00:00
ume
4059cab8d0 MFC: Extend the nsswitch to support Services, Protocols and Rpc
databases.

	include/nsswitch.h:		1.4 (partly)
	include/rpc/rpcent.h:		1.3, 1.4
	lib/libc/net/Makefile.inc:	1.59 (partly)
	lib/libc/net/getproto.c:	1.6 (partly)
	lib/libc/net/getprotoent.c:	1.8 (partly)
	lib/libc/net/getprotoname.c:	1.6 (partly)
	lib/libc/net/getservbyname.c:	1.9
	lib/libc/net/getservbyport.c:	1.9
	lib/libc/net/getservent.c:	1.22 (partly)
	lib/libc/net/netdb_private.h:	1.12
	lib/libc/rpc/getrpcent.c:	1.15 (partly)
2007-01-20 14:59:12 +00:00
jhb
03131f35d3 MFC: Fix kenv() function prototype. 2007-01-04 19:59:41 +00:00
ume
1cf119375a MFC: Merge BIND9 9.3.3 into main chunk.
include/arpa/nameser_compat.h:	1.6
	lib/libc/inet/inet_cidr_ntop.c:	1.1.1.2
	lib/libc/inet/inet_net_ntop.c:	1.3
	lib/libc/isc/eventlib_p.h:	1.4
	lib/libc/resolv/mtctxres.c:	1.3
	lib/libc/resolv/res_init.c:	1.4
	lib/libc/resolv/res_send.c:	1.5
2006-12-22 07:33:20 +00:00
emax
3361db4c05 MFC:
Install vkbd(4) header into dev/vkbd.

Update bthidd(8) code and hook it up to the build. bthidd(8) now was integrated
with vkbd(4) and supports multiple keyboards via vkbd(4)/kbdmux(4).

The code was tested with Apple Bluetooth keyboard and SE k700i cell phone
(remote control feature).

Add bthidd(8) rc(8) script.

Approved by:	re (kensmith)
2006-10-09 21:00:17 +00:00
rwatson
f44f66180c Merge BSD.include.dist:1.106, include/Makefile:1.258 from HEAD to
RELENG_6:

  Do install sys/security/audit include files.  It would be nice just
  to install audit_ioctl.h, but we seem only to support installing
  directories, so we get them all.  The two not intended for extra-
  kernel use have !_KERNEL #error's, which should help.

Obtained from:	TrustedBSD Project
2006-09-03 08:09:58 +00:00
ume
ea7fc621ce MFC:
- Update the resolver in libc to BIND9's one.
  - make reentrant version of netdb functions glibc style API, and
    expose them to outside of libc.
  - make netdb functions NSS friendly.

	include/Makefile			1.261
	include/arpa/inet.h			1.26
	include/arpa/nameser.h			1.18
	include/arpa/nameser_compat.h		1.5
	include/netdb.h				1.40-1.42
	include/res_update.h			1.1
	include/resolv.h			1.29-1.30
	lib/libc/Makefile			1.64
	lib/libc/include/isc/eventlib.h		1.1.1.1
	lib/libc/include/port_after.h		1.1-1.2
	lib/libc/include/port_before.h		1.1
	lib/libc/include/resolv_mt.h		1.1.1.1
	lib/libc/inet/Makefile.inc		1.1
	lib/libc/inet/inet_addr.c		1.1.1.1, 1.2
	lib/libc/inet/inet_cidr_ntop.c		1.1.1.1
	lib/libc/inet/inet_cidr_pton.c		1.1.1.1, 1.2
	lib/libc/inet/inet_lnaof.c		1.1.1.1, 1.2
	lib/libc/inet/inet_makeaddr.c		1.1.1.1, 1.2
	lib/libc/inet/inet_net_ntop.c		1.1.1.1, 1.2
	lib/libc/inet/inet_net_pton.c		1.1.1.1, 1.2
	lib/libc/inet/inet_neta.c		1.1.1.1, 1.2
	lib/libc/inet/inet_netof.c		1.1.1.1, 1.2
	lib/libc/inet/inet_network.c		1.1.1.1, 1.2
	lib/libc/inet/inet_ntoa.c		1.1.1.1, 1.2
	lib/libc/inet/inet_ntop.c		1.1.1.1, 1.2
	lib/libc/inet/inet_pton.c		1.1.1.1, 1.2
	lib/libc/inet/nsap_addr.c		1.1.1.1, 1.2
	lib/libc/isc/Makefile.inc		1.1
	lib/libc/isc/ev_streams.c		1.1.1.1, 1.2
	lib/libc/isc/ev_timers.c		1.1.1.1, 1.2
	lib/libc/isc/eventlib_p.h		1.1.1.1, 1.2
	lib/libc/nameser/Makefile.inc		1.1
	lib/libc/nameser/ns_name.c		1.1.1.1
	lib/libc/nameser/ns_netint.c		1.1.1.1
	lib/libc/nameser/ns_parse.c		1.1.1.1
	lib/libc/nameser/ns_print.c		1.1.1.1, 1.2
	lib/libc/nameser/ns_samedomain.c	1.1.1.1, 1.2
	lib/libc/nameser/ns_ttl.c		1.1.1.1
	lib/libc/net/Makefile.inc		1.58
	lib/libc/net/getaddrinfo.c		1.74, 1.77-1.78
	lib/libc/net/gethostbydns.c		1.55-1.57
	lib/libc/net/gethostbyht.c		1.24-1.26
	lib/libc/net/gethostbyname.3		1.35
	lib/libc/net/gethostbynis.c		1.26-1.28
	lib/libc/net/gethostnamadr.c		1.29-1.30, 1.32
	lib/libc/net/getnameinfo.c		1.18
	lib/libc/net/getnetbydns.c		1.32-1.33
	lib/libc/net/getnetbyht.c		1.17-1.18
	lib/libc/net/getnetbynis.c		1.20-1.21
	lib/libc/net/getnetnamadr.c		1.22
	lib/libc/net/getproto.c			1.5
	lib/libc/net/getprotoent.c		1.7
	lib/libc/net/getprotoname.c		1.5
	lib/libc/net/getservbyname.c		1.8
	lib/libc/net/getservbyport.c		1.8
	lib/libc/net/getservent.c		1.21
	lib/libc/net/name6.c			1.56-1.57
	lib/libc/net/netdb_private.h		1.10-1.11, 1.13
	lib/libc/net/res_config.h		1.9
	lib/libc/net/res_mkupdate.c		1.7-1.8
	lib/libc/net/res_update.c		1.8-1.9
	lib/libc/resolv/Makefile.inc		1.1
	lib/libc/resolv/h_errno.c		1.1
	lib/libc/resolv/herror.c		1.1.1.1, 1.2
	lib/libc/resolv/mtctxres.c		1.1.1.1, 1.2
	lib/libc/resolv/res_comp.c		1.1.1.1, 1.2
	lib/libc/resolv/res_data.c		1.1.1.1, 1.2-1.3
	lib/libc/resolv/res_debug.c		1.1.1.1, 1.2
	lib/libc/resolv/res_debug.h		1.1.1.1
	lib/libc/resolv/res_init.c		1.1.1.1, 1.2
	lib/libc/resolv/res_mkquery.c		1.1.1.1, 1.2
	lib/libc/resolv/res_private.h		1.1.1.1
	lib/libc/resolv/res_query.c		1.1.1.1, 1.2-1.3
	lib/libc/resolv/res_send.c		1.1.1.1, 1.2
	lib/libc/resolv/res_state.c		1.1-1.2

Tested by:	nork
2006-07-17 10:09:58 +00:00
phk
45d0009c1b MFC:
Extensible printf implementation compatible with GLIBC
2006-06-25 07:35:51 +00:00
cvs2svn
47d76a2b91 This commit was manufactured by cvs2svn to create branch 'RELENG_6'. 2006-05-25 04:01:05 +00:00
davidxu
9bc741e58e MFC revision 1.4. 2006-05-17 02:28:14 +00:00
brooks
30e305b4eb MFC rev 1.13:
Fix ypwhich -m.  This should be MFC'ed back at least as far as RELENG_5.

Submitted by: Gil Kloepfer <gil@arlut.utexas.edu>
PR:		64445
Approved by:	re (scottl)
2006-04-21 05:14:20 +00:00
andre
0cbadcf68d MFC of import of OpenBSD's strtonum(3).
Approved by:	re
2006-04-04 19:56:46 +00:00
cvs2svn
9cb23632cc This commit was manufactured by cvs2svn to create branch 'RELENG_6'. 2006-03-08 18:03:10 +00:00
ume
7a2da0ef17 MFC 1.28: Decrease the value of RES_DFLRETRY from 4 to 2.
Approved by:	re (scottl)
2006-03-06 14:31:30 +00:00
stefanf
ce5ae18e82 Unbreak building RELENG_6 on RELENG_5 by providing a __format_arg macro if
it's not defined in <sys/cdefs.h>.  This situation happens early when building
the bootstrap-tools, where the new <nl_types.h> is mixed with the old
<sys/cdefs.h>.

Submitted by:	imp
Reviewed by:	ru
2006-02-01 12:24:39 +00:00
stefanf
b1424e33b5 MFC: Add the macro __format_arg which expands to the format_arg attribute if
supported.
2006-01-31 17:57:17 +00:00
trhodes
1266b75767 MFC:
Add a64l(), l64a(), and l64a_r() XSI extentions.  These functions convert
  between a 32-bit integer and a radix-64 ASCII string.  The l64a_r() function
  is a NetBSD addition.

  PR:             51209 (based on submission, but very different)
  Reviewed by:    bde, ru
2006-01-27 05:17:25 +00:00
davidxu
148697495d MFC revision 1.40:
Add prototype for following functions:
	pthread_condattr_getpshared
	pthread_condattr_setpshared
	pthread_mutexattr_getpshared
	pthread_mutexattr_setpshared
2005-12-15 06:50:39 +00:00
ru
3b474f83c7 MFC: Bring /dev/speaker support to amd64. 2005-11-16 10:50:12 +00:00
delphij
f93a29eca0 MFC stefanf's work on libedit. This includes a sync with NetBSD/OpenBSD
and some bugfixes.

Approved by:	re (scottl)
2005-10-09 03:44:01 +00:00
andre
e5068a6432 MFC addition of memmem(3).
Submitted by:	Pascal Gloor <pascal.gloor at spale.com>
Approved by:	re (scottl)
2005-08-29 18:46:39 +00:00
pjd
ce534181e2 MFC: Connect GEOM_ELI class to the build.
Sponsored by:	Wheel Sp. z o.o.
		http://www.wheel.pl
Approved by:	re (kensmith)
2005-08-05 20:02:46 +00:00
ume
34d108ce3b MFC: Remove padding for ABI compatibility of ai_addrlen member
from struct addrinfo.  This change break ABI compatibility on
64 bit arch.

	include/netdb.h:		1.39
	lib/libc/net/getaddrinfo.c:	1.70

Approved by:	re (kensmith)
2005-07-22 20:17:30 +00:00
jkoshy
1d3209ab83 MFP4:
- Implement sampling modes and logging support in hwpmc(4).

- Separate MI and MD parts of hwpmc(4) and allow sharing of
  PMC implementations across different architectures.
  Add support for P4 (EMT64) style PMCs to the amd64 code.

- New pmcstat(8) options: -E (exit time counts) -W (counts
  every context switch), -R (print log file).

- pmc(3) API changes, improve our ability to keep ABI compatibility
  in the future.  Add more 'alias' names for commonly used events.

- bug fixes & documentation.
2005-06-09 19:45:09 +00:00
ume
0d8a6fcf73 - Remove padding for ABI compatibility of n_net member from struct
netent.
- Change 1st argument of getnetbyaddr() to an uint32_t on 64 bit
  arch as well to confirm to POSIX-2001.

These changes break ABI compatibility on 64 bit arch.
There is similar padding issue for ai_addrlen of struct addrinfo.
However, it is leaved as is for now.

Discussed on:	arch@, standards@ and current@
X-MFC after:	never
2005-06-03 03:32:06 +00:00
rodrigc
055ba01ea7 According to:
http://www.opengroup.org/onlinepubs/009695399/basedefs/sys/types.h.html

#include <sys/types.h>
should include the definitions of pthread types.

PR:		standards/78907
Reported by:	Brooks Davis
Approved by:	das (mentor)
2005-05-31 15:18:17 +00:00
dfr
874478d7fd Add support for XMM registers in GDB for x86 processors that support
SSE (or its successors).

Reviewed by: marcel, davidxu
MFC After: 2 weeks
2005-05-31 09:43:04 +00:00
rwatson
5ca6f955b5 Correct mistake in previous commit: add 'bsm' to LDIRS not LSUBDIRS.
Pointy hat:	over here, please
2005-05-30 01:06:29 +00:00
rwatson
12b86b875b Do install BSM include files (such as they are) when installing system
includes.

Submitted by:	wsalamon
Obtained from:	TrustedBSD Project
2005-05-29 16:17:00 +00:00
ume
9409f5e4f1 disable defining NI_WITHSCOPEID. It was obsoleted, and was exist
only for backward compatibility since 5.2-RELEASE.
2005-05-27 19:02:12 +00:00
ru
86758e8895 Make <runefile.h> internal to libc.
Suggested by:	phantom
2005-05-16 09:32:41 +00:00
ume
7a6cd620d0 - The ai_addrlen of a struct addrinfo used to be a size_t, per
RFC 2553.  In XNS5.2, and subsequently in POSIX-2001 and RFC
  3493, it was changed to a socklen_t.  And, the n_net of a
  struct netent used to be an unsigned long integer.  In XNS5,
  and subsequently in POSIX-2001, it was changed to an uint32_t.
  To accomodate for this while preserving ABI compatibility with
  the old interface, we need to prepend or append 32 bits of
  padding, depending on the (LP64) architecture's endianness.
- Correct 1st argument of getnetbyaddr() to uint32_t on 32
  bit arch.  Stay as is on 64 bit arch for ABI backward
  compatibility for now.

Reviewed by:	das, peter
MFC after:	2 weeks
2005-05-15 20:15:15 +00:00
delphij
4c5083a81c Provide more POSIX-complaint ttyname_r(3) interface[1], which is slightly
different from what has been offered in libc_r (the one spotted in the
original PR which is found in libthr has already been removed by David's
commit, which is rev. 1.44 of lib/libthr/thread/thr_private.h):
	- Use POSIX standard prototype for ttyname_r, which is,
		int ttyname_r(int, char *, size_t);
	  Instead of:
	  	char *ttyname_r(int, char *, size_t);
	  This is to conform IEEE Std 1003.1, 2004 Edition [1].
	- Since we need to use standard errno for return code, include
	  errno.h in ttyname.c
	- Update ttyname(3) implementation according to reflect the API
	  change.
	- Document new ttyname_r(3) behavior
	- Since we already make use of a thread local storage for
	  ttyname(3), remove the BUGS section.
	- Remove conflicting ttyname_r related declarations found in libc_r.

Hopefully this change should not have changed the API/ABI, as the ttyname_r
symbol was never introduced before the last unistd.h change which happens a
couple of days before.

[1] http://www.opengroup.org/onlinepubs/009695399/functions/ttyname.html

Requested by:	Tom McLaughlin <tmclaugh sdf lonestar org>
Through PR:	threads/76938
Patched by:	Craig Rodrigues <rodrigc crodrigues org> (with minor changes)
Prompted by:	mezz@
2005-05-13 16:27:30 +00:00
delphij
41460d5099 Connect MLINKS for ttyname_r(3), and add prototype into unistd.h. 2005-05-11 14:07:25 +00:00
ume
1dcbf1fa6d hide implementation specific internal functions from netdb.h.
it is needed to make get{host,net}by*() thread-safe.
2005-04-27 19:12:57 +00:00
scottl
8392ca289b Conditionalize the ipfilter header files on NO_IPFILTER. While normally these
should be harmless, the kdump(1) build does evil things with collecting
system header files, and thus would unconditionally collect and process these.

MFC After: 3 days
2005-04-26 02:01:39 +00:00
davidxu
8d5bf26054 Increase PTHREAD_STACK_MIN to MINSIGSTKSZ because thread libraries now use
makecontext which enforces a minimum stack size to be MINSIGSTKSZ.

Bug report: Bill Middleton <flashdict at gmail dot com>, BSD-sharp project.
2005-04-11 03:47:42 +00:00
davidxu
a57604e980 Add pthread_condattr_getclock, pthread_condattr_setclock. 2005-04-03 23:55:02 +00:00
imp
b115dca3b2 Make sure that $_MARCH and friends exist
Submitted by: nyan@
2005-04-03 04:53:23 +00:00
das
ed4814bbdf Define CLOCK_* and TIMER_* in time.h, where they are supposed to be. 2005-04-02 12:33:27 +00:00
imp
6a96427b33 When $MACHINE != $MACHINE_ARCH, install $MACHINE_ARCH/include into
/usr/include/$MACHINE_ARCH in addition to installing $MACHINE/include
into /usr/include/machine.
2005-04-01 23:22:01 +00:00
das
5ac70244e5 - Declare mknod in stat.h (in addition to unistd.h), as per XSI.
- Use blksize_t and blkcnt_t in struct stat.
- Hide non-standard fields in stat.h when !__BSD_VISIBLE.
- Add restrict qualifiers in stat.h.
2005-03-22 01:19:18 +00:00
ume
5ce7e2e80a just use crypto/rijndael, and nuke opencrypto/rindael.[ch].
the two became almost identical since latest KAME merge.

Discussed with:	sam
2005-03-11 17:24:46 +00:00
njl
8ec4560902 Only install acpiio.h in /usr/include. That's all we want to export to users.
Submitted by:	ru (any bugs by me)
MFC after:	1 day
2005-03-02 10:45:09 +00:00
ru
e80e223f73 Sync the list of headers visible with SHARED=symlinks with those
visible with SHARED=copies.

Inspired by:	njl
2005-03-02 07:40:18 +00:00