Commit Graph

11459 Commits

Author SHA1 Message Date
Jeff Johnston 0d1c7d281c 2009-05-13 Ulrich Weigand <uweigand@de.ibm.com>
* spu/crtn.S: Add dummy to ensure nothing gets linked at address 0.
        * spu/crti.S: Remove nop.
2009-05-13 21:31:06 +00:00
Jeff Johnston 5900080d7d 2009-05-13 Paul Brook <paul@codesourcery.com>
* libc/machine/arm/setjmp.S: Don't bother saving IP.  Copy SP to
        IP before saving.  Likewise when restoring.
2009-05-13 18:31:55 +00:00
Jeff Johnston eba36c51fa 2009-05-13 Paul Brook <paul@codesourcery.com>
* libc/machine/arm/setjmp.S: Add ARMv6-M implementation.
2009-05-13 18:28:49 +00:00
Corinna Vinschen 40c66067fb * pathnames.sgml (pathnames-unusual): Talk about using UTF-8 in C
locale.
	* setup2.sgml (setup-locale-problems): Ditto.
2009-05-13 15:11:39 +00:00
Corinna Vinschen b6c6ea43f3 * cygheap.h (cwdstuff): Convert to class. Make posix and dir private.
(cwdstuff::get_posix): New method.
	(cwdstuff::reset_posix): New method.
	* dcrt0.cc (dll_crt0_1): Call setlocale rather than _setlocale_r.
	* environ.cc (environ_init): Ditto.  Prefer "C" locale over current
	codepage default locale.
	* path.cc (chdir): Use cwdstuff::get_posix method instead of accessing
	cwdstuff::posix directly.
	(cwdstuff::set): Defer creating posix path to first usage.
	(cwdstuff::get_posix): Create posix path if it's empty, and return it.
	(cwdstuff::get): Create posix path if it's empty.
	* strfuncs.cc (sys_cp_wcstombs): Use UTF-8 conversion in the "C"
	locale.
	(sys_cp_mbstowcs): Ditto.
	* syscalls.cc (gen_full_path_at): Fetch CWD posix path locked.
	(setlocale): Implement here.  Reset CWD posix path.
2009-05-13 15:00:06 +00:00
Corinna Vinschen 136033a852 * libc/locale/locale.c (setlocale): Don't build on Cygwin. 2009-05-13 14:54:11 +00:00
Alexandre Oliva c91ae28fd2 ChangeLog:
PR target/37137
* Makefile.def (flags_to_pass): Remove redundant and incomplete
STAGE1_CFLAGS, STAGE2_CFLAGS, STAGE3_CFLAGS, and STAGE4_CFLAGS.
Add FLAGS_FOR_TARGET and BUILD_CONFIG.
(bootstrap_stage): Remove bootstrap-debug custom stages.  Turn
stage_configureflags, stage_cflags and stage_libcflags into
explicit Makefile macros.
* Makefile.tpl (HOST_EXPORTS, EXTRA_HOST_FLAGS): Pass GCJ and
GFORTRAN.
(POSTSTAGE1_HOST_EXPORTS): Add XGCC_FLAGS_FOR_TARGET and TFLAGS to
CC.  Set CC_FOR_BUILD from CC.
(BASE_TARGET_EXPORTS, RAW_CXX_TARGET_EXPORTS,
NORMAL_TARGET_EXPORTS): Move SYSROOT_CFLAGS_FOR_TARGET and
DEBUG_PREFIX_CFLAGS_FOR_TARGET from CFLAGS and CXXFLAGS to
XGCC_FLAGS_FOR_TARGET.  Add it along with TFLAGS to CC, CXX, GCJ,
and GFORTRAN.
(TFLAGS, STAGE_CFLAGS, STAGE_TFLAGS, STAGE_CONFIGURE_FLAGS): New.
(_LIBCFLAGS): Renamed to _TFLAGS.
(do-compare-debug, do-compare3-debug): Drop.
(CC, GCC_FOR_TARGET, CXX_FOR_TARGET, RAW_CXX_FOR_TARGET,
GCJ_FOR_TARGET, GFORTRAN_FOR_TARGET): Remove FLAGS_FOR_TARGET.
(FLAGS_FOR_TARGET, SYSROOT_CFLAGS_FOR_TARGET,
DEBUG_PREFIX_CFLAGS_FOR_TARGET): Move down.
(XGCC_FLAGS_FOR_TARGET): New.
(BASE_FLAGS_TO_PASS): Pass STAGEid_CFLAGS, STAGEid_TFLAGS and TFLAGS.
(EXTRA_HOST_FLAGS): Pass GCJ and GFORTRAN.
(POSTSTAGE1_FLAGS_TO_PASS): Move SYSROOT_CFLAGS_FOR_TARGET and
DEBUG_PREFIX_CFLAGS_FOR_TARGET from CFLAGS, CXXFLAGS, LIBCFLAGS,
LIBCXXFLAGS to XGCC_FLAGS_FOR_TARGET.    Add it along with TFLAGS
to CC, CXX, GCJ, and GFORTRAN.  Pass XGCC_FLAGS_FOR_TARGET and
TFLAGS.
(BUILD_CONFIG): Include if requested.
(all): Set TFLAGS on bootstrap.
(configure-stageid-prefixmodule): Pass TFLAGS, adjust FLAGS.
(all-stageid-prefixmodule): Likewise.
(do-clean, distclean-stageid): Set TFLAGS.
(restrap): Fix whitespace.
* Makefile.in: Rebuilt.
config/ChangeLog:
* multi.m4: Save CXX, GFORTRAN and GCJ in config.status.
* mt-gnu (CXXFLAGS_FOR_TARGET): Adjust.
* bootstrap-O1.mk: New.
* bootstrap-O3.mk: New.
* bootstrap-debug.mk: New.
2009-05-12 18:16:01 +00:00
Jeff Johnston ca3a040abf 2009-05-11 Craig Howland <howland@LGSInnovations.com>
* libm/machine/i386/f_llrint.c: Remove llrint() definition.
        * libm/machine/i386/f_llrintf.c: Remove llrintf() definition.
2009-05-11 21:58:05 +00:00
Corinna Vinschen 46777e0a3d * Makefile.in: Link ps.exe agains ntdll.dll.
* ps.cc (main): Enable SE_DEBUG_NAME privilege if Windows processes
	have to be enumerated.  Workaround EnumProcessModules problem when
	running under WOW64 and use NtQueryInformationProcess to fetch
	process image name.
2009-05-11 14:01:17 +00:00
Christopher Faylor 5aaaadc0e5 * cygwin/version.h (CYGWIN_VERSION_CYGWIN_CONV): New define. 2009-05-09 20:16:06 +00:00
Corinna Vinschen 9b98d6a8fb * dtable.cc (dtable::init_std_file_from_handle): Add workaround for
Windows 7 64 bit issue.  Add lengthy comment to explain what happens.
	* wincap.h (wincaps::has_console_handle_problem): New element.
	* wincap.cc: Implement above element throughout.
	(wincap_7): New wincaps structure for NT 6.1 kernels.
	(wincapc::init): Set has_console_handle_problem to false for 32 bit
	systems.

	Fix broken older ChangeLog entry.
2009-05-09 15:56:37 +00:00
Corinna Vinschen a22af4a956 * sec_auth.cc (str2uni_cat): Move from here...
* path.cc (str2uni_cat): ...to here.  Simplify.  Make static inline.
	(get_nt_native_path): Use RtlAppendUnicodeToString rather than
	str2uni_cat for constant strings for speed.
	* security.h (str2uni_cat): Drop declaration.
2009-05-09 15:08:16 +00:00
Corinna Vinschen 4dff3fed7d * strfuncs.cc (sys_cp_wcstombs): save and restore previous errno value.
(sys_cp_mbstowcs): Ditto.
2009-05-08 20:28:20 +00:00
Corinna Vinschen 0e6edb13c6 * strfuncs.cc (sys_cp_wcstombs): Set errno to 0 before converting
wide char to SO/UTF-8 sequence.
2009-05-08 19:38:33 +00:00
Corinna Vinschen 415867c378 * include/sys/select.h: Guard definitions with __USE_W32_SOCKETS as
the accompanying fd_set definitions in newlib's sys/types.h.
2009-05-08 10:54:58 +00:00
Nick Clifton 5796080933 * MAINTAINERS: Add myself as a maintainer for the MN10300 and to
the write-after-approval list.
2009-05-08 10:00:25 +00:00
Nick Clifton 797c4b998f * mn10300/sim.ld: Add missing section names such as .bss.*
.text.*, etc.  General tidy up.
2009-05-08 09:59:56 +00:00
Jeff Johnston debb2e3e77 2009-05-07 Ken Werner <ken.werner@de.ibm.com>
* spu/configure.in: Fix multilib support.
        * spu/configure: Regenerate.
        * spu/Makefile.in: Add CFLAGS_FOR_TARGET.
2009-05-07 18:07:35 +00:00
Christopher Faylor 6f5b891b7b * fhandler_console.cc (fhandler_console::ioctl): Properly treat TIOCLINUX
argument as a char.
* fhandler_tty.cc (fhandler_tty_slave::ioctl): Use coercion to properly set
char value.
2009-05-06 17:16:33 +00:00
Corinna Vinschen 967c052689 * Move ChangeLog entry. 2009-05-06 12:08:07 +00:00
Corinna Vinschen eed691a929 * libc/minires.c (scanline): Fix type in calls to ctype functions
to stay in unsigned char range for char values >= 0x80.
	* regex/regcomp.c: Ditto, throughout.
	* regex/regex2.h (ISWORD): Ditto.
2009-05-06 12:03:34 +00:00
Corinna Vinschen e1de7bfabd * faq-setup.xml: Fix entry explaing how the homedir is evaluated
according to recent change.
2009-05-06 12:02:51 +00:00
Corinna Vinschen 05e6f7b2b9 * mkpasswd.c (current_user): Don't use HOMEDRIVE/HOMEPATH to generate
user's homedir.

	* mkgroup.c: Accommodate ctype changes.
	* mkpasswd.c: Ditto.
	* setfacl.c: Ditto.
	* ssp.c: Ditto.
2009-05-06 11:54:24 +00:00
Corinna Vinschen 764d88e4a7 * cygheap.cc (cygheap_init): Set umask to a sane default.
* uinfo.cc (cygheap_user::ontherange): Don't use HOMEDRIVE/HOMEPATH
	to set HOME.  Default to /home/USERNAME.
2009-05-06 11:52:20 +00:00
Christopher Faylor 3227665e19 * cygcheck.cc (find_app_on_path): Avoid using NULL pointer if find_on_path
doesn't find the app on the path.
2009-05-04 18:51:08 +00:00
Corinna Vinschen 143cb0bed5 * cygcheck.cc (usage): Fix option order and print. 2009-05-04 10:15:48 +00:00
Corinna Vinschen 9d86c13dbb * security.cc (set_file_sd): Drop using FILE_OPEN_FOR_RECOVERY flag in
call to NtOpenFile.
	* exceptions.cc (open_stackdumpfile): Ditto in call to NtCreateFile.
	* fhandler.cc (fhandler_base::open): Ditto.  Simplify setting
	create_options.

	* mount.cc (fs_info::update): Recognize offline storage.
	(fillout_mntent): Report UDF and offline storage.
	* mount.h (class fs_info): Add is_csc_cache status flag.
2009-05-04 09:16:42 +00:00
Christopher Faylor 56a4d31a7f * fhandler_console.cc (fhandler_console::write_console): Eliminate unneeded
debugging output.
(fhandler_console::write_normal): Eliminate unneeded __seterrno.
2009-05-04 04:43:50 +00:00
Christopher Faylor b7a1552440 * libc/minires.c (scanline): Accommodate ctype changes which disallow use of an
unadorned char argument to is* macros.
* regex/regcomp.c: Ditto, throughout.
* regex/regex2.h (ISWORD): Ditto.
2009-05-04 04:30:37 +00:00
Christopher Faylor b65ec404a7 * fhandler.h (fhandler_console::MAX_WRITE_CHARS): Declare.
(fhandler_console::write_replacement_char): Declare as inline.
(fhandler_console::write_console): Declare new function.
* fhandler_console.cc (fhandler_console::MAX_WRITE_CHARS): Define.
(handler_console::write_console): Define.
(fhandler_console::write_replacement_char): Define as inline.
(fhandler_console::write_normal): Use write_console when writing buffers of
unknown length.
2009-05-04 03:51:16 +00:00
Chris Sutcliffe 1f5ea7a0db 2009-05-01 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* include/shellapi.h (SHIL_LARGE, SHIL_SMALL, SHIL_EXTRALARGE,
        SHIL_SYSSMALL, SHIL_JUMBO, SHIL_LAST SHIL_JUMBO, SHGetImageList): Define.
        * lib/shell32.def (SHGetImageList): Define.
2009-05-02 01:46:36 +00:00
Anthony Green 2585eb1832 Add self to MAINTAINERS file. Tweak moxie stack position. 2009-05-01 02:53:25 +00:00
Eric Blake 82b77480f7 Allow gcc warning for toupper even with extended charsets.
* libc/include/ctype.h (toupper, tolower)
[_MB_EXTENDED_CHARSETS_ISO]: Allow gcc warning when called with
'char' even when we must call the function for correct behavior.
[!_MB_EXTENDED_CHARSETS_ISO]: Fix regression in result type.
2009-04-30 22:53:00 +00:00
DJ Delorie 47b09662ee * mep.h (EF_MEP_COP_*): New.
(EF_MEP_ALL_FLAGS): Add them.
2009-04-30 18:49:37 +00:00
Nick Clifton de72e93ad9 include/elf
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * common.h (STT_GNU_IFUNC): Define.

elfcpp
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * (enum STT): Add STT_GNU_IFUNC.

gas
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * config/obj-elf.c (obj_elf_type): Add support for a
        gnu_indirect_function type.
        * config/tc-i386.c (tc_i386_fix_adjustable): Do not adjust fixups
        against indirect function symbols.
        * doc/as.texinfo (.type): Document the support for the
        gnu_indirect_function symbol type.
        * NEWS: Mention the new feature.

gas/testsuite
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * gas/elf/elf.exp: Extend type test to include an ifunc symbol.
        Provide an alternative test for targets which do not support ifunc
        symbols.
        (type.s): Add entry for an ifunc symbol.
        (type.e): Add ifunc entry to expected symbol dump.
        (section2.e-armelf): Add  entry for ifunc symbol.
        (type-noifunc.s): New file.
        (type-noifunc.e): New file.

bfd/
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * elf-bfd.h (struct bfd_elf_section_data): Add indirect_relocs
        section pointer.
        (struct elf_obj_data): Add has_ifunc_symbols boolean.
        * elf.c (swap_out_syms): Convert BSF_GNU_INDIRECT_FUNCTION flags
        into a STT_GNU_IFUNC symbol type.
        (_bfd_elf_is_function_type): Accept STT_GNU_IFUNC as a function
        type.
        (_bfd_elf_set_osabi): Set the osasbi field to ELFOSABI_LINUX if
        the binary contains ifunc symbols.
        * elfcode.h (elf_slurp_symbol_table): Translate the STT_GNU_IFUNC
        symbol type into a BSF_GNU_INDIRECT_FUNCTION flag.
        * elf32-i386.c (is_indirect_function): New function.
        (elf_i386_check_relocs): Create an ifunc output section.
        (allocate_dynrelocs): Create dynamic relocs in the ifunc output
        section if necessary.
        (elf_i386_relocate_section): Emit a reloc against an ifunc symbol
        if necessary.
        (elf_i386_add_symbol_hook): New function. Set the
        has_ifunc_symbols field of the elf_obj_data structure if an ifunc
        symbol is encountered.
        (elf_backend_post_process_headers): Define.
        (elf_backend_add_symbol_hook): Define.
        (elf_i386_post_process_headers): Rename to
        elf_i388_fbsd_post_process_headers.
        * elf64-x86_64.c (IS_X86_64_PCREL_TYPE): New macro.
        (is_indirect_function): New function.
        (elf64_x86_64_check_relocs): Create an ifunc output section.
        (allocate_dynrelocs): Create dynamic relocs in the ifunc output
        section if necessary.
        (elf64_x86_64_relocate_section): Emit a reloc against an ifunc
        symbol if necessary.
        (elf_i386_add_symbol_hook): Set the has_ifunc_symbols field of the
        elf_obj_data structure if an ifunc symbol is encountered.
        (elf_backend_post_process_headers): Define.
        * elflink.c (_bfd_elf_adjust_dynamic_symbol): Always create a PLT
        if we have ifunc symbols to handle.
        (get_ifunc_reloc_section_name): New function.  Computes the name
        for an ifunc section.
        (_bfd_elf_make_ifunc_reloc_section): New function.  Creates a
        section to hold ifunc relocs.
        * syms.c (BSF_GNU_INDIRECT_FUNCTION): Define.
        (bfd_print_symbol_vandf): Handle ifunc symbols.
        (bfd_decode_symclass): Likewise.
        * bfd-in2.h: Regenerate.

binutils
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * readelf.c (dump_relocations): Display a relocation against an
        ifunc symbol as if it were a function invocation.
        (get_symbol_type): Handle STT_GNU_IFUNC.

ld
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * NEWS: Mention support for IFUNC symbols.

ld/testsuite
2009-04-30  Nick Clifton  <nickc@redhat.com>

        * ld-ifunc: New directory.
        * ld-ifunc/ifunc.exp: New file: Run the IFUNC tests.
        * ld-ifunc/prog.c: New file.
        * ld-ifunc/lib.c: New file.
2009-04-30 15:47:11 +00:00
Christopher Faylor a8fdf91d85 * include/cygwin/socket.h: Define SOL_IPV6. 2009-04-27 04:31:22 +00:00
Eric Botcazou 2addcd0830 * Makefile.tpl (POSTSTAGE1_HOST_EXPORTS): Add GNATBIND.
(POSTSTAGE1_FLAGS_TO_PASS): Pick up exported value for GNATBIND.
	* Makefile.in: Regenerate.
2009-04-25 12:25:01 +00:00
Jeff Johnston bcde129400 2009-04-24 Jeff johnston <jjohnstn@redhat.com>
* libc/stdio/fgetc.c: Make sure sfp lock is acquired before the
        file lock and released before the file lock to avoid a deadlock
        scenario.
        * libc/stdio/fgets.c: Ditto.
        * libc/stdio/fgetwc.c: Ditto.
        * libc/stdio/fgetws.c: Ditto.
        * libc/stdio/fread.c: Ditto.
        * libc/stdio/fseek.c: Ditto.
        * libc/stdio/getc.c: Ditto.
        * libc/stdio/getdelim.c: Ditto.
        * libc/stdio/gets.c: Ditto.
2009-04-24 22:52:52 +00:00
Jeff Johnston 35f31b6a98 2009-04-24 Jeff johnston <jjohnstn@redhat.com>
* configure.in: Add configuration test for long double equals dbl
        and set flag _LDBL_EQ_DBL if true.
        * configure: Regenerated.
        * newlib.hin: Add _LDBL_EQ_DBL flag.
        * libc/include/math.h: Use _LDBL_EQ_DBL flag instead of
        _HAVE_LDBL_MATH.
        * libc/include/stdlib.h: Use _LDBL_EQ_DBL flag instead of
        _HAVE_LDBL_STDLIB.
        * libc/common/local.h: Remove _LDBL_EQ_DBL flag setting.
        * libc/stdlib/local.h: Ditto.
2009-04-24 22:49:55 +00:00
Jeff Johnston de19487224 2009-04-24 Joseph Myers <joseph@codesourcery.com>
* libc/include/stdint.h (UINTPTR_MAX): Define to __UINTPTR_MAX__
	if __UINTPTR_MAX__ defined.
2009-04-24 21:55:07 +00:00
Cary Coutant 546065b39f include/elf/
* dwarf2.h (DW_LNE_set_discriminator): New enum value.

binutils/

	* dwarf.c (process_extended_line_op): Add DW_LNE_set_discriminator.
	Add missing newlines to HP extensions.
2009-04-24 18:28:58 +00:00
H.J. Lu fc49eaf437 Update ChangeLog entries. 2009-04-24 16:57:08 +00:00
Eli Zaretskii 1f445b924b *** empty log message *** 2009-04-24 14:28:17 +00:00
Eli Zaretskii e05488489f * config.guess (pc:*:*:*): Return i586-pc-msdosdjgpp, for
consistency with config.sub.  (Update from upstream sources.)
2009-04-24 14:27:20 +00:00
Eric Blake 190ccfc18c Be namespace clean in ctype.h.
* libc/include/ctype.h (_tolower, _toupper, isalpha, isupper)
(islower, isdigit, isxdigit, isspace, ispunct, isalnum)
(isprint, isgraph, iscntrl, isblank, toupper, tolower)
(isascii, toascii): Don't use 'c' as macro parameter name.
2009-04-24 12:27:36 +00:00
Eric Blake 1335bf3c5d Trigger gcc warning if isFoo macros are called with plain char.
* libc/include/ctype.h (isalpha, isupper, islower, isdigit)
(isxdigit, isspace, ispunct, isalnum, isprint, isgraph)
(iscntrl, isblank, toupper, tolower): Rewrite to let 'gcc -Wall'
warn when user calls macro with a char argument.
2009-04-24 12:20:07 +00:00
Jeff Johnston 5921804481 2009-04-23 Mike Burgess <wizardsguild@earthlink.net>
* libc/string/strcasecmp.c: Optimized rewrite.
        * libc/string/strncasecmp.c: Fix description.
        * libc/string/strlwr.c: Avoid passing signed char to tolower.
        * libc/string/strupr.c: Avoid passing signed char to tolower.
2009-04-23 18:11:22 +00:00
Jeff Johnston bbb9d4fde3 2009-04-23 Paul Brook <paul@codesourcery.com>
Kazu Hirata  <kazu@codesourcery.com>

        * libc/stdlib/__atexit.c (__register_exitproc): Use weak reference
        to malloc.  Allocate dynamically only if it is present.
        * libc/stdlib/__call_atexit.c (__call_exitprocs): Use weak
        reference to free.  Call free only if it is present.
2009-04-23 17:54:22 +00:00
Jeff Johnston 2beb9fbb02 2009-04-22 Anthony Green <green@moxielogic.com>
* configure.host: Add moxie support.
        * libc/machine/configure.in: Add moxie support.
        * libc/machine/configure: Rebuilt.
        * libc/machine/moxie/aclocal.m4: New file.
        * libc/machine/moxie/configure: New file.
        * libc/machine/moxie/configure.in: New file.
        * libc/machine/moxie/Makefile.am: New file.
        * libc/machine/moxie/Makefile.in: New file.
        * libc/machine/moxie/setjmp.S: New file.
        * libc/include/machine/setjmp.h (_JBLEN): Define for moxie.
        * libc/include/machine/ieeefp.h: Add moxie support.
2009-04-22 19:52:49 +00:00
Jeff Johnston bc6b90cc10 2009-04-22 Anthony Green <green@moxielogic.com>
* configure.in: Add moxie support.
        * configure: Regenerate.
        * moxie/aclocal.m4, moxie/configure, moxie/configure.in,
        moxie/crt0.S, moxie/fstat.c, moxie/getpid.c, isatty.c,
        moxie/kill.c, moxie/Makefile.in, moxie/moxie-elf-common.ld,
        moxie/print.c, moxie/putnum.c, moxie/qemu.ld, moxie/qemu-time.c,
        moxie/qemu-write.c, moxie/sbrk.c, moxie/sim-close.S,
        moxie/sim-exit.S,
        moxie/sim-inbyte.c, moxie/sim.ld, moxie/sim-lseek.c,
        moxie/sim-lseek.S, moxie/sim-open.S, moxie/sim-read.S, moxie/sim-time.c,
        moxie/sim-unlink.S, moxie/sim-write.S, moxie/stat.c: New files.
2009-04-22 19:48:07 +00:00