summaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)AuthorFilesLines
2012-09-30add getopt reset supportRich Felker1-1/+1
based on proposed patches by Daniel Cegiełka, with minor changes: - use a weak symbol for optreset so it doesn't clash with namespace - also reset optpos (position in multi-option arg like -lR) - also make getopt_long support reset
2012-09-30define some _POSIX_* macros that were omitted; required for XSI conformanceRich Felker1-0/+3
2012-09-29always expose accept4Rich Felker1-4/+1
it will be in the next version of POSIX
2012-09-29always expose dup3 and pipe2Rich Felker1-2/+2
they will be in the next version of POSIX
2012-09-29microblaze portRich Felker1-0/+24
based on initial work by rdp, with heavy modifications. some features including threads are untested because qemu app-level emulation seems to be broken and I do not have a proper system image for testing.
2012-09-21LFS64 alias for prlimitRich Felker1-0/+1
issue reported/requested by Justin Cormack
2012-09-16add clock_adjtime, remap_file_pages, and syncfs syscall wrappersRich Felker3-0/+11
patch by Justin Cormack, with slight modification
2012-09-15fix stupid bug in updating of O_ACCMODE for O_SEARCH supportRich Felker1-1/+1
this could cause major bugs, and warrants a fix release right away.
2012-09-13strsep is BSD|GNU, not GNU-only; it's originally from BSDRich Felker1-1/+4
2012-09-13add O_PATH/O_SEARCH support to fcntl.hRich Felker1-1/+1
I'm not 100% sure that Linux's O_PATH meets the POSIX requirements for O_SEARCH, but it seems very close if not perfect. and old kernels ignore it, so O_SEARCH will still work as desired as long as the caller has read permissions to the directory.
2012-09-09add setdomainname syscall, fix getdomainname (previously a stub)Rich Felker1-0/+1
2012-09-09mincore syscall wrapperRich Felker1-0/+1
2012-09-09fix up lfs64 junk for preadv/pwritevRich Felker1-0/+5
2012-09-09add preadv/pwritev syscall wrappersRich Felker1-0/+9
2012-09-09fix typo introduced in poll.hRich Felker1-1/+1
2012-09-09add linux ppoll syscall wrapperRich Felker1-0/+10
2012-09-08syscall organization overhaulRich Felker1-18/+0
now public syscall.h only exposes __NR_* and SYS_* constants and the variadic syscall function. no macros or inline functions, no __syscall_ret or other internal details, no 16-/32-bit legacy syscall renaming, etc. this logic has all been moved to src/internal/syscall.h with the arch-specific parts in arch/$(ARCH)/syscall_arch.h, and the amount of arch-specific stuff has been reduced to a minimum. changes still need to be reviewed/double-checked. minimal testing on i386 and mips has already been performed.
2012-09-08add acct, accept4, setns, and dup3 syscalls (linux extensions)Rich Felker4-0/+82
based on patch by Justin Cormack
2012-09-08add IPPROTO_HOPOPTS to in.hRich Felker1-0/+1
2012-09-08add IPPROTO_MAX to in.hRich Felker1-0/+1
2012-09-08fix redundant _Noreturn def in err.hRich Felker1-7/+1
not sure why this was missed in the earlier commit.
2012-09-08remove all remaining redundant __restrict/__inline/_Noreturn defsRich Felker14-76/+14
2012-09-08sysmacros major/minor: result should have type unsigned int, not dev_tRich Felker1-2/+2
2012-09-08add linux tee syscallRich Felker1-0/+1
2012-09-08add linux sync_file_range syscallRich Felker1-0/+4
2012-09-08add linux readahead syscallRich Felker1-0/+1
2012-09-08add fallocate (nonstandardized) functionRich Felker1-0/+3
this is equivalent to posix_fallocate except that it has an extra mode/flags argument to control its behavior, and stores the error in errno rather than returning an error code.
2012-09-08add timerfd interfaces (untested)Rich Felker1-0/+18
2012-09-08add stdnoreturn.h (C11)Rich Felker1-0/+5
features.h contains the fallback logic for pre-C11 compilers
2012-09-07TCP_* is in the reserved namespace for tcp.h; make use of thatRich Felker1-3/+4
2012-09-07remove unneeded judgemental commentary from ftw.hRich Felker1-4/+0
2012-09-07default features: make musl usable without feature test macrosRich Felker47-116/+100
the old behavior of exposing nothing except plain ISO C can be obtained by defining __STRICT_ANSI__ or using a compiler option (such as -std=c99) that predefines it. the new default featureset is POSIX with XSI plus _BSD_SOURCE. any explicit feature test macros will inhibit the default. installation docs have also been updated to reflect this change.
2012-09-06provide loff_t for splice syscallRich Felker1-0/+1
so far, this is the only actual use of loff_t i've found. some software, including glib, assumes loff_t must exist if splice exists; this is a reasonable assumption since the official prototype for splice uses loff_t, as it always works with 64-bit offsets regardless of the selected libc off_t size. i'm using #define for now rather than a typedef to make it easy to define in other headers if necessary (like the LFS64 ugliness), but it may be necessary to add it to alltypes.h eventually if other functions end up needing it.
2012-09-06further use of _Noreturn, for non-plain-C functionsRich Felker5-9/+37
note that POSIX does not specify these functions as _Noreturn, because POSIX is aligned with C99, not the new C11 standard. when POSIX is eventually updated to C11, it will almost surely give these functions the _Noreturn attribute. for now, the actual _Noreturn keyword is not used anyway when compiling with a c99 compiler, which is what POSIX requires; the GCC __attribute__ is used instead if it's available, however. in a few places, I've added infinite for loops at the end of _Noreturn functions to silence compiler warnings. presumably __buildin_unreachable could achieve the same thing, but it would only work on newer GCCs and would not be portable. the loops should have near-zero code size cost anyway. like the previous _Noreturn commit, this one is based on patches contributed by philomath.
2012-09-06add _Noreturn function attribute, with fallback for pre-C11 GNUCRich Felker2-5/+19
2012-09-06dladdr should be available under _BSD_SOURCE as well as _GNU_SOURCERich Felker1-1/+1
2012-09-06use restrict everywhere it's required by c99 and/or posix 2008Rich Felker28-184/+353
to deal with the fact that the public headers may be used with pre-c99 compilers, __restrict is used in place of restrict, and defined appropriately for any supported compiler. we also avoid the form [restrict] since older versions of gcc rejected it due to a bug in the original c99 standard, and instead use the form *restrict.
2012-09-02avoid "inline" in public headers for strict c89 compatibilityRich Felker4-27/+22
while musl itself requires a c99 compiler, some applications insist on being compiled with c89 compilers, and use of "inline" in the headers was breaking them. much of this had been avoided already by just skipping the inline keyword in pre-c99 compilers or modes, but this new unified solution is cleaner and may/should result in better code generation in the default gcc configuration.
2012-09-01fix wrong type for poll.h nfds_tRich Felker1-1/+1
this should not break anything since the type should never be used except as the argument type for poll.
2012-08-26dladdr support for dynamic linker (nonstandard extension)Rich Felker1-0/+10
based on patches submitted by boris brezillon. this commit also fixes the issue whereby the main application and libc don't have the address ranges of their mappings stored, which was theoretically a problem for RTLD_NEXT support in dlsym; it didn't actually matter because libc never calls dlsym, and it seemed to be doing the right thing (by chance) for symbols in the main program as well.
2012-08-25implement "low hanging fruit" from C11Rich Felker3-0/+18
based on Gregor's patch sent to the list. includes: - stdalign.h - removing gets in C11 mode - adding aligned_alloc and adjusting other functions to use it - adding 'x' flag to fopen for exclusive mode
2012-08-25add c11 quick_exit and at_quick_exit functionsRich Felker1-0/+2
2012-08-24type exposure fixes in sys/sem.hRich Felker1-2/+5
2012-08-24stdio_ext.h needs to include stdio.h, at least to get FILE...Rich Felker1-0/+2
2012-08-24fix missing uintXX_t in nameser.hRich Felker1-0/+2
2012-08-24fix dirent.h with _BSD_SOURCERich Felker1-0/+3
2012-08-15improve headers to better deal with removed-in-posix-2008 featuresRich Felker2-13/+22
with this patch, setting _POSIX_SOURCE, or setting _POSIX_C_SOURCE or _XOPEN_SOURCE to an old version, will bring back the interfaces that were removed in POSIX 2008 - at least the ones i've covered so far, which are gethostby*, usleep, and ualarm. if there are other functions still in widespread use that were removed for which similar changes would be beneficial, they can be added just like this.
2012-08-15add missing xattr functionsRich Felker1-0/+3
not sure why these were originally omitted..
2012-08-13math: fix _BSD_SOURCE namespace in math.hnsz1-25/+26
2012-08-13remove significandlRich Felker1-1/+0
this function never existed historically; since the float/double functions it's based on are nonstandard and deprecated, there's really no justification for its existence except that glibc has it. it can be added back if there's ever really a need...