Corinna Vinschen
4abcdf2717
* fhandler_socket.cc (fhandler_socket::recv_internal): Always call
...
WSARecv on SOCK_STREAM sockets.
2009-09-29 08:46:29 +00:00
Jeff Johnston
c38ed7c697
2009-09-28 Michael Eager <eager@eagercon.com>
...
* configure.in: Add microblaze-*-*.
* configure: Add microblaze-*-* (not regenerated.)
* microblaze: NEW microblaze target directory.
* microblaze/configure.in: NEW.
* microblaze/configure: Generate.
* microblaze/Makefile.in: NEW.
* microblaze/{crt0.S, crt1.S, crt2.S, crt3.S, crt4.S, crtinit.S}: NEW.
* microblaze/{pgcrtinit.S, _program_clean.S, _program_init.S,
sbrk.c, sim-crtinit.S, sim-pgcrtinit.S, timer.c, _exception_handler.S,
_hw_exception_handler.S, _interrupt_handler.S, xil_malloc.c,
nnxil_printf.c, xil_sbrk.c: NEW.
* microblaze/xilinx.ld: NEW.
2009-09-28 16:43:57 +00:00
Jeff Johnston
6c249577fb
2009-09-28 Michael Eager <eager@eagercon.com>
...
* configure.host: Add microblaze.
* libc/include/machine/ieeefp.h [MICROBLAZE]: Define __IEEE_BIG_ENDIAN.
* libc/include/machine/setjmp.h [MICROBLAZE]: Define _JBLEN, _JBTYPE.
* libc/include/sys/config.h [MICROBLAZE]: Define _REENT_SMALL,
_UNIX98_THREAD_MUTEX_ATTRIBUTES.
* libc/include/sys/types.h: Treat XMK like rtems, define
PTHREAD_MUTEX_NORMAL, PTHREAD_MUTEX_ERRORCHECK, PTHREAD_MUTEX_RECURSIVE,
PTHREAD_MUTEX_DEFAULT, PTHREAD_STACK_MIN, define stuct pthread_attr_s.
* libc/machine/configure.in: Add microblaze.
* libc/machine/configure: Add microblaze (not regenerated).
* libc/machine/microblaze/configure.in: NEW.
* libc/machine/microblaze/configure: Generate.
* libc/machine/microblaze/Makefile.am: NEW.
* libc/machine/microblaze/Makefile.in: Generate.
* libc/machine/microblaze/{abort.c, strcmp.c, strcpy.c, strlen.c,
mallocr.c, longjmp.S, setjmp.S}: NEW.
* libc/stdlib/mallocr.c [MICROBLAZE]: Don't declare sbrk prototype,
mALLOc(): return malloc value.
2009-09-28 16:42:21 +00:00
Corinna Vinschen
587b75f7bd
* fhandler.h (class dev_console): Constify charset parameter of
...
str_to_con.
* fhandler_console.cc (dev_console::con_to_str): Simplify. Always
default to the current internal locale.
(dev_console::get_console_cp): Always use codepage 437 for alternate
charset.
(dev_console::str_to_con): Constify charset parameter.
(fhandler_console::write_normal): Always use codepage 437 for alternate
charset. Otherwise always default to the current internal locale.
Replace ASCII SO with ASCII CAN.
* strfuncs.cc: Tweka comments according to below changes.
(sys_cp_wcstombs): Constify charset parameter. Convert all wchar_t
values in the Unicode private use area U+F0xx to the singlebyte
counterpart. Drop special handling creating ASCII SO sequence from
U+DCxx value. Rearrange for performance. Replace ASCII SO with
ASCII CAN.
(sys_cp_mbstowcs): Constify charset parameter. Replace ASCII SO with
ASCII CAN. Drop special case for U+DCxx ASCII SO sequences. Always
create a replacement from the Unicode private use area U+F0xx for
invalid byte values in a multibyte sequence. Do the same for wchar_t
values from the U+F0xx range to make them roundtrip safe.
* wchar.h (sys_cp_wcstombs): Constify charset parameter.
(sys_cp_mbstowcs): Ditto.
2009-09-28 12:10:32 +00:00
Corinna Vinschen
d856640e1c
* cygheap.cc (cygheap_init): Default locale.charset to "UTF-8".
...
* dcrt0.cc (dll_crt0_1): Call setlocale (LC_CTYPE, "") here, just
before resetting application locale to "C".
* environ.cc (environ_init): Drop code setting locale here.
* syscalls.cc (check_codepage): Break out check for required codepage
from internal_setlocale.
(internal_setlocale): Just convert CWD and $PATH from old charset to
new charset and set internal charset.
(setlocale): Change accordingly. Don't require LC_ALL or LC_CTYPE to
store old locale value. Always call internal_setlocale if charset
changed due to locale environment changes.
2009-09-28 10:43:49 +00:00
Corinna Vinschen
a58d484bcf
* libc/locale/locale.c (lc_ctype_charset): Set to "UTF-8" on Cygwin.
...
(lc_message_charset): Ditto.
(loadlocale): Set charset of the "C" locale to "UTF-8" on Cygwin.
* libc/stdlib/mbtowc_r.c (__mbtowc): Default to __utf8_mbtowc on
Cygwin.
* libc/stdlib/wctomb_r.c (__wctomb): Default to __utf8_wctomb on
Cygwin.
2009-09-27 12:21:16 +00:00
Eric Blake
7677a6b206
* new-features.sgml (ov-new1.7-file): Mention fexecve, execvpe.
2009-09-26 21:01:59 +00:00
Eric Blake
15e9ecd14a
Add fexecve, execvpe.
...
* exec.cc (fexecve): New function.
* cygwin.din (execvpe, fexecve): Export new fexecve and existing
execvpe.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
* posix.sgml: Mention them.
2009-09-26 21:01:10 +00:00
Eric Blake
b14f894fd1
* libc/include/sys/unistd.h (execvpe, fexecve) [__CYGWIN__]:
...
Add declarations.
2009-09-26 20:59:54 +00:00
Eric Blake
52dba6a5c4
Fix some POSIX-compliance bugs in link, rename, mkdir.
...
* syscalls.cc (link): Delete obsolete comment. Reject directories
and missing source up front.
(rename): Use correct errno for trailing '.'. Detect empty
strings. Allow trailing slash to newpath iff oldpath is
directory.
* dir.cc (mkdir): Reject dangling symlink with trailing slash.
* fhandler_disk_file.cc (fhandler_disk_file::link): Reject
trailing slash.
* fhandler.cc (fhandler_base::link): Match Linux errno.
2009-09-26 15:51:53 +00:00
DJ Delorie
1e6459d3e5
merge from gcc
2009-09-26 00:01:16 +00:00
Eric Blake
65d436509b
* libc/include/sys/unistd.h (eaccess, euidaccess) [__CYGWIN__]:
...
Add declarations.
2009-09-25 23:57:09 +00:00
Eric Blake
76fe91b90b
* new-features.sgml (ov-new1.7-file): Mention eaccess, euidaccess,
...
canonicalize_file_name, and document change in access semantics.
2009-09-25 23:56:18 +00:00
Eric Blake
2bf78f0928
Provide euidaccess, canonicalize_file_name; fix fchmodat.
...
* syscalls.cc (fchmodat): lchmod is not yet implemented.
(euidaccess): New function.
* path.cc (realpath): Update comment.
(canonicalize_file_name): New function.
* include/cygwin/stdlib.h (canonicalize_file_name): Declare it.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
* cygwin.din: Export canonicalize_file_name, eaccess, euidaccess.
* posix.sgml: Mention them.
2009-09-25 23:55:00 +00:00
Nick Clifton
358d4e3cb0
* configure.ac: Pass any --cache-file=/dev/null option on to
...
subconfigures.
* configure: Regenerate.
2009-09-25 19:25:04 +00:00
DJ Delorie
0986f93365
merge from gcc
2009-09-25 19:02:00 +00:00
Corinna Vinschen
5ceb291210
* setup2.sgml (setup-locale-problems): Fix charset names of codepages
...
936 and 949.
2009-09-25 16:42:36 +00:00
Eric Blake
3dbe243afa
Fix faccessat(,0) and access() semantics.
...
* fhandler.h (fhandler_base::fhaccess): Add parameter.
* security.h (check_file_access, check_registry_access): Likewise.
* security.cc (check_file_access, check_registry_access)
(check_access): Implement new parameter.
* fhandler.cc (fhandler_base::fhaccess): Likewise.
(device_access_denied): Update caller.
* syscalls.cc (access, faccessat): Update callers.
* spawn.cc (find_exec, fixup): Likewise.
2009-09-25 13:44:45 +00:00
Eric Blake
5386cd8ecc
* setup2.sgml (setup-locale-problems): Document how to install
...
non-default charsets.
2009-09-25 12:27:46 +00:00
Cary Coutant
005012ce6b
include/
...
* dwarf2.h (DW_TAG_rvalue_reference_type, DW_TAG_template_alias):
New tags.
(DW_FORM_ref_sig8): New name for DW_FORM_sig8.
(DW_AT_main_subprogram, DW_AT_data_bit_offset, DW_AT_const_expr,
DW_AT_enum_class, DW_AT_linkage_name, DW_AT_GNU_guarded_by,
DW_AT_GNU_pt_guarded_by, DW_AT_GNU_guarded, DW_AT_GNU_pt_guarded,
DW_AT_GNU_locks_excluded, DW_AT_GNU_exclusive_locks_required,
DW_AT_GNU_shared_locks_required, DW_AT_GNU_odr_signature): New
attributes.
(DW_LANG_Python): New language.
binutils/
* dwarf.c (get_TAG_name): Add missing DWARF-3 and new DWARF-4 tags.
(get_FORM_name): Add new DWARF-4 forms.
(read_and_display_attr_value): Add DW_FORM_ref_sig8, DW_LANG_Python.
(get_AT_name): Add new DWARF-4 and GNU-specific attributes.
(process_debug_info): Add do_types parameter; change all callers.
Add support for .debug_types sections.
(display_debug_types): New function.
(debug_displays): Add .debug_types section.
* readelf.c (process_section_headers): Add .debug_types section.
(display_debug_section): Simplify call to streq.
2009-09-24 20:52:07 +00:00
Corinna Vinschen
599d462dfa
* posix_ipc.cc (mq_open): Avoid closing the same descriptor twice in
...
case of errors.
(sem_open): Ditto.
2009-09-24 09:25:35 +00:00
Corinna Vinschen
1c23aff7a3
* kernel32.cc (CreateMutexW): Use correct access mask.
...
(CreateSemaphoreW): Ditto.
2009-09-24 09:09:45 +00:00
Corinna Vinschen
c1754722ee
* libc/locale/locale.c: Drop Cygwin-specific windows.h include.
...
(loadlocale): Call __set_charset_from_codepage with 0 codepage.
2009-09-23 17:19:00 +00:00
Corinna Vinschen
8e3607fcee
* strfuncs.cc (__set_charset_from_codepage): Fetch current ANSI
...
codepage if cp is 0.
2009-09-23 17:13:55 +00:00
Corinna Vinschen
565d6ede3f
Fix typo.
2009-09-23 12:01:42 +00:00
Corinna Vinschen
e664429d77
* strfuncs.cc (sys_cp_wcstombs): Convert lone surrogate pair
...
second halves to unambiguous ASCII SO sequence. When converting
chars invalid in current codepage to ASCII SO sequence, make
sure to check for surrogate pair second half only if ct least
one wide characters is left. Decrement nwc if valid second half has
been converted.
(sys_cp_mbstowcs): Improve ASCII SO handling. Never break from loop
if invalid character has been found. Recognize ASCII SO sequence
representing originally invalid mulitbyte char converted into a
lone surrogate pair second half. Convert accordingly.
2009-09-23 11:31:00 +00:00
Nick Clifton
70ecec052a
* config.sub, config.guess: Update from upstream sources.
2009-09-23 09:51:31 +00:00
DJ Delorie
515575eaae
merge from gcc
2009-09-22 21:52:47 +00:00
Jeff Johnston
2ad8d17a16
2009-09-22 Ralf Corsépius <ralf.corsepius@rtems.org>
...
* libc/include/stdlib.h: Add posix_memalign.
2009-09-22 21:49:20 +00:00
Jeff Johnston
bdb08ed44f
2009-09-22 Ralf Corsépius <ralf.corsepius@rtems.org>
...
* configure.host (*-rtems*): Remove -DMISSING_SYSCALL_NAMES.
Add -DHAVE_BLKSIZE, -D_NO_WORDEXP -D_NO_POPEN.
2009-09-22 21:24:55 +00:00
Jeff Johnston
c3f3d59e43
2009-09-22 Ralf Corsépius <ralf.corsepius@rtems.org>
...
* configure.host (m32c): Move setting -DABORT_PROVIDED to second
"case $host".
2009-09-22 21:23:13 +00:00
Ralf Wildenhues
8980b9ad03
Error out if building separately but srcdir has build remnants.
...
/:
PR bootstrap/32272
* configure.ac: Error out if $srcdir isn't '.' but contains
host-${host_noncanonical}.
* configure: Regenerate.
2009-09-22 18:00:40 +00:00
Corinna Vinschen
5e8d7527af
* autoload.cc (WSARecv): Define.
...
* fhandler_socket.cc (fhandler_socket::recv_internal): Call WSARecv
instead of WSARecvFrom if no name parameter is given. Explain why.
2009-09-22 14:27:57 +00:00
Eric Blake
74a67d01a5
Make *at functions more like Linux.
...
* syscalls.cc (faccessat): Fix typo, reject bad flags.
(fchmodat, fchownat, fstatat, utimensat, linkat, unlinkat): Reject
bad flags.
2009-09-22 12:13:53 +00:00
Corinna Vinschen
abe6b5a3e2
* strfuncs.cc (sys_cp_mbstowcs): Reset shift state after handling
...
invalid multibyte sequence.
2009-09-22 09:44:32 +00:00
Corinna Vinschen
4401b147bb
* path.cc (symlink_worker): Rework error handling to generate Linux
...
compatible errno in case of trailing slash in newpath.
2009-09-22 09:24:30 +00:00
Eric Blake
29bca9bb0c
Match dup2 and fcntl error values to POSIX.
...
* dtable.h (OPEN_MAX_MAX): New macro.
* resource.cc (getrlimit) [RLIMIT_NOFILE]: Use it.
* dtable.cc (dtable::extend): Likewise.
* fcntl.cc (fcntl64): Obey POSIX rule with too-large F_DUPFD.
* syscalls.cc (dup2): Likewise.
2009-09-22 04:09:03 +00:00
Eric Blake
a7b24e14d7
* ChangeLog-2002: Fix typo.
...
* ChangeLog-2008: Likewise.
2009-09-22 02:49:15 +00:00
Alan Modra
35f452c3e2
o * ppc.h (ppc_cpu_t): Typedef to uint64_t.
2009-09-22 02:36:26 +00:00
Ralf Wildenhues
9d1fd371d1
Require c++ in stage1_languages with --enable-gold in combined bootstrap.
...
/:
* configure.ac: If bootstrapping a combined tree with
--enable-gold, require c++ in stage1_languages.
* configure: Regenerate.
2009-09-21 20:32:59 +00:00
Ralf Wildenhues
e1762cf3a4
toplevel configure: bootstrap target_libs of stage1_languages.
...
/:
* configure.ac: Also add target_libs of stage1_languages to
bootstrap_target_libs.
* configure: Regenerate.
2009-09-21 20:31:02 +00:00
Corinna Vinschen
ee42ccd3a2
* cygheap.h (cwdstuff::get_posix): Convert to const inline method just
...
returning pointer to posix path.
(cwdstuff::reset_posix): Convert to non-inline method taking a wchar_t
pointer.
* path.cc (cwdstuff::set): Revert change from 2009-05-13. Set posix
to valid incoming path again.
(cwdstuff::reset_posix): New implementation setting posix path from
incoming wchar_t path. Explain usage.
(cwdstuff::get_posix): Drop implementation.
(cwdstuff::get): Drop special case to handle empty posix path.
* syscalls.cc (internal_setlocale): Store old posix cwd as wide char
path. Restore posix cwd using new charset. Explain why.
2009-09-21 19:29:16 +00:00
Ralf Wildenhues
92763ad9ba
Diagnose --enable-build-with-cxx --enable-bootstrap --enable-languages w/o c++
...
/:
* configure.ac: Diagnose --enable-build-with-cxx bootstrap
with --enable-languages not containing c++.
* configure: Regenerate.
2009-09-21 19:25:05 +00:00
Jeff Johnston
07ad8d11ca
2009-09-21 Ken Werner <ken.werner@de.ibm.com>
...
* spu/getpagesize.c: Align getpagesize implementation to POSIX
2009-09-21 16:07:34 +00:00
Alan Modra
cd6dd861a3
include/elf/
...
* ppc.h (DT_PPC_TLSOPT): Define.
* ppc64.h (DT_PPC64_TLSOPT): Define.
bfd/
* elf32-ppc.c (TLS_GET_ADDR_GLINK_SIZE): Define.
(ADD_3_12_2, BEQLR, CMPWI_11_0, LWZ_11_3, LWZ_12_3): Define.
(MR_0_3, MR_3_0): Define.
(struct ppc_elf_link_hash_table): Add no_tls_get_addr_opt.
(ppc_elf_select_plt_layout): Save emit_stub_syms param earlier.
(ppc_elf_tls_setup): Add no_tls_get_addr_opt param and save to hash
table. Check for presense of __tls_get_addr_opt
(allocate_dynrelocs): Increase glink entry size for __tls_get_addr.
(ppc_elf_size_dynamic_sections): Add DT_PPC_TLS_OPT tag.
(write_glink_stub): Add param p.
(ppc_elf_relocate_section): Adjust write_glink_stub call.
(ppc_elf_finish_dynamic_symbol): Emit special glink call stub for
__tls_get_addr.
* elf32-ppc.h (ppc_elf_tls_setup): Update prototype.
* elf64-ppc.c (struct ppc_link_hash_table): Add no_tls_get_addr_opt.
(ppc64_elf_tls_setup): Add no_tls_get_addr_opt param and save to hash
table. Check for presense of __tls_get_addr_opt.
(ppc64_elf_size_dynamic_sections): Add DT_PPC64_TLS_OPT tag.
(LD_R11_0R3, LD_R12_0R3, MR_R0_R3, CMPDI_R11_0, ADD_R3_R12_R13,
BEQLR, MR_R3_R0, MFLR_R11, STD_R11_0R1, BCTRL, LD_R11_0R1,
LD_R2_0R1, MTLR_R11): Define.
(build_tls_get_addr_stub): New function.
(ppc_build_one_stub): Call it.
(ppc_size_one_stub): Add extra size for __tls_get_addr stub.
(ppc64_elf_relocate_section): Don't change nop to ld 2,40(1) for
__tls_get_addr plt call.
* elf64-ppc.h (ppc64_elf_tls_setup): Update prototype.
binutils/
* readelf.c (get_ppc_dynamic_type): Add TLSOPT.
(get_ppc64_dynamic_type): Likewise.
ld/
* emultempl/ppc32elf.em (no_tls_get_addr_opt): New var.
(ppc_before_allocation): Pass to ppc_elf_tls_setup.
(OPTION_NO_TLS_GET_ADDR_OPT): Define. Redefine other options in
terms of previous option.
(PARSE_AND_LIST_LONGOPTS, PARSE_AND_LIST_OPTIONS): Add
--no-tls-get-addr-optimize.
(PARSE_AND_LIST_ARGS_CASES): Handle it.
* emultempl/ppc64elf.em (no_tls_get_addr_opt): New var.
(ppc_before_allocation): Pass to ppc64_elf_tls_setup.
(OPTION_NO_TLS_GET_ADDR_OPT): Define.
(PARSE_AND_LIST_LONGOPTS, PARSE_AND_LIST_OPTIONS): Add
--no-tls-get-addr-optimize.
(PARSE_AND_LIST_ARGS_CASES): Handle it.
ld/testsuite/
* ld-powerpc/tlslib.s: Delete dot-symbol entry syms. Add
__tls_get_addr_opt.
* ld-powerpc/tlslib32.s: Add __tls_get_addr_opt.
* ld-powerpc/oldtlslib.s: New file, old-abi version of tlslib.s.
* ld-powerpc/powerpc.exp: Build old-abi library and use it in
two new link tests.
* ld-powerpc/tlsexe.d: Update for new __tls_get_addr stub.
* ld-powerpc/tlsexe.g, * ld-powerpc/tlsexe.r, *ld-powerpc/tlsexe32.d,
* ld-powerpc/tlsexe32.g, * ld-powerpc/tlsexe32.r,
* ld-powerpc/tlsexetoc.d, * ld-powerpc/tlsexetoc.g,
* ld-powerpc/tlsexetoc.r: Likewise.
2009-09-21 11:51:01 +00:00
Corinna Vinschen
8fd422fe4e
* new-features.sgml (ov-new1.7-file): Add new hardlink behaviour on
...
filesystems not supporting hardlinks.
* overview2.sgml (ov-hi-files): Change descripton accordingly.
2009-09-21 11:01:19 +00:00
Corinna Vinschen
6cabe044dd
* fhandler_disk_file.cc (fhandler_disk_file::link): Drop faking hardlink
...
creation on filesystems not supporting hardlinks.
2009-09-21 10:56:50 +00:00
Ben Elliston
991caa7310
gas/
...
* config/tc-ppc.c (md_show_usage): Document -mpcca2.
* doc/c-ppc.texi (PowerPC-Opts): Document -mppca2.
gas/testsuite/
* gas/ppc/a2.s: New.
* gas/ppc/a2.d: Likewise.
* gas/ppc/ppc.exp: Run the a2 dump test.
include/opcode/
* ppc.h (PPC_OPCODE_PPCA2): New.
opcodes/
* ppc-dis.c (ppc_opts): Add "ppca2" entry.
* ppc-opc.c (powerpc_opcodes): Add eratilx, eratsx, eratsx.,
eratre, wchkall, eratwe, ldawx., mdfcrx., mfdcr. mtdcrx., icswx,
icswx., mtdcr., dci, wclrone, wclrall, wclr, erativax, tlbsrx.,
ici mnemonics.
(ERAT_T): New operand.
(XWC_MASK): New mask.
(XOPL2): New macro.
(PPCA2): Define.
2009-09-21 10:29:07 +00:00
Christopher Faylor
92c4330f5b
* dcrt0.cc (dll_crt0_1): Add another hack to REALLY make sure that cxx_malloc
...
is always set to the cygwin version.
2009-09-21 02:32:06 +00:00
Christopher Faylor
adfbdcdb07
* external.cc (cygwin_internal): Add hack to always reset cxx_malloc to proper
...
value.
* lib/_cygwin_crt0_common.cc (_cygwin_crt0_common): Relocate wayward comment.
2009-09-21 02:19:31 +00:00