summaryrefslogtreecommitdiffstats
path: root/libc/misc
Commit message (Collapse)AuthorAgeFilesLines
...
* Reduce memory used by static buffers and allocate that memory dynamiclyEric Andersen2004-03-182-3/+18
| | | | | | | | | | instead. Based on an initial patch from Tobias Anderberg, but reworked. I asked Tobias to look into doing something more like what is done in busybox, but that proved to be a pain. One possible concern is that these buffers will probably show up as memory leaks i.e. with valgrind. Perhaps we should add in an atexit call to free this memory right after we allocate it?
* Rewrite the err/warn functions as they were broken (__noreturn__ funcsManuel Novoa III2004-03-113-76/+111
| | | | | were returning). Anyway, also make them threadsafe and smaller. The error.c file still needs work.
* New stdio core. Should be more maintainable. Fixes a couple of bugs.Manuel Novoa III2004-02-116-68/+44
| | | | | | | | Codepaths streamlined. Improved performance for nonthreaded apps when linked with a thread-enabled libc. Minor iconv bug and some locale/thread related startup issues fixed. These showed up in getting a gcj-compiled java helloworld app running. Removed some old extension functions... _stdio_fdout and _stdio_fsfopen.
* Split up syscalls.c, since it had grown to be quite large and ugly.Eric Andersen2004-01-215-21/+18
| | | | -Erik
* Prevent runaway asserts, which can happen if there's a problem withManuel Novoa III2004-01-171-9/+15
| | | | stdio or locales.
* Add a dummy (always fails) wcsftime. This is needed for the libstdc++ localeManuel Novoa III2004-01-142-0/+36
| | | | implementation to build. Later this month I'll add a functional wcsftime.
* My mistake. We do need some weak pthread_* funcs. But we were previouslyManuel Novoa III2004-01-041-2/+87
| | | | | | | missing one in the glibc abi, and including a number of extras (which I left in commented). Unfortunately, this brings back the perl pthread bug. Fixing the incorrect weaks in libpthread wasn't sufficient to escape the shared loader bug. :-(
* Peter S. Mazinger writes:Eric Andersen2004-01-021-0/+7
| | | | | | | | | | | | | | | | | | | Hello Erik! I have made some cosmetical changes to the files, removed the added SCRT=-fPIC option from building the crt0.S file (but it is a requirement to build them with -fPIC), and changed some comments. I have left the ldso.c patch with PIE_SUPPORT ifdefs, but consider applying it w/o them (see some earlier comment from PaX Team on this issue, as it is considered a bug). To have it work correctly, you'll also need removing COMPLETELY_PIC. One thing is missing: PIE_SUPPORT should be usable only for i386 (for now). Also added the support for propolice protection (that works for me and catches memcpy/strcpy attacks (but needs a special gcc version). Thanks, Peter
* Handle the app_fini stuff in exit without requiring atexit().Manuel Novoa III2003-12-271-3/+4
| | | | This avoids pulling in all the malloc/free code for a simple true/false app.
* Fix a long-standing bug with pthreads. A couple of linuxthreads filesManuel Novoa III2003-12-2714-95/+30
| | | | | | | | | | | | | | | | were including libc-lock.h which had a bunch of weak pragmas. Also, uClibc supplied a number of no-op weak thread functions even though many weren't needed. This combined result was that sometimes the functional versions of thread functions in pthread would not override the weaks in libc. While fixing this, I also prepended double-underscore to all necessary weak thread funcs in uClibc, and removed all unused weaks. I did a test build, but haven't tested this since these changes are a backport from my working tree. I did test the changes there and no longer need to explicitly add -lpthread in the perl build for perl to pass its thread self tests.
* Fix some dst issues in _time_mktime().Manuel Novoa III2003-12-141-5/+12
| | | | | Normalize the tm_isdst value to -1, 0, or 1. If no dst for this timezone, then reset tm_isdst to 0.
* Fix a couple of 'declaration after statement' errors.Manuel Novoa III2003-12-141-2/+1
|
* Building of iconv.o was accidently always disabled.Manuel Novoa III2003-12-041-8/+4
| | | | Also, build the iconv app in utils.
* Always include locale.h, which was included by libintl.h only whenManuel Novoa III2003-11-201-0/+2
| | | | optimizing.
* I forgot to update the thread locking in the last dst fix.Manuel Novoa III2003-11-161-2/+4
|
* For now, disable the iconv utilityEric Andersen2003-11-081-8/+7
|
* Fix up several errors related to filename length and errno thatEric Andersen2003-11-081-2/+5
| | | | | showed up while running the latest LTP testsuite. -Erik
* Add clock_gettime() submitted by Justus Pendleton <uc@ryoohki.net>.Manuel Novoa III2003-11-072-1/+41
|
* Hopefully fix the struct tm extension problem once and for all.Manuel Novoa III2003-11-021-22/+65
| | | | Also fix a dst-related bug which caused the use of uninitialized data.
* Some more soft float fixes... for arm in particular (libfloat).Manuel Novoa III2003-10-311-1/+1
| | | | | | Remove the ADD_LIBGCC_FUNCTIONS option and do things the right way. Either we have a shared libgcc available, or the libgcc routines aren't PIC and don't belong in the shared libc anyway.
* Peter Kjellerstedt writes:Eric Andersen2003-10-181-1/+1
| | | | | | | | | | ln.patch: * Define $(LN) as ln in Rules.mak. * Change all occurrences of ln into $(LN). * Change all constructs like (cd path && ln -sf foo/file file) into $(LN) -sf foo/file path/file. The latter construct is already used in a number of places so it should not be an additional compatibility problem.
* Peter Kjellerstedt writes:Eric Andersen2003-10-1826-26/+26
| | | | | | | rm.patch: * Define $(RM) as rm -f in Rules.mak and test/Rules.mak (this is the same definition as gmake uses by default). * Change all occurrences of rm and rm -f into $(RM).
* Don't make two copiesEric Andersen2003-10-122-34/+40
|
* Sigh. It seems that csh wants glob_pattern_p(), we need toEric Andersen2003-10-121-5/+3
| | | | export it,
* Patch from Rob McMullen:Eric Andersen2003-10-091-0/+74
| | | | | | | | Here's a patch... Since they aren't SUSv3 functions, I don't know if they'll ever get officially added, but it helps with BSD porting and allows quite a few Gentoo ebuilds to compile without changing anything. Rob
* Apply a trivial patch that doesn't change anything, but which is alledged toEric Andersen2003-10-081-1/+1
| | | | workaround a toolchain specifi bug for the e1.
* Fix wctype.c so that wchar can be enabled without ctype table-based functions.Manuel Novoa III2003-09-091-0/+58
|
* Add back in table-less ctype funcs for those interested in minimizingManuel Novoa III2003-09-082-5/+93
| | | | | | static build sizes and not needing wchar support. Add in a SUSv3 getopt as an option for those not needing gnu getopt. Again, mainly for the static linking crowd.
* oops. ftw would blow chunks if UCLIBC_HAS_LFS was disabled.Eric Andersen2003-09-061-4/+1
|
* fixup ftw and ftw64. Unfortunately, adding ftw64 doubles theEric Andersen2003-09-062-20/+51
| | | | size... :-(
* Fix the bugs I stupidly addedEric Andersen2003-09-063-2/+29
|
* Let people enable ftw, make glob an option, add a new "Big and Tall"Eric Andersen2003-09-061-1/+7
| | | | top level config menu.
* Add support for ftw and nftwEric Andersen2003-09-052-0/+660
|
* Some more buildroot-motivated fixes. Avoid installing some headers, asManuel Novoa III2003-09-032-2/+6
| | | | well as stub libintl, depending on configuration.
* Hack around bg_BG bug; grouping specified but no thousands separator.Manuel Novoa III2003-09-011-0/+24
| | | | | Also, disable the locale link_warnings for now, as they generate a lot of noise when using libstd++.
* Rework a few things.Manuel Novoa III2003-09-012-5/+52
|
* Create a typedef for the ctype bitmask table entries.Manuel Novoa III2003-08-282-34/+126
| | | | | | | | | Hack a fix for ctype support of 8-bit codeset locales. Note: toupper/tolower mappings do not handle the special cases for the tr_TR and az_AZ locales, since the wide versions currently handle them either. That will be addressed when I rewrite the data generation tools and the libc locale code.
* conditionally add wordexp, in this case ripped from glibc.Eric Andersen2003-08-243-1/+2287
| | | | I hate to add this stuff, but it is specified by SuSv3...
* Fix a few bugs in the new extended locale functions.Manuel Novoa III2003-08-249-154/+82
| | | | | | | | | Move stub gettext functions to a stub libintl to make switching in gnu gettext easier. Also add a few gnu-isms. Change to using hidden names with global weak aliases for the extended locale functions, as expected by libstd++. Slightly rework the locale data generation stuff to allow pregenerated locale data to be used with buildroot.
* _wchar_utf8sntowcs and _wchar_wcsntoutf8s now set errno if EILSEQ.Manuel Novoa III2003-08-181-0/+7
|
* Fix a cut-and-paste error. Collation should be working again.Manuel Novoa III2003-08-171-1/+1
|
* Add a new *scanf implementation, includeing the *wscanf functions.Manuel Novoa III2003-08-0115-844/+2667
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Should be standards compliant and with several optional features, including support for hexadecimal float notation, locale awareness, glibc-like locale-specific digit grouping with the `'' flag, and positional arg support. I tested it pretty well (finding several bugs in glibc's scanf in the process), but it is brand new so be aware. The *wprintf functions now support floating point output. Also, a couple of bugs were squashed. Finally, %a/%A conversions are now implemented. Implement the glibc xlocale interface for thread-specific locale support. Also add the various *_l(args, locale_t loc_arg) funcs. NOTE!!! setlocale() is NOT threadsafe! NOTE!!! The strto{floating point} conversion functions are now locale aware. The also now support hexadecimal floating point notation. Add the wcsto{floating point} conversion functions. Fix a bug in mktime() related to dst. Note that unlike glibc's mktime, uClibc's version always normalizes the struct tm before attempting to determine the correct dst setting if tm_isdst == -1 on entry. Add a stub version of the libintl functions. (untested) Fixed a known memory leak in setlocale() related to the collation data. Add lots of new config options (which Erik agreed to sort out :-), including finally exposing some of the stripped down stdio configs. Be careful with those though, as they haven't been tested in a long time. (temporary) GOTCHAs... The ctype functions are currently incorrect for 8-bit locales. They will be fixed shortly. The ctype functions are now table-based, resulting in larger staticly linked binaries. I'll be adding an option to use the old approach in the stub locale configuration.
* Yield to yet another glibc-ism and add __prognameEric Andersen2003-06-301-0/+3
|
* Optionally support the struct tm extension fields.Manuel Novoa III2003-06-172-12/+40
| | | | | | | Add a few misc functions mentioned in time.h. Revert davidm's change regarding using a define for the "/etc/TZ" path, as this is eventually meant to be a configurable extension and not unconditionally supported.
* uClibc 0.9.19 has a bug in globfree(). If the previous call toEric Andersen2003-04-291-2/+2
| | | | | | | | | | | glob(...,pglob) used the GLOB_DOOFFS flag to reserve the first pglob->gl_offs slots of pglob->gl_pathv, globfree(pglob) would attempt to free the objects pointed to by those slots. If those objects were not on the heap, the system would crash. The attached patch fixes this. Norm
* Patch from Marshall M. Midden:Eric Andersen2003-04-191-33/+39
| | | | | | It turns out that uClibc's syslog.c does not close sockets when doing retries and when it exits due to errors. This patch fixes it.
* Fixup some small issues that show up when large file support is disabledEric Andersen2003-02-241-0/+2
|
* Use a define for the path to /etc/TZDavid McCullough2003-02-171-1/+2
|
* Fixup handling of the .note.ABI-tag section so that it is ARM only,Eric Andersen2003-02-083-88/+1
| | | | | | and so it actually works as intended allowing binaries on ARM to be debugged. -Erik
* Fix scandir64 to not free the wrong pieces of memory (which couldEric Andersen2003-01-286-79/+86
| | | | | | | | and did cause segfaults) by adjusting the working scandir.c to the the 64 thing. Fix up potential for mismatches between the libc and kernel dirent structures, which could also cause ugly problems. -Erik