aboutsummaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* dirdeps.mk now sets DEP_RELDIRSimon J. Gerraty2015-06-08168-528/+783
| | | | Notes: svn path=/projects/bmake/; revision=284172
* Fix include of atf-c.hSimon J. Gerraty2015-05-302-1/+3
| | | | Notes: svn path=/projects/bmake/; revision=283774
* Merge sync of headSimon J. Gerraty2015-05-27832-12341/+21496
|\ | | | | | | Notes: svn path=/projects/bmake/; revision=283595
| * Remove the stray DEBUG_FLAGS=-g line that snuck in with theWarner Losh2015-05-211-1/+0
| | | | | | | | | | | | | | soft-updates journaling project merge in r207141. Notes: svn path=/head/; revision=283243
| * Drop libmandoc and incorporate it into the main mandoc MakefileBaptiste Daroussin2015-05-212-45/+0
| | | | | | | | | | | | | | | | This simplifies maintainance of mandoc(1). Note that the same direction was taken on OpenBSD Notes: svn path=/head/; revision=283220
| * Remove clause 3 and 4 from the licenseBaptiste Daroussin2015-05-211-2/+0
| | | | | | | | | | | | | | Obtained from: NetBSD Notes: svn path=/head/; revision=283201
| * Create links to the libprocstat man pages for all of the libprocstat ↵Allan Jude2015-05-212-26/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | functions so they can be looked up by name Add a cross refrence to libprocstat in the procstat.1 man page Differential Revision: https://reviews.freebsd.org/D2578 Suggested by: jmg Reviewed by: brueffer Approved by: wblock (mentor) MFC after: 1 week Sponsored by: ScaleEngine Inc. Notes: svn path=/head/; revision=283167
| * Remove the write-only variable phent. We currently do not check theKonstantin Belousov2015-05-201-5/+0
| | | | | | | | | | | | | | | | | | | | | | size of the program header's entries. Reported by: adrian (by using gcc 4.9) Sponsored by: The FreeBSD Foundation MFC after: 1 week Notes: svn path=/head/; revision=283153
| * Fix underlinkingBaptiste Daroussin2015-05-191-0/+2
| | | | | | | | Notes: svn path=/head/; revision=283132
| * All FreeBSD platforms are elf: move i386-elf to i386Ed Maste2015-05-196-3/+2
| | | | | | | | | | | | | | | | | | | | | | This was a leftover from when we had both i386 a.out and ELF. Reviewed by: kib, imp Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D2591 Notes: svn path=/head/; revision=283125
| * Use fixed enum values for PMC_CLASSES().John Baldwin2015-05-191-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | This removes one of the frequent causes of ABI breakage when new CPU types are added to hwpmc(4). Differential Revision: https://reviews.freebsd.org/D2586 Reviewed by: davide, emaste, gnn (earlier version) MFC after: 2 weeks Notes: svn path=/head/; revision=283120
| * Add Performance Monitoring Counters support for AArch64.Ruslan Bukin2015-05-191-0/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | Family-common and CPU-specific counters implemented. Supported CPUs: ARM Cortex A53/57/72. Reviewed by: andrew, bz, emaste, gnn, jhb Sponsored by: ARM Limited Differential Revision: https://reviews.freebsd.org/D2555 Notes: svn path=/head/; revision=283112
| * Synchronize libedit with NetBSDBaptiste Daroussin2015-05-188-72/+116
| | | | | | | | | | | | | | | | It incorporates and fixes our patches to get el_gets return the proper count of characters in unicode mode. Notes: svn path=/head/; revision=283084
| * Drop some unnecessary casts.Pedro F. Giffuni2015-05-181-4/+3
| | | | | | | | | | | | | | | | Reported by: Clang static analyzer Obtained from: NetBSD Notes: svn path=/head/; revision=283068
| * In r279493, the functions pzero[f](), qzero[f], pone[f](),Steve Kargl2015-05-174-4/+4
| | | | | | | | | | | | | | | | | | | | | | and qone[f]() were marked as __inline, but their forward declarations were not updated. Fix the forward declarations to match the actual function declarations. Requested by: bde Notes: svn path=/head/; revision=283032
| * Some third-party malloc(3) implementations use pthread_setspecific(3)Konstantin Belousov2015-05-151-110/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to handle per-thread information. Since our pthread_setspecific() implementation calls calloc(3) to allocate per-thread specific data storage, things get complicated. Switch the allocator to use bare mmap(2). There is some loss of the allocated page, since e.g. on amd64, PTHREAD_KEYS_MAX * sizeof(struct pthread_specific_elem) is 3K (it actually spans whole page due to padding), but I believe it is more acceptable than additional code for specialized allocator(). The alternatives would either to make the specific data array be part of the struct thread, or use internal bindings to call the libc malloc, avoiding interposing. Also do the style pass over the thr_spec.c, esp. simplify the conditionals nesting by returning early when an error detected. Remove trivial comments. Found by: yuri@rawbw.com PR: 200138 Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Notes: svn path=/head/; revision=282948
| * Update to ELF Tool Chain r3197Ed Maste2015-05-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Highlights: - Fix man page markup, whitespace, and typos - Fix sh_info of SHT_GROUP section to point to the correct string - Improve validation in readelf and elfcopy/strip - Handle DWARF 4's DW_AT_high_pc in addr2line Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=282918
| * Add fabs() to arm64 libcEd Maste2015-05-143-1/+36
| | | | | | | | | | | | | | | | Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D2532 Notes: svn path=/head/; revision=282909
| * Remove redundant csu subdir logicEd Maste2015-05-121-11/+1
| | | | | | | | | | | | | | | | | | | | | | | | The appropriate subdirectories are handled by lib/csu/Makefile. There's no need to duplicate this logic in Makefile.inc1 and lib/Makefile. Reviewed by: imp Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D2523 Notes: svn path=/head/; revision=282821
| * Teach bits of libc about Thumb. This adds the if-then instructions neededAndrew Turner2015-05-125-4/+48
| | | | | | | | | | | | | | | | | | | | | | | | to handle the ARM conditional execution. While here fix a bug found by this in the hard-float code, cc is the opposite of cs. The former is used for 'less than' in floating-point code and is executed when the C (carry) bit is clear, the latter is used when greater than, equal, or unordered, and is executed when the C bit is set. Notes: svn path=/head/; revision=282816
| * Revert r282775 for now. The added dependency would cause problems forXin LI2015-05-123-5/+12
| | | | | | | | | | | | | | | | | | e.g. ports-mgmt/pkg and we would like to do an exp-build. Requested by: bdrewery Notes: svn path=/head/; revision=282808
| * Use the GOT_* macros to help simplify the code, these work with both picAndrew Turner2015-05-112-26/+9
| | | | | | | | | | | | | | and non-pic code, and to build for Thumb. Notes: svn path=/head/; revision=282782
| * Revert r281372, it's no longer needed after r282726 (fix for PR 199119) as theXin LI2015-05-113-12/+5
| | | | | | | | | | | | | | symbol conflict between libmd and libcrypto have been solved. Notes: svn path=/head/; revision=282775
| * Unbreak MIPS build following rev. 282726Thomas Quinot2015-05-118-6/+49
| | | | | | | | | | | | | | | | | | | | | | Introduce further adjustments to the renaming of libmd symbols: make sure that we do not generate dangling weak aliases, as this causes build failures on MIPS. Tested by: sbruno Notes: svn path=/head/; revision=282774
| * Unbreak build following rev. 282726Thomas Quinot2015-05-106-0/+130
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (Makefile.inc1): add dependency of xinstall on libmd to avoid failure of parallel bootstrap. (lib/libmd/*.h): do not redefine symbols if already defined as macros (libcrypt uses the same sources internally, redefining symbols with a prefix of its own). Fixes build failures caused by previous change to libmd. Reported by: ian Pointy hat to: thomas Notes: svn path=/head/; revision=282736
| * recv(),send(): Directly call interposing entry instead of going through PLT.Jilles Tjoelker2015-05-102-2/+10
| | | | | | | | | | | | | | | | | | recv() and send()'s calls to recvfrom() and sendto() are much like waitpid()'s call to wait4(), and likewise need not allow PLT interposing on the called function. Notes: svn path=/head/; revision=282729
| * Ensure libmd symbols do not clash with libcryptoThomas Quinot2015-05-1014-1/+195
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a prefix to all symbols in libmd to avoid incompatibilites with same-named, but not binary compatible, symbols from libcrypto. Also introduce Weak aliases to avoid the need to rebuild dependent binaries and a major version bump. PR: 199119 Differential Revision: D2216 Reviewed by: roberto, delphij MFC after: 2 weeks Notes: svn path=/head/; revision=282726
| * Tweak the comment here some more. In particular, the previous openingJohn Baldwin2015-05-061-7/+7
| | | | | | | | | | | | | | | | | | sentence was a bit confusing. Noted by: kib Notes: svn path=/head/; revision=282560
| * Deprecate the 3-way return values from vm_gla2gpa() and vm_copy_setup().Neel Natu2015-05-062-26/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prior to this change both functions returned 0 for success, -1 for failure and +1 to indicate that an exception was injected into the guest. The numerical value of ERESTART also happens to be -1 so when these functions returned -1 it had to be translated to a positive errno value to prevent the VM_RUN ioctl from being inadvertently restarted. This made it easy to introduce bugs when writing emulation code. Fix this by adding an 'int *guest_fault' parameter and setting it to '1' if an exception was delivered to the guest. The return value is 0 or EFAULT so no additional translation is needed. Reviewed by: tychon MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D2428 Notes: svn path=/head/; revision=282558
| * Remove the note about seekdir() removing telldir() cookies. That wasJohn Baldwin2015-05-061-7/+1
| | | | | | | | | | | | | | | | | | removed back in r269204. MFC after: 3 days Notes: svn path=/head/; revision=282552
| * A few style fixes and expand the comment a bit on what _fixtelldir() isJohn Baldwin2015-05-061-6/+10
| | | | | | | | | | | | | | doing. Notes: svn path=/head/; revision=282550
| * Tweak seekdir, telldir and readdir so that when htere are deletes going on,Julian Elischer2015-05-055-1/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | as seek to teh last location saved will still work. This is needed for Samba to be able to correctly handle delete requests from windows. This does not completely fix seekdir when deletes are present but fixes the worst of the problems. The real solution must involve some changes to the API for eh VFS and getdirentries(2). Obtained from: Panzura inc MFC after: 1 week Notes: svn path=/head/; revision=282485
| * Fix major copy/paste and other style errors.Sergey Kandaurov2015-05-051-5/+10
| | | | | | | | Notes: svn path=/head/; revision=282472
| * Rework PRIVATELIBBaptiste Daroussin2015-05-042-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now when a lib is marked as PRIVATELIB it is renamed into libprivate$foo instead of being installed in /usr/lib/private and playing with rpath. Also allow to install headers for PRIVATELIBS in that case the headers will be installed in /usr/include/private/$foo Keep the headers under a private namespace to prevent third party build system to easily find them to ensure they are only used on purpose. This allows for non base applications to statically link against a library in base which is linked to a privatelib Treating PRIVATELIBS as regular libraries allows to push them into our current compatX packages if needed. While here finish promotion of libevent as PRIVATELIB Install header for bsdstat and libucl Differential Revision: https://reviews.freebsd.org/D2365 Reviewed by: brooks, des Discussed with: imp Notes: svn path=/head/; revision=282420
| * Various updates to the ftruncate(2) documentation:John Baldwin2015-05-041-7/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Note that ftruncate(2) can operate on shared memory objects and cross reference shm_open(2). - Note that ftruncate(2) does not change the file position pointer (aka seek pointer) of the file descriptor. - ftruncate(2) will fail with EINVAL for all sorts of other fd types than just sockets, so instead note that it fails for all but regular files and shared memory objects. - Note that ftruncate(2) also appeared in 4.2BSD along with truncate(2). (Or at least the manpage for both appeared in 4.2, I did not check the kernel code itself to see if either predated 4.2.) PR: 199472 (2) Submitted by: andrew@ugh.net.au (2) MFC after: 1 week Notes: svn path=/head/; revision=282417
| * Partially revert r255486, the first argument to socketpair() is a socketJohn Baldwin2015-05-041-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | domain, not a file descriptor. Use 'domain' instead of the original 'd' for this argument to match socket(2). PR: 199491 Reported by: sp55aa@qq.com MFC after: 1 week Notes: svn path=/head/; revision=282416
| * Add test case for unpack with diffrent flags.Mariusz Zaborski2015-05-021-0/+35
| | | | | | | | | | | | | | Approved by: pjd (mentor) Notes: svn path=/head/; revision=282348
| * Introduce the NV_FLAG_NO_UNIQUE flag. When set, it allows to storeMariusz Zaborski2015-05-021-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | multiple values using the same key in a nvlist. Approved by: pjd (mentor) Obtained from: WHEEL Systems (http://www.wheelsystems.com) Update man page. Reviewed by: AllanJude Approved by: pjd (mentor) Notes: svn path=/head/; revision=282347
| * Approved, oprócz użycie RESTORE_ERRNO() do ustawiania errno.Mariusz Zaborski2015-05-0213-39/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change the nvlist_recv() function to take additional argument that specifies flags expected on the received nvlist. Receiving a nvlist with different set of flags than the ones we expect might lead to undefined behaviour, which might be potentially dangerous. Update consumers of this and related functions and update the tests. Approved by: pjd (mentor) Update man page for nvlist_unpack, nvlist_recv, nvlist_xfer, cap_recv_nvlist and cap_xfer_nvlist. Reviewed by: AllanJude Approved by: pjd (mentor) Notes: svn path=/head/; revision=282346
| * fork(2): Add a note to the effect that kqueue descriptors, unlike otherMark Johnston2015-05-021-2/+5
| | | | | | | | | | | | | | | | | | | | descriptor types, are not inherited from the parent process. Reported by: kmacy MFC after: 1 week Notes: svn path=/head/; revision=282333
| * Apply the copyright the the same owners as the original malloc(3) where most ofBaptiste Daroussin2015-05-011-2/+3
| | | | | | | | | | | | | | | | | | | | | | the text here comes from Reported by: many Discussed with: miod@OpenBSD.org Pointyhat to: bapt Notes: svn path=/head/; revision=282321
| * libc now has reallocarrayBaptiste Daroussin2015-05-011-2/+0
| | | | | | | | Notes: svn path=/head/; revision=282316
| * Import reallocarray(3) from OpenBSDBaptiste Daroussin2015-05-014-2/+182
| | | | | | | | | | | | | | | | | | | | | | | | Add a manpage for it, assign the copyright to the OpenBSD project on it since it is mostly copy/paste from OpenBSD manpage. style(9) fixes Differential Revision: https://reviews.freebsd.org/D2420 Reviewed by: kib Notes: svn path=/head/; revision=282314
| * Add nvlist_flags() function, which returns nvlist's public flags.Mariusz Zaborski2015-05-012-1/+11
| | | | | | | | | | | | | | Approved by: pjd (mentor) Notes: svn path=/head/; revision=282312
| * Sort MLINKS alphabetically.Mariusz Zaborski2015-05-011-46/+46
| | | | | | | | | | | | | | Approved by: pjd (mentor) Notes: svn path=/head/; revision=282304
| * Unreak DNS usage through libcapsicum, which broke, e.g., ping in r282252Bjoern A. Zeeb2015-05-011-1/+1
| | | | | | | | | | | | | | | | | | with what looks like a copy and paste error. Sponsored by: DARPA/AFRL Notes: svn path=/head/; revision=282298
| * Remove the nvlist_.*[fv] functions.Mariusz Zaborski2015-04-291-82/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Those functions are problematic, because there is no way to report memory allocation problems without complicating the API, so we can either abort or potentially return invalid results. None of which is acceptable. In most cases the caller knows the size of the name, so he can allocate buffer on the stack and use snprintf(3) to prepare the name. After some discussion the conclusion is to removed those functions, which also simplifies the API. Discussed with: pjd, rstone Approved by: pjd (mentor) Notes: svn path=/head/; revision=282257
| * Remove the use of nvlist_.*[fv] functions from tests.Mariusz Zaborski2015-04-292-48/+24
| | | | | | | | | | | | | | Approved by: pjd (mentor) Notes: svn path=/head/; revision=282254
| * Remove the use of nvlist_.*[vf] functions from libcapsicum and replaceMariusz Zaborski2015-04-293-20/+59
| | | | | | | | | | | | | | | | | | them with snprintf(3). Assert the results of snprintf(3). Approved by: pjd (mentor) Notes: svn path=/head/; revision=282252
| * The presence/absence of CPU features should be tested withWarner Losh2015-04-281-1/+3
| | | | | | | | | | | | | | | | | | | | MACHINE_CPUARCH or MACHINE_ARCH, not MACHINE. The latter is for kernel only things. Also, I think this should be unconditional since all our architectures have long double support, but I don't have time to test that thoroughly so just add a comment to that effect. Notes: svn path=/head/; revision=282146