OSDN Git Service

uclinux-h8/uClibc.git
16 years agoBlackfin FD-PIC patch 3/6.
Bernd Schmidt [Mon, 3 Dec 2007 22:54:16 +0000 (22:54 -0000)]
Blackfin FD-PIC patch 3/6.
Change _dl_find_hash to _dl_lookup_hash, as on the NPTL branch.
_dl_find_hash is now a wrapper function around it; unlike on the NPTL branch,
it retains the old interface so that not all callers need to be changed.

_dl_lookup_hash can optionally give its caller a pointer to the module where
the symbol was found.

Introduce ELF_RTYPE_CLASS_DLSYM for lookups from libdl.

Spelling fixes in the Blackfin port, since Alex Oliva's original version of
these patches used _dl_find_hash_mod as the name of the function rather than
_dl_lookup_hash.

16 years agoBlackfin FD-PIC patch 2/6.
Bernd Schmidt [Mon, 3 Dec 2007 22:46:53 +0000 (22:46 -0000)]
Blackfin FD-PIC patch 2/6.
Add the necessary changes in ld.so and libdl to deal with targets that
prepend an underscore to symbol names.

16 years agoBlackfin FD-PIC patch 1/6.
Bernd Schmidt [Mon, 3 Dec 2007 22:41:36 +0000 (22:41 -0000)]
Blackfin FD-PIC patch 1/6.
Add a new function _dl_free.  In _dl_malloc, ensure we always get back a full
page from mmap.
Reset _dl_malloc_function and _dl_free_function when libdl is initialized.

16 years agoSome versions of gcc consider inline merely a hint. AVR32 depends on the
Carmelo Amoroso [Mon, 3 Dec 2007 20:58:30 +0000 (20:58 -0000)]
Some versions of gcc consider inline merely a hint. AVR32 depends on the
system calls actually being inlined, so AVR32 needs to use
__always_inline instead of just inline. The attached patch changes this
for the system calls.

Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel.com>
16 years agorealpath: reduce stack usage from 3*PATH_MAX (12k) to 1*PATH_MAX (4k).
Denis Vlasenko [Mon, 3 Dec 2007 08:59:12 +0000 (08:59 -0000)]
realpath: reduce stack usage from 3*PATH_MAX (12k) to 1*PATH_MAX (4k).
reduction is achieved by direct use of user-supplied PATH_MAX sized
buffer for result (without intermediate copy) and changes
in copy_buf[] usage - now it is used for both "source" pathname
and link name (it works because they have to be less than PATH_MAX combined,
otherwise we return NULL).

16 years agoFix merging error: a macro was renamed.
Bernd Schmidt [Wed, 28 Nov 2007 18:03:45 +0000 (18:03 -0000)]
Fix merging error: a macro was renamed.

16 years agoBlackfin crt1.S fixes for building with -msep-data.
Bernd Schmidt [Fri, 23 Nov 2007 18:05:55 +0000 (18:05 -0000)]
Blackfin crt1.S fixes for building with -msep-data.

16 years agoAdd some necessary Makefile bits for UCLIBC_FORMAT_FLAT_SEP_DATA.
Bernd Schmidt [Fri, 23 Nov 2007 18:03:47 +0000 (18:03 -0000)]
Add some necessary Makefile bits for UCLIBC_FORMAT_FLAT_SEP_DATA.

16 years agoSome shared flat improvements.
Bernd Schmidt [Fri, 23 Nov 2007 18:02:12 +0000 (18:02 -0000)]
Some shared flat improvements.
Fix minor errors:
  - UCLIBC_SHARED_FLAT_ID instead of SHARED_FLAT_ID
  - use -Wl,-shared-lib-id properly
Use libc_so.a as the source for the shared libc, in order to be able to
use -mleaf-id-shared-library on the Blackfin.

16 years agoAdd necessary Makefile rules for the Blackfin.
Bernd Schmidt [Fri, 23 Nov 2007 17:57:32 +0000 (17:57 -0000)]
Add necessary Makefile rules for the Blackfin.

16 years agoA better atomic ops implementation for the Blackfin, relying on a feature
Bernd Schmidt [Fri, 23 Nov 2007 17:28:17 +0000 (17:28 -0000)]
A better atomic ops implementation for the Blackfin, relying on a feature
present in our recent kernels.

16 years agomcontext_t shouldn't have a version argument, and fix REG_B0 definition.
Bernd Schmidt [Fri, 23 Nov 2007 17:19:02 +0000 (17:19 -0000)]
mcontext_t shouldn't have a version argument, and fix REG_B0 definition.

16 years agoFrom Jie Zhang:
Bernd Schmidt [Fri, 23 Nov 2007 17:14:20 +0000 (17:14 -0000)]
From Jie Zhang:
__bswap_16 could not assume that it's zero extended when an unsigned short int is loaded into the data register.

16 years agoChange test for a define that got renamed a while ago.
Bernd Schmidt [Fri, 23 Nov 2007 17:09:54 +0000 (17:09 -0000)]
Change test for a define that got renamed a while ago.

16 years agoDisable tst-ftime_l test if Extended Locale Support
Carmelo Amoroso [Fri, 23 Nov 2007 13:23:25 +0000 (13:23 -0000)]
Disable tst-ftime_l test if Extended Locale Support
is not enabled, otherwise build will fail

Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
16 years agoIgnore entries of "-1" in rofixup; the linker sometimes has no choice but to
Bernd Schmidt [Thu, 22 Nov 2007 19:27:42 +0000 (19:27 -0000)]
Ignore entries of "-1" in rofixup; the linker sometimes has no choice but to
create these for deleted entries in .eh_frame.

16 years agoAdd Blackfin specific mmap implementation using sys_mmap2.
Bernd Schmidt [Thu, 22 Nov 2007 17:28:22 +0000 (17:28 -0000)]
Add Blackfin specific mmap implementation using sys_mmap2.

16 years agosys/procfs.h defines a typedef for floating point registers that references an
Bernd Schmidt [Thu, 22 Nov 2007 17:22:13 +0000 (17:22 -0000)]
sys/procfs.h defines a typedef for floating point registers that references an
undefined structure.  This typedef is used in linuxthreads.old-db, causing a
compilation failure.  Fixed by defining an empty structure for it - we don't
have fp regs anyway.

16 years agoCertain configure scripts test for presence of dlfcn.h. Don't install it
Bernd Schmidt [Thu, 22 Nov 2007 17:05:28 +0000 (17:05 -0000)]
Certain configure scripts test for presence of dlfcn.h.  Don't install it
if !HAVE_SHARED.

16 years agoAdd hidden symbols for a number of pthread functions, and use them to ensure
Bernd Schmidt [Thu, 22 Nov 2007 16:55:08 +0000 (16:55 -0000)]
Add hidden symbols for a number of pthread functions, and use them to ensure
that all entries in the __pthread_functions point to functions within
libpthread, not identically-named functions in libc.

16 years agoAdded optimized versions of strcpy() and strncpy() for CRIS/CRISv32.
Peter Kjellerstedt [Wed, 21 Nov 2007 12:34:41 +0000 (12:34 -0000)]
Added optimized versions of strcpy() and strncpy() for CRIS/CRISv32.

16 years agoARM SHMLBA = (4 * PAGE_SIZE). Currently in uclibc arm used shm.h from
Carmelo Amoroso [Tue, 20 Nov 2007 07:43:19 +0000 (07:43 -0000)]
ARM SHMLBA = (4 * PAGE_SIZE). Currently in uclibc arm used shm.h from
common directory where SHMLBA = __getpagesize()

This patch fixes the issue.

Khem Raj
MontaVista Software Inc.

16 years agoIf uClibc's ld.so encounters text relocations in a shared library - one
Carmelo Amoroso [Fri, 16 Nov 2007 14:32:35 +0000 (14:32 -0000)]
If uClibc's ld.so encounters text relocations in a shared library - one
containing an object built without -fpic/-fPIC - then:

* If __FORCE_SHAREABLE_TEXT_SEGMENTS__, then it gives an error "Can't
modify %s's text section. Use GCC option -fPIC for shared objects,
please.\n" and exits.

* Otherwise, it makes the library's pages writable and relocates it.

If it encounters text relocations in a position-independent executable -
one containing an object built without -fpie/-fPIE/-fpic/-fPIC - then:

* If __FORCE_SHAREABLE_TEXT_SEGMENTS__, it does nothing about making the
pages writable, leading to a crash.

* Otherwise, the loop to make the pages writable uses the same variable
ppnt as used in an outer loop, messing up that outer loop and also causing
a crash.

This patch fixes both cases, by giving an error if
__FORCE_SHAREABLE_TEXT_SEGMENTS__ and saving and restoring ppnt otherwise.
Tested in both cases on ARM EABI.

Joseph S. Myers
joseph@codesourcery.com

16 years agoAdded AVR32 support to uClibc. Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel...
Carmelo Amoroso [Fri, 16 Nov 2007 14:26:46 +0000 (14:26 -0000)]
Added AVR32 support to uClibc. Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel.com>

16 years agoCRIS/CRISv32 architecture specific memcpy, memmove and memset.
Ricard Wanderlof [Mon, 12 Nov 2007 12:08:31 +0000 (12:08 -0000)]
CRIS/CRISv32 architecture specific memcpy, memmove and memset.

16 years agoDo not return error when fprintf returns 0 in addmntent().
Khem Raj [Sat, 10 Nov 2007 06:42:45 +0000 (06:42 -0000)]
Do not return error when fprintf returns 0 in addmntent().
fprintf is considered failing if the return is less than 0

16 years agoFix build system to generate locale data instead of using pregenerated ones
Carmelo Amoroso [Fri, 9 Nov 2007 13:04:26 +0000 (13:04 -0000)]
Fix build system to generate locale data instead of using pregenerated ones

16 years agoDefine _dl_assert in libdl only if __DOASSERTS__ is defined. Thanks to Peter Mazinger
Carmelo Amoroso [Fri, 9 Nov 2007 09:17:35 +0000 (09:17 -0000)]
Define _dl_assert in libdl only if __DOASSERTS__ is defined. Thanks to Peter Mazinger

16 years ago- fix whitespace
Bernhard Reutner-Fischer [Wed, 7 Nov 2007 20:35:37 +0000 (20:35 -0000)]
- fix whitespace

16 years agoAdded support for GNU hash style into dynamic linker
Carmelo Amoroso [Wed, 7 Nov 2007 15:14:50 +0000 (15:14 -0000)]
Added support for GNU hash style into dynamic linker

16 years ago- fix order of link-flags
Bernhard Reutner-Fischer [Wed, 24 Oct 2007 22:29:30 +0000 (22:29 -0000)]
- fix order of link-flags
  On cygwin one has to pass
  make menuconfig HOST_LOADLIBES="-lcurses -lintl"
  otherwise just curses is linked in and some symbols that live in intl are
  unresolved. Closes #1554 and possibly a couple of other reports.

16 years agoPoll with zero timeout
Joakim Tjernlund [Tue, 23 Oct 2007 11:47:01 +0000 (11:47 -0000)]
Poll with zero timeout

Jean-Christian de Rivaz writes:
The attached patch solve an issue I faced while using the libdbus-glib
waiting for a D-Bus message or the end of a glib timer at the same time.
This specific case of use generate a poll call with a zero timeout. On
platformes with the glibc a zero timeout poll return immetiately even if
there is no file descriptor event. But on platformes with uClibc a zero
timeout poll block until a file descriptor event occurs.

16 years agoHandle STT_COMMON symbols too. Following binutils release
Joakim Tjernlund [Sun, 21 Oct 2007 15:36:17 +0000 (15:36 -0000)]
Handle STT_COMMON symbols too. Following binutils release
will set the type of common symbols to STT_COMMON
instead of STT_OBJECTS, so the dynamic linker needs
to handle this type os symbols too.
Same changes have been added to glibc (See: bugzilla #5104).
This patch ensures the uclibc will work with later bintuils.

Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
16 years ago- commentary typo fix
Bernhard Reutner-Fischer [Sat, 20 Oct 2007 18:17:18 +0000 (18:17 -0000)]
- commentary typo fix

16 years ago- move UCLIBC_EXTRA_LDFLAGS below pinning LDFLAGS
Bernhard Reutner-Fischer [Tue, 16 Oct 2007 11:51:51 +0000 (11:51 -0000)]
- move UCLIBC_EXTRA_LDFLAGS below pinning LDFLAGS

16 years ago- use the compiler-driver instead of the linker
Bernhard Reutner-Fischer [Sat, 13 Oct 2007 14:50:43 +0000 (14:50 -0000)]
- use the compiler-driver instead of the linker
- adjust setting flags accordingly to use (hardcoded, see below) -Wl,
  Potential improvements:
  *) --warn-unresolved-symbols should perhaps be used for all libs
  *) eventually rename LDFLAGS to CC_LDFLAGS
  *) probe for compiler driver's notion of flag to use for passing in
     linker flags (i.e. don't hardcode "-Wl,")

16 years ago- allow for passing in UCLIBC_EXTRA_LDFLAGS
Bernhard Reutner-Fischer [Sat, 13 Oct 2007 14:41:46 +0000 (14:41 -0000)]
- allow for passing in UCLIBC_EXTRA_LDFLAGS

16 years agoDo string comparisos as late as possible during symbol lookup.
Mike Frysinger [Mon, 8 Oct 2007 02:03:48 +0000 (02:03 -0000)]
Do string comparisos as late as possible during symbol lookup.

Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
16 years ago- Fix compilation for mips ABI64 with no LFS.
Bernhard Reutner-Fischer [Sun, 30 Sep 2007 19:30:40 +0000 (19:30 -0000)]
- Fix compilation for mips ABI64 with no LFS.

16 years ago- Fix compilation for mips ABI64 with no LFS.
Bernhard Reutner-Fischer [Sun, 30 Sep 2007 19:29:19 +0000 (19:29 -0000)]
- Fix compilation for mips ABI64 with no LFS.
  This wants a stub_enosys(readahead) line later on, like many, many others need..

16 years agoThis patch will fix a problem when the same host is defined with both IPv4 and
Mike Frysinger [Fri, 28 Sep 2007 21:17:53 +0000 (21:17 -0000)]
This patch will fix a problem when the same host is defined with both IPv4 and
IPv6 entries in /etc/hosts. Previous only the first of these host would work,
as uClibc would read the /etc/hosts file from top to bottom, failing if the
first hit did not match the IP type.

Now uClibc will continue reading, even if the first correct entry name, but wrong IP
type fails. Thus, allowing a second correct entry name with correct IP type
will result in a name resolve.

Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel.com>
16 years agodo not check the pointer before freeing it since free(NULL) works just fine
Mike Frysinger [Fri, 28 Sep 2007 20:42:24 +0000 (20:42 -0000)]
do not check the pointer before freeing it since free(NULL) works just fine

16 years agocleanup code style
Mike Frysinger [Fri, 28 Sep 2007 20:39:18 +0000 (20:39 -0000)]
cleanup code style

16 years agoMake sure that the DSO has an hash table into its elf, otherwise skip
Mike Frysinger [Fri, 28 Sep 2007 20:14:36 +0000 (20:14 -0000)]
Make sure that the DSO has an hash table into its elf, otherwise skip
the lookup over next DSO.

Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
16 years agoJie Zhang writes:
Mike Frysinger [Fri, 21 Sep 2007 19:49:04 +0000 (19:49 -0000)]
Jie Zhang writes:
GCC 4.3 will put fixed headers in a seperate include-fixed directory.
And I don't think that there are people who are still using the 'stupid'
GCC which cannot handle -iwithprefix, at least it works with gcc-3.3.x.

16 years agodrop LDFLAGS from OUTPUT_FORMAT until LD/LDFLAGS can be fixed in general
Mike Frysinger [Fri, 21 Sep 2007 08:19:27 +0000 (08:19 -0000)]
drop LDFLAGS from OUTPUT_FORMAT until LD/LDFLAGS can be fixed in general

16 years ago- spelling fix
Bernhard Reutner-Fischer [Thu, 20 Sep 2007 12:07:10 +0000 (12:07 -0000)]
- spelling fix

16 years agoFix author name and copyright notice in __uc_malloc.c
Denis Vlasenko [Wed, 19 Sep 2007 08:23:09 +0000 (08:23 -0000)]
Fix author name and copyright notice in __uc_malloc.c

16 years agofix assembler error. libc_hidden_data_def cannot work on COMMONs,
Denis Vlasenko [Wed, 19 Sep 2007 07:57:22 +0000 (07:57 -0000)]
fix assembler error. libc_hidden_data_def cannot work on COMMONs,
thus need to initialize stuff with 0 to force it into bss.
All hell can again break loose if future gcc will be smart enough
to ignore it.

16 years agoadd libc_hidden_xxxx for __uc_malloc
Denis Vlasenko [Sat, 15 Sep 2007 21:10:52 +0000 (21:10 -0000)]
add libc_hidden_xxxx for __uc_malloc

16 years agofrom Blue Swirl: fixup sparc a bit more
Mike Frysinger [Sat, 15 Sep 2007 20:42:37 +0000 (20:42 -0000)]
from Blue Swirl: fixup sparc a bit more

16 years agopull from Blackfin repo: optimized byteswap funcs!
Mike Frysinger [Sat, 15 Sep 2007 11:05:11 +0000 (11:05 -0000)]
pull from Blackfin repo: optimized byteswap funcs!

16 years agopull from Blackfin repo: cleanup string funcs
Mike Frysinger [Sat, 15 Sep 2007 11:04:21 +0000 (11:04 -0000)]
pull from Blackfin repo: cleanup string funcs

16 years agoforgot to add this with previous sparc commit ...
Mike Frysinger [Sat, 15 Sep 2007 11:04:08 +0000 (11:04 -0000)]
forgot to add this with previous sparc commit ...

16 years agouse gcc input constraints to avoid often duplicated reloads when making syscalls
Mike Frysinger [Sat, 15 Sep 2007 11:02:36 +0000 (11:02 -0000)]
use gcc input constraints to avoid often duplicated reloads when making syscalls

16 years agoif __NR__newselect and __NR_select are unavailable, fall back to __NR_pselect6
Mike Frysinger [Sat, 15 Sep 2007 10:57:09 +0000 (10:57 -0000)]
if __NR__newselect and __NR_select are unavailable, fall back to __NR_pselect6

16 years agoalso fix bug 1012 by moschny in 64bit version of readdir
Mike Frysinger [Sat, 15 Sep 2007 09:24:42 +0000 (09:24 -0000)]
also fix bug 1012 by moschny in 64bit version of readdir

16 years agobug 1310: drop hidden aliases to data since some arches crap with this due to copy...
Mike Frysinger [Sat, 15 Sep 2007 09:12:59 +0000 (09:12 -0000)]
bug 1310: drop hidden aliases to data since some arches crap with this due to copy relocs

16 years agonot sure how this obvious one liner got lost from glibc, but merge it
Mike Frysinger [Sat, 15 Sep 2007 08:33:08 +0000 (08:33 -0000)]
not sure how this obvious one liner got lost from glibc, but merge it

16 years agoadd one more testcase from Natanael Copa
Mike Frysinger [Sat, 15 Sep 2007 08:14:09 +0000 (08:14 -0000)]
add one more testcase from Natanael Copa

16 years agoswitch to a smaller/more robust implementation by Andrey Simonenko and as suggested...
Mike Frysinger [Sat, 15 Sep 2007 08:12:15 +0000 (08:12 -0000)]
switch to a smaller/more robust implementation by Andrey Simonenko and as suggested by Natanael Copa

harvested from: http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/92880

16 years agoadd more tests as suggested by Natanael Copa and as harvested from:
Mike Frysinger [Sat, 15 Sep 2007 08:11:30 +0000 (08:11 -0000)]
add more tests as suggested by Natanael Copa and as harvested from:
http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/92880

16 years agoBlue Swirl writes:
Mike Frysinger [Sat, 15 Sep 2007 07:50:58 +0000 (07:50 -0000)]
Blue Swirl writes:
I got the library to compile with the attached patches, though dynamic
loader crashes early.

In buildroot I changed the architecture name by hand from sparc to
sparc64, otherwise the compiler produced 32-bit files with V9 (64-bit)
instructions. This configuration is not supported by QEMU, so I aimed
for pure 64-bit. I think Sparc64 option needs to be added to
buildroot.

The _Qp_ ops seem to be required by the ABI. This and setjmp patches
are just hacks to get the compilation further. The _Qp_ ops can be
found in glibc, would it be OK to use those?

V9 assembler requires declarations for global register use.

The mem* functions in sparc32 directory did not work. They are
actually used only by the hybrid 32-bit + V9 CPU configuration.

16 years agosimplify binutils as-needed support and enable it all the time regardless of ssp
Mike Frysinger [Sat, 15 Sep 2007 07:42:01 +0000 (07:42 -0000)]
simplify binutils as-needed support and enable it all the time regardless of ssp

16 years agosetup OUTPUT_FORMAT() in linker script (helps with multilib)
Mike Frysinger [Sat, 15 Sep 2007 07:40:58 +0000 (07:40 -0000)]
setup OUTPUT_FORMAT() in linker script (helps with multilib)

16 years agoAtsushi Nemoto writes:
Mike Frysinger [Sat, 15 Sep 2007 07:25:54 +0000 (07:25 -0000)]
Atsushi Nemoto writes:
In MIPS syscall(2), .cpload was added to an the error path, but it was
not enough for ABIs other then O32.  Use SETUP_GP, SETUP_GP64 and
RESTORE_GP64 to handle all ABIs.  This patch fixes an error path of
MIPS pipe(2) too.

16 years agosync with glibc
Mike Frysinger [Sat, 15 Sep 2007 06:50:02 +0000 (06:50 -0000)]
sync with glibc

16 years agoactually update errors variable when a test fails
Mike Frysinger [Sat, 15 Sep 2007 03:58:20 +0000 (03:58 -0000)]
actually update errors variable when a test fails

16 years agoadd strerror_r symbol alias as some autotool based packages simply use AC_CHECK_LIB...
Mike Frysinger [Sat, 15 Sep 2007 00:52:56 +0000 (00:52 -0000)]
add strerror_r symbol alias as some autotool based packages simply use AC_CHECK_LIB() to see if a function exists rather than checking the headers

16 years agodrop __user hack for crappy kernel headers and document the __linux__ grease
Mike Frysinger [Sat, 15 Sep 2007 00:36:49 +0000 (00:36 -0000)]
drop __user hack for crappy kernel headers and document the __linux__ grease

16 years agofix from Kevin Day to make sure we use strchr() rather than index()
Mike Frysinger [Sat, 15 Sep 2007 00:26:11 +0000 (00:26 -0000)]
fix from Kevin Day to make sure we use strchr() rather than index()

16 years agosgetspent: add missing free/__uc_malloc calls
Denis Vlasenko [Wed, 1 Aug 2007 10:19:51 +0000 (10:19 -0000)]
sgetspent: add missing free/__uc_malloc calls
(spotted by Peter S. Mazinger <ps.m@gmx.net>)

16 years agomake regex_old.c, ruserpass.c use __uc_malloc,
Denis Vlasenko [Mon, 30 Jul 2007 17:02:06 +0000 (17:02 -0000)]
make regex_old.c, ruserpass.c use __uc_malloc,
replace "buf = malloc(BUFSIZ); if (!buf) abort();" by __uc_malloc
elsewhere.

With last 7 patches together uclibc has 3k of static data total
with fairly big .config and with 2k being used for 2 x BUFSIZ stdio buffer:
   text    data     bss     dec     hex filename
    114     132    2048    2294     8f6 _stdio.o (ex lib/libc.a)
total data 593
total bss  3062

16 years agomake getnetent.c, md5.c use __uc_malloc
Denis Vlasenko [Mon, 30 Jul 2007 16:55:05 +0000 (16:55 -0000)]
make getnetent.c, md5.c use __uc_malloc

16 years agomake utent.c, getpass.c use __uc_malloc
Denis Vlasenko [Mon, 30 Jul 2007 16:54:31 +0000 (16:54 -0000)]
make utent.c, getpass.c use __uc_malloc

16 years agomake pwd_grp.c use __uc_malloc
Denis Vlasenko [Mon, 30 Jul 2007 16:54:07 +0000 (16:54 -0000)]
make pwd_grp.c use __uc_malloc

16 years agopatch #3: make resolv.c use __uc_malloc
Denis Vlasenko [Mon, 30 Jul 2007 16:53:44 +0000 (16:53 -0000)]
patch #3: make resolv.c use __uc_malloc

16 years agoconvert des.c to use __uc_malloc (-70 kbytes of bss)
Denis Vlasenko [Mon, 30 Jul 2007 16:52:23 +0000 (16:52 -0000)]
convert des.c to use __uc_malloc (-70 kbytes of bss)

16 years agointroduce __uc_malloc, so that users can intercept libc internal OOM.
Denis Vlasenko [Mon, 30 Jul 2007 16:51:48 +0000 (16:51 -0000)]
introduce __uc_malloc, so that users can intercept libc internal OOM.

16 years agoRemove stray code alignment (.align 16 and .align 4 directives)
Denis Vlasenko [Sun, 29 Jul 2007 14:45:26 +0000 (14:45 -0000)]
Remove stray code alignment (.align 16 and .align 4 directives)
from i386 and x86_64.

16 years agoexecXp should go to next PATH dir on any error except ENOEXEC,
Denis Vlasenko [Wed, 18 Jul 2007 22:32:40 +0000 (22:32 -0000)]
execXp should go to next PATH dir on any error except ENOEXEC,
not just on ENOENT (in particular, on EPERM). At least glibc does so.
Fixing this.

16 years agoinclude/sys/mman.h says that msync exists only on MMU.
Denis Vlasenko [Wed, 18 Jul 2007 22:31:31 +0000 (22:31 -0000)]
include/sys/mman.h says that msync exists only on MMU.
Make msync.c agree on this.

16 years agodes.c: move 0.5k of static data on stack, they are used only temporarily
Denis Vlasenko [Wed, 18 Jul 2007 22:30:43 +0000 (22:30 -0000)]
des.c: move 0.5k of static data on stack, they are used only temporarily
by des_init.

16 years agoEnable all of the remaining baud rates. All of the other architectures have them...
"Steven J. Hill" [Wed, 18 Jul 2007 03:16:05 +0000 (03:16 -0000)]
Enable all of the remaining baud rates. All of the other architectures have them enabled, so let's go all the way. There was a quick discussion on IRC about making the max baud rate configurable. That requires a bunch of #ifdef salting throughout all of the 'termios.h' files for the pre-processor to chew on. I'm going to pass on that for now.

16 years agoApply patch as submitted by Blue Smurfy Swirly <blauwirbel@gmail.com> for Sparc32.
"Steven J. Hill" [Wed, 18 Jul 2007 03:08:36 +0000 (03:08 -0000)]
Apply patch as submitted by Blue Smurfy Swirly <blauwirbel@gmail.com> for Sparc32.

16 years agosyslog.h: allow prioritynames[]/facilitynames[] to be defined const
Denis Vlasenko [Sat, 14 Jul 2007 14:52:24 +0000 (14:52 -0000)]
syslog.h: allow prioritynames[]/facilitynames[] to be defined const
(selectable by #defining SYSLOG_NAMES_CONST)

16 years agoFix broken syscall() function since the original patch did not work.
"Steven J. Hill" [Thu, 12 Jul 2007 00:58:41 +0000 (00:58 -0000)]
Fix broken syscall() function since the original patch did not work.

17 years agotweak msync prototype to match header
Mike Frysinger [Fri, 29 Jun 2007 08:19:22 +0000 (08:19 -0000)]
tweak msync prototype to match header

17 years ago- make sure to define _LIBC in libc-symbols.h before including anything
Bernhard Reutner-Fischer [Sun, 24 Jun 2007 17:23:54 +0000 (17:23 -0000)]
- make sure to define _LIBC in libc-symbols.h before including anything
  else.
- internal_function is only used inside libc, so do not define it in
  uClibc_arch_features.h on i386 if we are outside of libc.

17 years agoas noted by psm, make sure we accumulate PICFLAG-y back into PICFLAG
Mike Frysinger [Fri, 22 Jun 2007 16:00:45 +0000 (16:00 -0000)]
as noted by psm, make sure we accumulate PICFLAG-y back into PICFLAG

17 years agopull from Blackfin repo: add -mid-shared-library for UCLIBC_FORMAT_SHARED_FLAT and...
Mike Frysinger [Fri, 22 Jun 2007 07:11:53 +0000 (07:11 -0000)]
pull from Blackfin repo: add -mid-shared-library for UCLIBC_FORMAT_SHARED_FLAT and -msep-data for UCLIBC_FORMAT_FLAT_SEP_DATA

17 years agoCarmelo AMOROSO <carmelo.amoroso@st.com> writes:
Joakim Tjernlund [Wed, 13 Jun 2007 16:23:59 +0000 (16:23 -0000)]
Carmelo AMOROSO <carmelo.amoroso@st.com> writes:
Hi All,
this patch fixes a mismatch in ucontext struct between uClibc and kernel.
In this way a signal handler installed by sigaction can access
to the whole machine state correctly.
This can be applied both to trunk and nptl branch

17 years agoCorrect return value. Pointed out by psm.
Joakim Tjernlund [Mon, 4 Jun 2007 22:16:54 +0000 (22:16 -0000)]
Correct return value. Pointed out by psm.

17 years agochange the auxvt code from being dependent on MMU to !LDSO as auxvt things are ELF...
Mike Frysinger [Fri, 1 Jun 2007 19:17:36 +0000 (19:17 -0000)]
change the auxvt code from being dependent on MMU to !LDSO as auxvt things are ELF-specific, not MMU-specific

17 years agoBernd Schmidt writes: make sure custom stacks work properly for no-mmu
Mike Frysinger [Thu, 31 May 2007 08:26:29 +0000 (08:26 -0000)]
Bernd Schmidt writes: make sure custom stacks work properly for no-mmu

17 years agoAtsushi Nemoto writes:
Mike Frysinger [Thu, 31 May 2007 08:22:35 +0000 (08:22 -0000)]
Atsushi Nemoto writes:
Current MIPS readahead(), posix_fadvise(), posix_fadvise64() do not
match with kernel on all ABIs.

On O32 ABI, a padding is needed before a long long argument.
On N32/N64, a long long argument should be passed via a single register.

17 years agoAtsushi Nemoto writes:
Mike Frysinger [Thu, 31 May 2007 08:21:38 +0000 (08:21 -0000)]
Atsushi Nemoto writes:
http://www.opengroup.org/onlinepubs/009695399/functions/posix_fadvise.html
states it returns error code instead of setting errno.

17 years agoJean-Christian de Rivaz writes:
Mike Frysinger [Fri, 25 May 2007 18:34:46 +0000 (18:34 -0000)]
Jean-Christian de Rivaz writes:
I actually suspect this code into the file uClibc/libc/sysdeps/linux/common/poll.c:
tval.tv_nsec = (timeout % 1000) *1000;  <==== make only usec!
From milisecond this really needs a * 1000000 to make nanosecond. Without this
a 1100 milisecond timeout is converted into a 1 seconde and 100 microsecond
timeout! This can explain the weird result of the test code.

17 years agoRemove the arch specific mmap impl. for Powerpc. The common one will do.
Joakim Tjernlund [Fri, 25 May 2007 18:06:02 +0000 (18:06 -0000)]
Remove the arch specific mmap impl. for Powerpc. The common one will do.

17 years agouse POSIX -eq rather than bash == #1360
Mike Frysinger [Thu, 24 May 2007 04:37:20 +0000 (04:37 -0000)]
use POSIX -eq rather than bash == #1360