summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2009-07-15use -EB/-EL for all targetsMike Frysinger
These are common linker options rather than target specific ones, so they should be safe to use for all targets. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-14Fix ARM syscall argument loading.Joseph Myers
This patch is a uClibc equivalent of <http://sourceware.org/ml/libc-ports/2008-11/msg00006.html>, to compute all syscall arguments on ARM in temporary variables before loading them into register variables. The principle is as for that glibc patch; the problem I actually observed was a GCC internal compiler error building ld.so for Thumb-2. Signed-off-by: Joseph Myers <joseph@codesourcery.com>
2009-07-14sh: Fix up optimized SH-4 memcpy on big endian.Giuseppe Cavallaro
Signed-off-by: Hideo Saito <saito@densan.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> See Linux Kernel commit: http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=e08b954c9a140f2062649faec72514eb505f18c3 Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
2009-07-09syscall(): create a common version based on INLINE_SYSCALL_NCS()Mike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-09syscall: unify part 2: NCS varietyMike Frysinger
Declare common NCS (non-constant syscall) variants and convert the existing ports over to this. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-09MAKEALL: expand cross-compiler arch searchMike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-09sh: Change __HAVE_SHARED__ to __PIC__Peter Griffin
Generate PIC relocations when __PIC__ is defined rather than __HAVE_SHARED__ (like other architectures). Signed-off-by: Peter Griffin <pgriffin@mpc-data.co.uk> Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
2009-07-08ignore generated .i filesMike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-08drop missing {INLINE,INTERNAL}_SYSCALL fallback logicMike Frysinger
Ports missing INLINE_SYSCALL() support need to get fixed, so drop the cruft keeping them alive since it no longer works with the unification. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-08syscall: unify common syscall definesMike Frysinger
Unify all the common syscall defines in syscalls-common.h and scrub all the duplicated code from relevant ports. This should also make converting existing ports to INLINE_SYSCALL() much easier as they don't have to get lost in all the unrelated noise, as well as creating new ports. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-06sparc: Update syscalls.h to define INTERNAL_SYSCALLAustin Foxley
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2009-07-05MAKEALL: start a quick build test helper scriptMike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Avoid type-punned pointers that break strict-aliasingRon
Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Avoid warnings about shifting more bits than we haveRon
The test here is a constant expression and will compile out. For platforms that don't need the shift the code gets slightly smaller and simpler, for those that do the result is unchanged. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Don't shadow the chroot globalRon
Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Don't shadow the mask parameter with a local variable in the same functionRon
Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Don't shadow stat with a local variableRon
Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Don't shadow the err() function with a local varRon
gcc-4.4 barks about that. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Add a few missing includesRon
elf.h needs __BYTE_ORDER, and s_scalbn.c needs {LONG,INT}_MAX. shm.c complains about no prototypes for shm_{open,unlink} without its header. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Check #if feature test macros are defined where they may not beRon
Once again all of these reduce the noise from gcc-4.4. Replaces a few more (USE_TLS && HAVE___THREAD) with USE___THREAD while we need to mess with them for this anyhow. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Provide token prototypes for functions that are external but have no headerRon
This cuts down on a lot of noise from gcc-4.4 Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Make more utility functions staticRon
This keeps gcc-4.4 from nagging that they have no prototypes. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Add noreturn attributes to some functions that won't ever do soRon
usage() is also made static in answer to warnings about no prototype. In __pthread_manager_event() we also have to drop the return statement, else gcc will in turn complain about a non-returning function having one. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Move extern prototype out of function scopeRon
gcc-4.4 now barks about this, so appease it. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05Add some missing printf/scanf format attributesRon
The gcc-4.4 documentation still suggests that the compiler will automatically do format checking for the standard format function prototypes, but it is now also barking warnings suggesting that we add them for this lot too. So added. Signed-off-by: Ron Lee <ron@debian.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-05use -isystem with gcc pathsMike Frysinger
Use -isystem to include gcc header paths rather than -I as these are system paths, not uClibc specific paths. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-03i386: store errno value before using __set_errno()Ingo van Lil
The __syscall_error() function stores the errno value in the edx register before invoking the __set_errno() macro. When using the pthread library this macro calls thread_self() to determine the errno location, which might clobber the edx register. The errno value must be stored in a "real" variable so the compiler can take care of saving/restoring it if necessary. Signed-off-by: Ingo van Lil <inguin@gmx.de> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-03ignore generated unifdefMike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-03uClibc_arch_features: sync defines between portsMike Frysinger
Make sure each arch has the same complete list to make comparing between them easier. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-07-03Merge branch 'master' of git://uclibc.org/uClibcMike Frysinger
2009-07-03add testcases for shm_{open,unlink}Bernhard Reutner-Fischer
Reported-by: Mikael Lund Jepsen <mlj@iccc.dk> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2009-07-02sh: add cacheflush syscall wrapperCarmelo Amoroso
Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
2009-07-01Correct ARM memcpy comments.Joseph Myers
The comments on register usage in ARM memcpy had dest and src the wrong way round; this patch (originally from Mark Shinwell) corrects this and adds a note on the return value. Signed-off-by: Joseph Myers <joseph@codesourcery.com>
2009-06-30Fix Thumb-2 setjmp.Joseph Myers
Many Thumb-2 instructions cannot use sp or pc as operands, and the assembler now diagnoses these. setjmp had one such instruction, movs; this patch changes it to mov. Signed-off-by: Joseph Myers <joseph@codesourcery.com>
2009-06-30Fix Thumb-2 memcpy.Joseph Myers
When an IT block was changed from having two instructions to having one, the IT instruction at the start of the block was not updated, causing memcpy to fail to assemble for Thumb-2; this patch makes the obvious fix. Signed-off-by: Joseph Myers <joseph@codesourcery.com>
2009-06-28Add missing CLIBABI variables __aeabi_stdin, __aeabi_stdout, __aeabi_stderr.Joseph Myers
The ARM EABI has a document CLIBABI specifying various __aeabi_* functions and variables to be provided for the use of portable objects that can be linked with different EABI-conforming C libraries. __aeabi_stdin, __aeabi_stdout and __aeabi_stderr were missing in uClibc; this patch (originally from Nathan Froyd and for glibc) adds them. Signed-off-by: Joseph Myers <joseph@codesourcery.com>
2009-06-28locale: gen_wc8bit: try to find UTF8 locale automaticallyMike Frysinger
Rather than require everyone to have en_US.UTF-8 when we really need any UTF8 locale, do a scan for possible UTF8 locales if the default en_US does not exist. Hopefully this should make the utility "just work" for most people. Reported-by: Daniel Cordero <theappleman@gmail.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-06-28stop installing/screwing with linux-headersMike Frysinger
It is not uClibc's business to make sure the user's toolchain is sane and has proper kernel headers configured/installed. If they don't, then they need to fix their toolchain, we don't need to try and magically do it for them. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-06-28add gitignore for utilsMike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-06-28wchar: fix inverted parameters in error messageAndré Goddard Rosa
The error message should output "fromcode -> tocode" rather than "tocode -> fromcode". Seems to be a typo due to the order of the func called: iconv_t iconv_open(const char *tocode, const char *fromcode); Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-06-28libc.so: include all output formats in linker scriptSteve Bennett
Rather than ripping out the default output format from the linker, include the big/little endian alternatives for the people who link with bi-endian toolchains. URL: http://lists.uclibc.org/pipermail/uclibc/2009-June/042595.html Signed-off-by: Steve Bennett <steveb@workware.net.au> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-06-28utils: punt readelfMike Frysinger
This miniature version of readelf has never been terribly useful and has caused significantly more headaches in its maintenance, so punt it. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-06-02include errno.h unconditionallyBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2009-06-02add stub for shm_open() and shm_unlinkBernhard Reutner-Fischer
Untested and needs testsuite exercise added Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2009-06-01Blackfin: make sure all relocs are uppercaseMike Frysinger
This is to match changes in the toolchain. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-05-27waitid: linux ABI takes 5 args, not 4Mike Frysinger
The POSIX waitid() takes 4 args, but the Linux one takes 5 args, so make sure we stuff the 5th arg with a NULL. Otherwise garbage gets randomly passed up and considering this is a pointer, that's baaaad. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2009-05-27tweak .gitignoreBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2009-05-26Add working pipe implementation for sparcAustin Foxley
Also get rid of warning in sparc sigaction Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2009-05-21fix compilation of linuxthreads for sparc64Austin Foxley
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2009-05-20Add a sigaction implementation for sparcAustin Foxley
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>