Commit Graph

2384 Commits

Author SHA1 Message Date
christos 13b9be18f4 fix size and format of time_t holding variable. 2008-12-29 04:09:25 +00:00
dogcow 165e230a9b sprintf to temporary buffer and memcpy, rather than sprintf directly
into place; this avoids possible corruption and coredumping on systems
that more aggressively bounds-check. patch by dbj.
2008-11-25 01:58:13 +00:00
phx 1872c0f94c Applied a patch from Roman Zippel to fix jump table addressing in the M68k
codegen.

Taken from the gcc mailing list January 2007:
http://gcc.gnu.org/ml/gcc-patches/2007-01/msg02476.html

2007-01-30  Roman Zippel <zippel@linux-m68k.org>

        * config/m68k/m68k.c (output_move_himode)
	config/m68k/m68k.md: remove jump table recognition
	* config/m68k/m68k.c (ASM_OUTPUT_CASE_FETCH): use simple pc
	relative addressing

Approved by Christos Zoulas, Alistair Crooks and Matthew Green.
2008-11-20 22:53:17 +00:00
phx 8fea32b8ab Reverted my last modification, because it included GPLv3 code. Sorry. 2008-11-13 18:10:56 +00:00
phx b933ea4d67 Fixed jump table bugs (e.g. detected when compiling lang/php5 for m68k).
The patch was suggested by Gunther Nikl <gnikl@baltic.net> and is part
of gcc 4.3.x.

	Backport from mainline (SVN 128601):
	2007-09-19  Roman Zippel <zippel@linux-m68k.org>

	* config/m68k/m68k.c (output_move_himode): Remove jump table
	recognition.
	config/m68k/m68k.md (lea): Likewise.
	* config/m68k/m68k.c (print_operand_address): Use simple pc
	relative addressing.
2008-11-12 21:40:03 +00:00
matt ee6001e544 Prevent some forced local relocations from going into the GOT/PLT. 2008-11-01 15:09:11 +00:00
uwe 70eb15d9df Teach gdb about reg::r_gbr. From mjf@
XXX: We should probably properly conditionalize these changes by
introducing HAVE_STRUCT_REG_R_GBR
2008-10-27 00:33:19 +00:00
mrg 9917d709a8 - add a i386/t-netbsd64 makefile fragment to build 32/64 bit
libgcc/multilib on amd64
- enable the 32/64 bit libgcc/multilib support on sparc64
- adapt mknative-gcc to grab multilib.h
- use --enable-multilib on amd64 and sparc64

none of this affects the installed tools yet, just the src/tools one.
2008-10-11 05:03:43 +00:00
mrg 5e3d72fe31 move the code that sets ld_vers and other variables so that it is
always executed, regardless of cached values.  this lets the comdat
version test for gas work properly.
2008-10-06 00:07:08 +00:00
mrg 983106fbb3 fix a 2 year old fix that broke genmultilib. ${CONFIG_SHELL}
wasn't expanded inside cat >tmpmultilib<<\EOF due to the \.
use two cat's to generate these files now, one with EOF and
one with \EOF.
2008-10-05 23:04:00 +00:00
lukem 915ac4056f Revert rev 1.9:
* we now disable gettext by not defining ENABLE_NLS,
 * we now link in the xmalloc/xstrdup/xexit replacements explicitly.
Reduces differences to upstream.
2008-09-09 06:32:59 +00:00
dogcow aedef3bb4f eliminate the need for gettext() when building the host-only tool. 2008-09-03 09:55:23 +00:00
christos 4ef43ee396 resolve conflicts 2008-09-02 08:41:51 +00:00
christos 834f5c54aa resolve conflicts. 2008-09-02 08:00:24 +00:00
christos 14e22615fd import last gplv2 version 2008-09-02 07:45:41 +00:00
mrg 674db90903 merge cornflakes from gcc-4-1-20080831-139820 2008-08-31 09:51:31 +00:00
mrg d85c56d01b import GCC 4.1-branch from 20080831 / svn 139820.
this fixes at least these GCC PR's:

	middle-end/35163
	target/34393
	middle_end/34150
	middle-end/34627
	middle-end/33631
	c++/34950
	c++/34774
	c++/35007
	libstdc++/20448
	libstdc++/20451
2008-08-31 09:39:12 +00:00
mrg 603b7728c3 import GCC 4.1-branch from 20080831 / svn 139820.
this fixes at least these GCC PR's:

	middle-end/35163
	target/34393
	middle_end/34150
	middle-end/34627
	middle-end/33631
	c++/34950
	c++/34774
	c++/35007
	libstdc++/20448
	libstdc++/20451
2008-08-31 09:28:43 +00:00
mrg e03df4d47b regen for this commit:
revision 1.9
date: 2008/08/31 08:16:45;  author: mrg;  state: Exp;  lines: +11 -17
move the AC_CACHE_CHECK(__stack_chk_fail, [ ... ]) code out
of the linux-specific section, so that it will be used by
everyone.

use AC_CHECK_FUNS() to check for __stack_chk_guard on netbsd.

now this test is properly cross-compile friendly.
2008-08-31 08:17:21 +00:00
mrg 556a5211d2 move the AC_CACHE_CHECK(__stack_chk_fail, [ ... ]) code out
of the linux-specific section, so that it will be used by
everyone.

use AC_CHECK_FUNS() to check for __stack_chk_guard on netbsd.

now this test is properly cross-compile friendly.
2008-08-31 08:16:45 +00:00
christos a17638d840 resolve conflicts 2008-08-30 10:54:24 +00:00
christos d7398d0e67 import 2.5.4 2008-08-30 10:25:50 +00:00
lukem 68640ea669 Issue a warning if -r is used without a directory:
grep: warning: recursive search of stdin

Patch from:
	http://savannah.gnu.org/patch/?6474
originally from:
	http://www.opensource.apple.com/darwinsource/Current/grep-24/patches/PR-4053512.diff
2008-08-28 03:59:06 +00:00
drochner 15efbe0f34 Back out an old local modification (originating from PR lib/29832)
which effectively disables *wprintf and *wscanf functions in
the std namespace. We have wchar support now.
(It might be necessary to do a "make clean" in
src/gnu/lib/libstdc++-v3_4/include for this to have effect.)
2008-08-27 14:38:58 +00:00
uwe dd998af85f shnbsd_software_single_step: There's no need to write back next_pc and
it actually messes things up if single step was interrupted with a
signal - we end up skipping the instruction we wanted to step.

There are still some corner cases, but at least it works enough to do
useful debugging in presence of signals.  Discovered while debugging
ntpdate where this problem was triggered by SIGALRM.
2008-08-27 01:05:42 +00:00
martin 92ee6fcbd5 Do not completely overwrite tm_defines in m68k specific target selection,
it may have been set globaly before for NETBSD_ENABLE_PTHREADS.
This caused wrong (old, pre NetBSD 2.0) builtin specs for m68k.
Fixes PR toolchain/38931.
2008-08-24 08:38:14 +00:00
lukem 18a7b6ae04 Tweak rules to disable generation of .c files from .l / .y.
(Goal is to minimize differences with the vendor file)
Fix PR 38152.
2008-08-12 10:09:31 +00:00
christos 181678b02c fix -w using:
http://www.linuxfromscratch.org/patches/downloads/grep/\
grep-2.5.1-option_w-1.patch
2008-08-01 15:24:35 +00:00
matt eb096a3c19 Add a few more conditions to the setting of the symbol size for external
dynamic symbols.
2008-07-22 05:35:44 +00:00
apb 5ad2c3f984 Comment out references to the "-P"/"--perl-regexp" option,
which is not supported on NetBSD.  Fixes PR 39122.
2008-07-21 09:15:12 +00:00
christos 657e141577 sockopts need to be int not ssize_t, which can be long on 64 bit machines.
fixes sparc64 issue. thanks to rafal for testing.
2008-07-16 16:51:14 +00:00
matt 92f61a999a Previous fix only got some undefined symbols. This one gets all of them. 2008-07-14 17:59:41 +00:00
matt 890018501f Set the size of undefined symbols to 0. 2008-07-14 15:55:03 +00:00
christos 872dac48eb /var/lib -> /var/db by popular demand. 2008-06-25 01:32:37 +00:00
christos db19bd9062 resolve conflicts. 2008-06-22 14:38:40 +00:00
christos a903102c9a import 2.5.2, requested by perry, approved by releng. 2008-06-22 14:02:40 +00:00
adrianp 8aae81d82f Fix for PR #33551 (a.k.a CVE-2006-2362)
Back port from the binutils CVS tree

Buffer overflow in getsym in tekhex.c in libbfd in Free Software Foundation
GNU Binutils before 20060423, as used by GNU strings, allows context-dependent
attackers to cause a denial of service (application crash) and possibly
execute arbitrary code via a file with a crafted Tektronix Hex Format (TekHex)
record in which the length character is not a valid hexadecimal character.
2008-06-22 14:02:39 +00:00
christos 0eea94d78f import 2.5.2, requested by perry, approved by releng. 2008-06-22 14:00:13 +00:00
christos b4e47fa186 import 2.5.2, requested by perry, approved by releng. 2008-06-22 13:59:17 +00:00
christos e5a95dcfd5 usage message 2008-06-22 13:55:05 +00:00
christos a81b2a4e6c Restore functionality lost during the libcpp conversion: cpp -CC should convert
// comments to /* comments */ not only during macro definition, but also
macro argument collection. Otherwise the following:

    #define b(a) a
    main {
	b(
	// 1);
	0);
    }

gets expanded to:

    main()
    {
	    return //          1); 0;
    }

instead of:

    main()
    {
	    return /*          1);*/ 0;
    }
2008-05-30 15:12:24 +00:00
tsutsui 407e634a58 Pull the follwoing fix from upstream:
http://gcc.gnu.org/viewcvs/trunk/gcc/config/m68k/m68k.md#rev117181
>       * config/m68k/m68k.md (negsf2, negdf2, negxf2): Use
>       -2147483647 - 1 instead of 0x80000000.

Fixes "internal compiler error: in do_SUBST" on compiling
floating point ops with -msoft-float or -m68010 on LP64 hosts,
and may also close PR toolchain/38359.  Tested on alpha.
2008-05-01 23:50:32 +00:00
martin 11a6dbe728 Convert TNF licenses to new 2 clause variant 2008-04-30 13:10:46 +00:00
christos 29c39f7ad5 Add -lc when -shared so that all shared libraries built by the compiler
have a dependency to -lc. To avoid adding that dependency in -lc and -lgcc*
we add -nostdlib to the compile rules.
2008-04-27 23:49:27 +00:00
uwe 95c5c2aebe Defer wide int L/LL suffix choice in insn-*.c until we compile for
host using correct set of HOST_WIDE_INT* defines.  Fixes compilation
of native sh3 gcc on 64-bit build machines.

Background and details in NetBSD PR 34549 and GCC bug 32497.
Tested by Joerg and myself.

Approved by "looks ok, but let some other guy decide" from ~all of our
gcc folks.
2008-04-22 22:06:01 +00:00
skrll 9a2b7df6e3 Apply fix from binutils-current so that sparc gdb can be cross built
on a 64bit host.

Problem reported by mrg.
2008-04-09 10:26:20 +00:00
matt 2c2b152b21 Add support for --ignore-unresolved-symbol 2008-04-03 15:40:17 +00:00
skrll 482dcc2f35 #include "nbsd-nat.h" 2008-03-17 20:01:12 +00:00
skrll 1c84a0c3c5 Add nbsd_pid_to_exec_file to target ops. 2008-03-17 17:39:15 +00:00
skrll 7fa564a753 strcmp doesn't taken a length argument. 2008-03-15 12:19:41 +00:00