Commit Graph

13800 Commits

Author SHA1 Message Date
Corinna Vinschen 551a3d64c9 * cygcheck.cc (dump_sysinfo): Add Windows 8 recognition. Note as
unsupported.  Update products array.
2011-10-13 17:50:48 +00:00
Corinna Vinschen 76173acf28 * path.cc (find_fast_cwd_pointer): Allow 'push crit-sect-addr' instead
of 'mov edi, crit-sect-addr; push edi' and set rcall accordingly.
2011-10-13 16:47:32 +00:00
Corinna Vinschen 40187f9007 * path.cc (copy_cwd_str): Move up in file to be accessible from
class fcwd_access_t.
	(class fcwd_access_t): New class to consolidate and hide the details
	of the various FAST_CWD implementations.  Add implementation for
	Windows 8 Developer Preview.
	(fast_cwd_version): Make static private member of fcwd_access_t.
	(fast_cwd_ptr): Change base type to fcwd_access_t.
	(find_fast_cwd_pointer): Return fcwd_access_t**.
	(find_fast_cwd): Ditto.  Rip out all FAST_CWD implementations and use
	fcwd_access_t methods instead.
	(cwdstuff::override_win32_cwd): Ditto.
2011-10-13 15:32:10 +00:00
Corinna Vinschen 5de3a1c10f * fhandler_console.cc (fhandler_console::cursor_set): Disable forcing
y to the current winBottom position.  Explain why.
2011-10-12 14:19:20 +00:00
Christopher Faylor 4add6f8db1 * cygwin.din: Remove some _tc* exports. Add tcgetsid().
* dtable.cc (fh_alloc): Revert ill-advised setting of major/minor.  Use new
is_dev_tty to remember that this device was opened as /dev/tty.
* fhandler.cc (fhandler_base::fstat): Remove leftover debugging statement.
(fhandler_base::tcgetsid): New function.
* fhandler.h ((fhandler_base::tcgetsid): Declare new function.
(fhandler_base::is_dev_tty): Ditto.
(fhandler_termios::opened_as_dev_tty): Declare new field.
(fhandler_termios::is_dev_tty): Declare new function.
(fhandler_termios::tcgetsid): Ditto.
(fhandler_pty_common::use_archetype): Move here from subclass.
(fhandler_pty_slave::use_archetype): Move up.
(fhandler_pty_master::use_archetype): Ditto.
* fhandler_console.cc (fhandler_console::ioctl): Rename second argument from
`buf' to `arg' for consistency.  Call ioctl_termios for common fhandler_termios
ioctl handling.
* fhandler_tty.cc (fhandler_pty_slave::ioctl): Call ioctl_termios for common
fhandler_termios ioctl handling.
(fhandler_pty_master::ioctl): Ditto.
* fhandler_termios.cc (fhandler_termios::tcgetsid): Implement new function.
(fhandler_termios::ioctl_termios): Ditto.  Implements TIOCSCTTY handling.
* syscalls.cc (stat_worker): Set /dev/tty device info when appropriate.
* termios.cc (tcgetpgrp): Avoid extraneous "isatty" check.
(tcgetsid): Implement new function.
* include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR to 253.
* include/sys/termios.h (TIOCSCTTY): Define.
2011-10-11 23:20:38 +00:00
Yaakov Selkowitz 14b9008cca * utils.sgml (getconf): Expand documentation. 2011-10-11 21:53:57 +00:00
Christopher Faylor 1e5bcae135 * dtable.cc (fh_alloc): Don't parse /dev/tty if ctty is < 0. Reset major/minor
from the specific tty to those for /dev/tty.
2011-10-11 12:39:31 +00:00
Corinna Vinschen f13f2da4ee * libc/time/mktm_r.c: (__tzcalc_limits) Fix Julian day calculation.
* libc/time/mktime.c: (mktime) Fix tm_yday, tm_mday updating when
	timezone causes roll over.
2011-10-11 11:28:05 +00:00
Nick Clifton eefc33184a oops - fix typo in previous delta. 2011-10-11 09:29:56 +00:00
Nick Clifton fa5c739c6e oops - omitted from previous delta. 2011-10-11 07:38:33 +00:00
Christopher Faylor be96a30c43 * syscalls.cc (open): Add temporary kludge to avoid assigning the controlling
tty on open unless the open is for stdin/stdout/stderr.
* tty.cc (tty_list::connect): Set ENXIO when can't find a tty.
2011-10-10 22:01:06 +00:00
Corinna Vinschen 4c34aaba55 * fhandler.h (fhandler_process::closedir): Declare.
* fhandler_process.cc (fhandler_process::closedir): New function to
	avoid a SEGV in fhandler_proc::closedir.
2011-10-10 18:59:56 +00:00
Corinna Vinschen 378eaba88b * cygserver.sgml: Change -v to -V, same as in sources. 2011-10-10 15:52:48 +00:00
Corinna Vinschen 9e9bc3a4e4 * cygserver.cc (print_usage): Align output to utilities in utils
directory.
	(print_version): Ditto.
2011-10-10 15:48:54 +00:00
Corinna Vinschen f213601cda * ldd.cc (VERSION): Remove. 2011-10-10 15:34:52 +00:00
Christopher Faylor c4fc42535c * ldd.cc: Update copyright. 2011-10-10 15:04:00 +00:00
Corinna Vinschen 92b499acff * Align usage output, version output, as well as usage and version
option handling to use the same style throughout all Cygwin utils.
	Throughout use program_invocation_short_name to refer to current
	process name in Cygwin executables.
	* utils.sgml: Align documentation to above change.  Add missing
	sections for getconf, ldd, and setmetamode.
	* strace.cc (proc_child): Avoid compiler warning.
2011-10-10 14:57:48 +00:00
Alan Modra 4fc8a5c90a include/elf/
* ppc64.h (R_PPC64_TOCSAVE): Add.
bfd/
	* elf64-ppc.c (ppc64_elf_howto_table): Add R_PPC64_TOCSAVE entry.
	(struct ppc_link_hash_table): Add tocsave_htab.
	(struct tocsave_entry): New.
	(tocsave_htab_hash, tocsave_htab_eq, tocsave_find): New functions.
	(ppc64_elf_link_hash_table_create): Create tocsave_htab..
	(ppc64_elf_link_hash_table_free): ..and delete it.
	(build_plt_stub): Always put STD_R2_40R1 first.
	(ppc64_elf_size_stubs): Check for R_PPC64_TOCSAVE following reloc
	on plt call.  If present add prologue nop location to tocsave_htab.
	(ppc64_elf_relocate_section): Convert prologue nop to std.  Skip
	first insn of plt call stub when R_PPC64_TOCSAVE present.
2011-10-10 13:21:05 +00:00
Nick Clifton f9a3814899 * libc/sys/arm/crt0.S: Synchronise with libgloss version.
* libc/sys/arm/arm.h: Imported from libgloss.
2011-10-10 13:00:25 +00:00
Corinna Vinschen 9198ac4dc6 * locale.cc (usage): Restructure, rephrase, add new options. Drop
arguments, don't exit.
	(print_version): New function.
	(longopts): Add -f, -n, and -V options.  Reorder.
	(opts): Add -f, -n, and -V options.
	(main): Call GetSystemDefaultUILanguage for -s option.  Call
	GetUserDefaultUILanguage for -u option.  Add -f and -n options and
	call GetUserDefaultLCID and GetSystemDefaultLCID respectively.  Return
	0 after calling usage in -h case.  Add -V option and call print_version.
	Don't print full usage in default case, rather just a short help message
	similar to GNU tools.
	* utils.sgml (locale): Align to above changes.  Rephrase description.
2011-10-10 09:50:43 +00:00
Corinna Vinschen f818494c63 * cygcheck.cc (check_keys): Use UNICODE Win32 functions. 2011-10-10 09:42:00 +00:00
Christopher Faylor 336e8ee685 * fhandler_tty.cc (fhandler_pty_slave::open): Clarify debugging output.
(fhandler_pty_slave::open): Change ENOENT to ENXIO when can't open a tty.
2011-10-10 04:05:29 +00:00
Christopher Faylor 3d1dd0789e * fhandler.h (fhandler_console::tc_getpgid): New function.
* spawn.cc (spawn_guts): Add logic to put pure-windows processes "in the
background" when they are started that way.
2011-10-07 13:52:20 +00:00
Corinna Vinschen c53c656b1c * include/sys/cygwin.h (cygwin_getinfo_types): Define values
additionally as preprocessor symbols.
2011-10-07 13:49:17 +00:00
Nick Clifton fe81c303e0 * rx/crt0.S: Initialise the PID address register.
(__pid_base): Define weakly.
2011-10-07 10:09:22 +00:00
Corinna Vinschen 7bbfea993a Fix copyright. 2011-10-07 08:14:25 +00:00
Corinna Vinschen 852908e82d * fhandler_termios.cc (fhandler_termios::tcsetpgrp): Send __SIGSETPGRP
pseudo signal to process group instead of just calling
	init_console_handler.
	* sigproc.cc (wait_sig): Call init_console_handler here on __SIGSETPGRP
	signal.
	* sigproc.h (__SIGSETPGRP): Define.
2011-10-06 19:47:45 +00:00
Christian Franke efe716bb8e 2011-10-06 Christian Franke <franke@computer.org>
* include/cygwin/wait.h: Use new __wait_status_to_int()
	macro to access status value in W*() status checks.
	Fix status description.
	* include/sys/wait.h: Allow `int' and `union wait' as
	wait status parameter.  Change __wait_status_to_int()
	macro and wait () prototypes accordingly.  Add inline
	functions for C++.  Remove extra `;'.
2011-10-06 16:02:37 +00:00
Nick Clifton e402890df2 * readelf.c (get_machine_dlags): Add support for RX's PID mode.
* ld-scripts/phdrs.exp: Expect to fail for the RX.

	* elf32-rx.c: Add support for PID mode.
	(rx_elf_relocate_section): Add checks for unsafe PID relocations.
	Include addend in R_RX_SYM relocations.

	* config/rx-defs.h (rx_pid_register): New.
	(rx_gp_register): New.
	* config/rx-parse.y (rx_lex): Add support for %gpreg and %pidreg.
	(displacement): Add PID support.
	* config/tc-rx.c (rx_pid_mode): New.
	(rx_num_int_regs): New.
	(rx_pid_register): New.
	(rx_gp_register): New.
	(options): Add -mpid and -mint-register= options.
	(md_longopts): Likewise.
	(md_parse_option): Likewise.
	(md_show_usage): Likewise.
	(rx_pid_symbol): New.
	(rx_pidreg_symbol): New.
	(rx_gpreg_symbol): New.
	(md_begin): Support PID.
	(rx_validate_fix_sub): Support PID.
	(tc_gen_reloc): Support PID.
	* doc/c-rx.texi: Document PID support.

	* rx.h (E_FLAG_RX_PID): New.
2011-10-05 14:13:29 +00:00
Corinna Vinschen 8dfce03bfa * external.cc (create_winenv): Rename from sync_winenv. Take
environment pointer as parameter and return pointer to corresponding
	win32 environment block if != NULL.  Otherwise just sync as before.
	(cygwin_internal): Add CW_CVT_ENV_TO_WINENV case.
	* include/cygwin/version.h: Bump API minor number.
	* include/sys/cygwin.h (cygwin_getinfo_types): Add CW_CVT_ENV_TO_WINENV.
2011-10-05 12:27:37 +00:00
Corinna Vinschen a06c3bf336 * net.cc (socketpair): Bind first socket to loopback only as well. 2011-10-05 06:18:16 +00:00
Jeff Johnston 5be9bb15b2 2011-10-04 Greta Yorsh <Greta.Yorsh@arm.com>
* testsuite/newlib.string/memcpy-1.c: New test.
2011-10-04 18:43:14 +00:00
Nick Clifton de0ae33544 * libc/machine/arm/memcpy.S: Fix unaligned access copying. 2011-10-04 16:02:25 +00:00
Keith Marshall 35ddfc9e28 Rationalise structure layout; add dirent.d_type field. 2011-10-01 20:18:10 +00:00
Nick Clifton 341bf73d6d * libc/machine/arm/memcpy.S: New file. Contains a hand coded
memcpy function optimized for the cortex-a15.
	* libc/machine/arm/memcpy-stub.c: New file.
	* libc/machine/arm/Makefile.am (lib_a_SOURCES): Add memcpy-stub.c,
	memcpy.S.
	* libc/machine/arm/Makefile.in: Regenerate.
2011-09-29 13:28:50 +00:00
Nick Clifton 5b495afe51 * arm/crt0.s: Support 0 heap base response from HeapInfo syscall. 2011-09-29 11:23:29 +00:00
Nick Clifton 29deef8805 * arm/arm.h (HAVE_CALL_INDIRECT): Define.
* arm/crt0.S (indirect_call): New macro.  Encodes indirect
	function calls.  Does not use blx for pre-armv5 targets.
2011-09-29 11:06:49 +00:00
DJ Delorie 8a91ddb367 merge from gcc 2011-09-28 20:01:37 +00:00
DJ Delorie 6a534371fa merge from gcc 2011-09-27 00:01:35 +00:00
DJ Delorie 71c56d78b5 merge from gcc 2011-09-26 23:04:59 +00:00
Cary Coutant d77d04f542 include/ChangeLog
gcc PR lto/47247
	* plugin-api.h (enum ld_plugin_symbol_resolution): Add
	LDPR_PREVAILING_DEF_IRONLY_EXP.
	(enum ld_plugin_tag): Add LDPT_GET_SYMBOLS_V2.

gold/ChangeLog

	gcc PR lto/47247
	* plugin.cc (get_symbols_v2): New function.
	(Plugin::load): Add LDPT_GET_SYMBOLS_V2.
	(is_referenced_from_outside): New function.
	(Pluginobj::get_symbol_resolution_info): Add version parameter, return
	LDPR_PREVAILING_DEF_IRONLY_EXP when using new version.
	(get_symbols): Pass version parameter.
	(get_symbols_v2): New function.
	* plugin.h (Pluginobj::get_symbol_resolution_info): Add version
	parameter.
	* testsuite/plugin_test.c (get_symbols_v2): New static variable.
	(onload): Add LDPT_GET_SYMBOLS_V2.
	(all_symbols_read_hook): Use get_symbols_v2; check for
	LDPR_PREVAILING_DEF_IRONLY_EXP.
	* testsuite/plugin_test_3.sh: Update expected results.
2011-09-26 23:00:17 +00:00
DJ Delorie 9a2873437e merge from gcc 2011-09-23 22:21:28 +00:00
David S. Miller 7661a752ca Annotate sparc objects with cpu hardware capabilities used.
bfd/

	* elfxx-sparc.c (_bfd_sparc_elf_merge_private_bfd_data): New.
	* elfxx-sparc.h: Declare it.
	* elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Call it.
	* elf64-sparc.c (elf64_sparc_merge_private_bfd_data): Likewise.

binutils/

	* readelf.c (display_sparc_hwcaps): New.
	(display_sparc_gnu_attribute): New.
	(process_sparc_specific): New.
	(process_arch_specific): When EM_SPARC, EM_SPARC32PLUS,
	or EM_SPARCV9 invoke process_sparc_specific.

gas/

	* config/tc-sparc.c (hwcap_seen): New bitmask, defined when
	not TE_SOLARIS.
	(sparc_ip): When not TE_SOLARIS, accumulate hwcap bits from
	sparc_opcode->flags of instruction into hwcap_seen.
	(sparc_md_end): Create Tag_GNU_Sparc_HWCAPS attribute if
	hwcap_seen is non-zero and not TE_SOLARIS.

gas/testsuite/

	* gas/sparc/hpcvis3.s: Update for fixed fchksum16 mnemonic.
	* gas/sparc/hpcvis3.d: Likewise.

include/elf/

	* sparc.h (Tag_GNU_Sparc_HWCAPS): New object attribute.
	(ELF_SPARC_HWCAP_*): New HWCAPS bitmask values.

include/opcode/

	* sparc.h (struct sparc_opcode): Expand 'flags' to unsigned int.
	(F_MUL32, F_DIV32, F_FSMULD, F_V8PLUS, F_POPC, F_VIS, F_VIS2,
	F_ASI_BLK_INIT, F_FMAF, F_VIS3, F_HPC, F_RANDOM, F_TRANS,
	F_FJFMAU, F_IMA, F_ASI_CACHE_SPARING): New flag bits.

opcodes/

	* sparc-opc.c (sparc_opcodes): Annotate table with HWCAP flag
	bits.  Fix "fchksm16" mnemonic.
2011-09-21 20:49:15 +00:00
Christopher Faylor 36b6320736 * tty.cc (grantpt): Check for valid fd.
(unlockpt): Ditto.
2011-09-21 04:33:57 +00:00
H.J. Lu 7c14eb0589 Check if a symbol is hidden by linker script.
bfd/

2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/12975
	* bfd-in.h (bfd_elf_size_dynamic_sections): Remove pointer
	to struct bfd_elf_version_tree.

	* elflink.c (elf_info_failed): Remove verdefs.
	(_bfd_elf_export_symbol): Updated.
	_bfd_elf_link_assign_sym_version): Likewise.
	(bfd_elf_size_dynamic_sections): Remove pointer to struct
	bfd_elf_version_tree.  Updated.
	(bfd_elf_gc_mark_dynamic_ref_symbol): Check if a symbol is hidden
	by linker script.

	* linker.c (bfd_hide_sym_by_version): New.

	* bfd-in2.h: Regenerated.

include/

2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/12975
	* bfdlink.h (bfd_link_info): Add version_info.

ld/

2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/12975
	* ldlang.c (lang_elf_version_info): Removed.
	(lang_register_vers_node): Replace lang_elf_version_info with
	link_info.version_info.
	(lang_add_vers_depend): Likewise.
	* pe-dll.c (process_def_file_and_drectve): Likewise.
	* emultempl/solaris2.em (elf_solaris2_before_allocation): Likewise.

	* ldlang.h (lang_elf_version_info): Removed.

	* plugin.c  (is_visible_from_outside): Check if symbol is hidden
	by version script.

	* emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
	Remove lang_elf_version_info.

ld/testsuite/

2011-09-15  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/12975
	* ld-elf/pr12975.d: New.
	* ld-elf/pr12975.s: Likewise.
	* ld-elf/pr12975.t: Likewise.
2011-09-16 01:15:19 +00:00
Jon TURNEY 02a7f96ef7 * strace.cc (attach_process): Try to turn off DEBUG_ONLY_THIS_PROCESS
if Attaching to a process with the trace-children flag set.
	(handle_output_debug_string): Apparently we don't need to explicitly
	attach for debugging when a child process starts
	* Makefile.in (strace.exe): Link with ntdll
2011-09-15 16:49:51 +00:00
Jeff Johnston c9925bf497 2011-09-08 Jeff Johnston <jjohnstn@redhat.com>
* testsuite/lib/flags.exp: Add logic to add the
        srcdir include directory to compile flags.
2011-09-08 16:18:23 +00:00
Corinna Vinschen 35e8bb2b7e * net.cc (cygwin_getsockopt): Drop erroneous double conversion of error
code returned by SOL_SOCKET/SO_ERROR.  Fix error handling.
2011-09-02 09:52:08 +00:00
Corinna Vinschen d94522a76a * lc_msg.h: Regenerate. 2011-09-01 19:19:29 +00:00
Corinna Vinschen e2d88014ac * dlfcn.cc (gfpod_helper): Helper function to search DLL using
a given DLL name.  Change default search path to allow /usr/bin.
	(get_full_path_of_dll): Find DLLs even if the caller used a ".so"
	suffix or a "lib" prefix for the DLL.
2011-09-01 08:17:07 +00:00