Age | Commit message (Collapse) | Author |
|
Do it by following the trail of the existing commented code, which
implemented it by calling get_phys_pages() and get_avphys_pages().
This patch implements these two functions, which are also glibc
extensions.
Some program/libraries (e.g. libuv) assumes that sysconf(_SC_PHYS_PAGES)
works on linux and never check for -1, thus they report an insane amount
of memory.
Signed-off-by: Nicolas Cavallari <nicolas.cavallari@green-communications.fr>
|
|
Linuxthreads.new isn't really useful with the existence
of NPTL/TLS for well supported architectures. There is no
reason to use LT.new for ARM/MIPS or other architectures
supporting NPTL/TLS. It is not available for noMMU architectures
like Blackfin or FR-V. To simplify the live of the few uClibc-ng
developers, LT.new is removed and LT.old is renamed to LT.
LINUXTHREADS_OLD -> UCLIBC_HAS_LINUXTHREADS
|
|
portability on system with default shell on a different directory, like for instance on android.
Signed-off-by: Ubaldo Porcheddu <ubaldo@eja.it>
|
|
Saves 0.6k bss with default buffer size(256).
text data bss dec hex filename
- 1172 8 408 1588 634 libc/misc/utmp/utent.os
- 429 0 256 685 2ad libc/unistd/getpass.os
+ 1208 8 28 1244 4dc libc/misc/utmp/utent.os
+ 471 0 4 475 1db libc/unistd/getpass.os
================================================================
+78 -632
Signed-off-by: Leonid Lisovskiy <lly.dev@gmail.com>
|
|
Argp is an advanced support for parsing unix-style argument vectors.
In addition to the common getopt interface, it provides automatic
response
to `--help' and `--version' options and use of custom parser in
conjunction
with argp native option parser, among others.
Argp support is required by elfutils package and prelink.
In uClibc argp functionalities has been moved from C library to
libuargp.so
Further the libc.so linker script contains an AS_NEEDED entry so that
it doesn't need to link libuargp.so explicitely.
Disable argp test if feature disabled.
Signed-off-by: Salvatore Cro <salvatore.cro@st.com>
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Waldemar Brodkorb <wbx@uclibc-ng.org>
|
|
This reverts commit 6b6ede3d15f04fe825cfa9f697507457e3640344.
|
|
|
|
|
|
The GNU variant of getopt() previously had no way to turn off
getopt_long() support.
|
|
It was added in 6d6bd8ba78434ecb09395582b5f3e41febd4d4ee,
but it is unclear for me, why this is needed or if it is
required. I don't think we should depend on some gcc
optimization, which might change in the future.
Anyway, this breaks c6x toolchain building (ICE), so I remove it.
Testsuite run for supported architectures didn't add any
new errors.
|
|
Signed-off-by: Henning Heinold <heinold@inf.fu-berlin.de>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
regressions introduced in 1b3025b7352f5e432ffa1c7adc57085ac9092b77
"buildsys: switch libc to kbuild-style"
unistd: Handle !UCLIBC_HAS_GET{, SUB}OPT cases
libc/libc_so.a(getsubopt-susv3.os): In function getsubopt':
getsubopt-susv3.c:(.text+0x0): multiple definition of getsubopt'
libc/libc_so.a(getsubopt.os):getsubopt.c:(.text+0x0):
first defined here.
The solution is to filter out the correct files when
UCLIBC_HAS_GETOPT and UCLIBC_HAS_GETSUBOPT are not defined.
inet: Move INET_RPC_{DIR, OUT} before CSRC_ALL
libc/libc_so.a(rpc_thread.oS): In function __rpc_thread_svc_max_pollfd':
rpc_thread.c:(.text+0x148): undefined reference to svc_max_pollfd'
libc/libc_so.a(rpc_thread.oS): In function __rpc_thread_svc_pollfd':
rpc_thread.c:(.text+0x184): undefined reference to svc_pollfd'
The CSRC_ALL variable uses the INET_RPC_DIR variable which is
initialized later on. We fix this problem by moving the
INET_RCP_{DIR,OUT} definitions before we use them in CSRC_ALL
Signed-off-by: Markos Chandras <markos.chandras@imgtec.com>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
This drops __signed, __volatile, and __const. Only the latter was
used in the code base, and for uClibc, not consistently. Much of
the code used plain "const" which meant "__const" was useless.
Really, the point of this is to stay in sync with what glibc did.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
This matches a similar change made to glibc.
No functional changes here.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
the generic open, close, waitpid, read, write are good for NPTL too
no good reason to have the same sleep in both libc and libpthread (NPTL)
no good reason to add sigwaitinfo, sigtimedwait and sigwait to libpthread (NPTL)
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Even if glibc reuses the syscall (bloat), we can reuse the function.
Make sure, that we use it only if it is provided by the syscall
and the function is really around (UCLIBC_HAS_REALTIME disables it),
else we get into a loop.
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Change CANCELLATION_P macro and adapt usage.
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
getrlimit previously was only called for NPTL (why?), fix that to be
used everywhere.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
fixes bogus fgets error check
fixes bogus strlen() < 0 check
switches off buffering regardless of tcgetattr() success
prints newline even on error or if there was no '\n' on input
uses sizeof(buf) instead of PWD_BUFFER_SIZE
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Bug was introduced in revision a202cf6f.
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
|
|
text data bss dec hex filename
- 318 4 0 322 142 libc/pwd_grp/lckpwdf.o
+ 312 4 0 316 13c libc/pwd_grp/lckpwdf.o
- 166 0 1 167 a7 libc/stdlib/abort.o
+ 157 0 1 158 9e libc/stdlib/abort.o
- 42 0 0 42 2a libc/sysdeps/linux/common/pause.o
+ 27 0 0 27 1b libc/sysdeps/linux/common/pause.o
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
|
|
...or rather, it WILL BE code shrink when gcc become clever enough
to not emit a second, useless XORing of ebx:
31 db xor %ebx,%ebx
85 c0 test %eax,%eax
74 11 je 73 <__GI_sleep+0x73>
31 db xor %ebx,%ebx <=== ?!
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
|
|
__USE_EXTERN_INLINES was unused and had bit-rotted, had to fix it
when it didn't work as intended at first.
text data bss dec hex filename
- 168 0 0 168 a8 libc/unistd/sleep.o
+ 146 0 0 146 92 libc/unistd/sleep.o
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
|
|
text data bss dec hex filename
- 197 0 0 197 c5 libc/unistd/sleep.o
+ 168 0 0 168 a8 libc/unistd/sleep.o
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
|
|
It can be easily reconstructed, since it's obvious
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
|
|
Use less stack by using same "sigset_t set" object for new and saved
signal set, remove redundant clearing of set, and do not save/restore
errno around sigprocmask(SIG_SETMASK) - it never changes it.
While at it, improve comments and make code style consistent
across sleep.c file.
text data bss dec hex filename
- 242 0 0 242 f2 libc/unistd/sleep.o
+ 197 0 0 197 c5 libc/unistd/sleep.o
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
|
|
According to POSIX.1-2008 standard, the following syscalls shall be
cancellation points : waitid, sleep, fdatasync, ppoll.
Further, if generic syscall is not available and stubs are
configured, provide the stub implementation for function.
Signed-off-by: Salvatore Cro <salvatore.cro@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
perusing the config parser
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
This likes to break nommu systems.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
* Use getrlimit for ARG_MAX in sysconf on nptl.
* Define NCARGS directly instead of ARG_MAX
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
Conflicts:
libc/unistd/confstr.c
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
|
|
Conflicts:
libc/misc/utmp/utent.c
libc/sysdeps/linux/i386/bits/syscalls.h
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
|
|
the NPTL should probably print the version-string of the glibc it's
compatible with and not the uClibc version (check what mysql expects).
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|
|
Conflicts:
Makefile.in
extra/Configs/Config.in
libc/sysdeps/linux/common/bits/kernel-features.h
libc/sysdeps/linux/common/poll.c
libc/sysdeps/linux/common/sysdep.h
libc/sysdeps/linux/sh/sysdep.h
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
|
|
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
|