[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#163883: marked as done (gcc-3.2: support for i386-freebsd-gnu (Debian freebsd-i386 port))



Your message dated Sun, 20 Oct 2002 09:02:30 -0400
with message-id <E183Fiw-0005aJ-00@auric.debian.org>
and subject line Bug#163883: fixed in gcc-3.2 1:3.2.1ds3-0pre4
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 9 Oct 2002 00:48:11 +0000
>From utsl@utsl.org Tue Oct 08 19:48:11 2002
Return-path: <utsl@utsl.org>
Received: from cvg-65-27-234-246.cinci.rr.com (trantor.utsl.org) [65.27.234.246] 
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 17z51F-0005dY-00; Tue, 08 Oct 2002 19:48:09 -0500
Received: from hotrod.utsl.org ([10.10.57.3])
	by trantor.utsl.org with smtp (Exim 3.35 #1 (Debian))
	id 17z518-0000qG-00; Tue, 08 Oct 2002 20:48:02 -0400
Received: by hotrod.utsl.org (sSMTP sendmail emulation); Tue,  8 Oct 2002 20:46:37 -0400
Date: Tue, 8 Oct 2002 20:46:37 -0400
From: Nathan Hawkins <utsl@debian.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: gcc-3.2: support for i386-freebsd-gnu (Debian freebsd-i386 port)
Message-ID: <20021009004637.GA28942@hotrod.quic.net>
Mime-Version: 1.0
Content-Type: multipart/mixed; boundary="CE+1k2dSO48ffgeK"
Content-Disposition: inline
User-Agent: Mutt/1.4i
X-Reportbug-Version: 1.50
Delivered-To: submit@bugs.debian.org


--CE+1k2dSO48ffgeK
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Package: gcc-3.2
Version: 1:3.2.1-0pre2
Severity: important
Tags: patch

The attached patch adds support for i386-*-freebsd-gnu and
alpha-*-freebsd-gnu.  This is freebsd with glibc, used by freebsd-i386
port.

The patch is against 1:3.2.1ds2-0pre3, not what it says below.

-- System Information
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux hotrod 2.4.18 #1 SMP Thu May 30 01:10:09 EDT 2002 i686
Locale: LANG=C, LC_CTYPE=C

Versions of packages gcc-3.2 depends on:
ii  binutils                   2.13.90.0.4-1 The GNU assembler, linker and bina
ii  cpp-3.2                    1:3.2.1-0pre2 The GNU C preprocessor.
ii  gcc-3.2-base               1:3.2.1-0pre2 The GNU Compiler Collection (base 
ii  libc6                      2.2.5-14.3    GNU C Library: Shared libraries an
ii  libgcc1                    1:3.2.1-0pre2 GCC support library.

--CE+1k2dSO48ffgeK
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="gcc-3.2-freebsd.diff"

diff -urN gcc-3.2-3.2.1ds2/debian/patches/freebsd-gnu.dpatch gcc-3.2-3.2.1ds2-bak/debian/patches/freebsd-gnu.dpatch
--- gcc-3.2-3.2.1ds2/debian/patches/freebsd-gnu.dpatch	1969-12-31 19:00:00.000000000 -0500
+++ gcc-3.2-3.2.1ds2-bak/debian/patches/freebsd-gnu.dpatch	2002-10-08 20:27:31.000000000 -0400
@@ -0,0 +1,863 @@
+#! /bin/sh -e
+
+# All lines beginning with `# DPATCH:' are a description of the patch.
+# DP: GNU/FreeBSD support
+
+dir=
+if [ $# -eq 3 -a "$2" = '-d' ]; then
+    pdir="-d $3"
+    dir="$3/"
+elif [ $# -ne 1 ]; then
+    echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+    exit 1
+fi
+case "$1" in
+    -patch)
+        patch $pdir -f --no-backup-if-mismatch -p1 < $0
+        #cd ${dir}gcc && autoconf
+        ;;
+    -unpatch)
+        patch $pdir -f --no-backup-if-mismatch -R -p1 < $0
+        #rm ${dir}gcc/configure
+        ;;
+    *)
+        echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+        exit 1
+esac
+exit 0
+
+
+diff -urN src/boehm-gc/configure newsrc/boehm-gc/configure
+--- src/boehm-gc/configure	2002-05-08 02:15:14.000000000 -0400
++++ newsrc/boehm-gc/configure	2002-10-03 13:23:34.000000000 -0400
+@@ -2709,6 +2709,16 @@
+ 
+ 	THREADLIBS="-lpthread -lrt"
+ 	;;
++     *-*-freebsd*-gnu*)
++	cat >> confdefs.h <<\EOF
++#define GC_LINUX_THREADS 1
++EOF
++
++	cat >> confdefs.h <<\EOF
++#define _REENTRANT 1
++EOF
++
++	;;
+      *-*-freebsd*)
+ 	echo "configure: warning: "FreeBSD does not yet fully support threads with Boehm GC."" 1>&2
+ 	cat >> confdefs.h <<\EOF
+diff -urN src/boehm-gc/configure.in newsrc/boehm-gc/configure.in
+--- src/boehm-gc/configure.in	2002-05-08 01:48:18.000000000 -0400
++++ newsrc/boehm-gc/configure.in	2002-10-03 13:23:34.000000000 -0400
+@@ -95,6 +95,10 @@
+ 	AC_DEFINE(THREAD_LOCAL_ALLOC)
+ 	THREADLIBS="-lpthread -lrt"
+ 	;;
++     *-*-freebsd*-gnu*)
++	AC_DEFINE(GC_LINUX_THREADS)
++	AC_DEFINE(_REENTRANT)
++	;;
+      *-*-freebsd*)
+ 	AC_MSG_WARN("FreeBSD does not yet fully support threads with Boehm GC.")
+ 	AC_DEFINE(GC_FREEBSD_THREADS)
+diff -urN src/boehm-gc/dbg_mlc.c newsrc/boehm-gc/dbg_mlc.c
+--- src/boehm-gc/dbg_mlc.c	2002-03-01 18:37:23.000000000 -0500
++++ newsrc/boehm-gc/dbg_mlc.c	2002-10-03 13:23:34.000000000 -0400
+@@ -60,7 +60,8 @@
+ # include <stdlib.h>
+ 
+ # if defined(LINUX) || defined(SUNOS4) || defined(SUNOS5) \
+-     || defined(HPUX) || defined(IRIX) || defined(OSF1)
++     || defined(HPUX) || defined(IRIX) || defined(OSF1) \
++     || defined(GLIBC_FREEBSD)
+ #   define RANDOM() random()
+ # else
+ #   define RANDOM() (long)rand()
+@@ -819,7 +820,7 @@
+ void GC_check_heap_proc()
+ {
+ #   ifndef SMALL_CONFIG
+-	if (sizeof(oh) & (2 * sizeof(word) - 1) != 0) {
++	if ((sizeof(oh) & (2 * sizeof(word) - 1)) != 0) {
+ 	    ABORT("Alignment problem: object header has inappropriate size\n");
+ 	}
+ #   endif
+diff -urN src/boehm-gc/dyn_load.c newsrc/boehm-gc/dyn_load.c
+--- src/boehm-gc/dyn_load.c	2002-04-13 03:36:30.000000000 -0400
++++ newsrc/boehm-gc/dyn_load.c	2002-10-03 13:23:34.000000000 -0400
+@@ -26,7 +26,7 @@
+  * None of this is safe with dlclose and incremental collection.
+  * But then not much of anything is safe in the presence of dlclose.
+  */
+-#if defined(__linux__) && !defined(_GNU_SOURCE)
++#if (defined(__linux__) || defined(__gnu_freebsd__)) && !defined(_GNU_SOURCE)
+     /* Can't test LINUX, since this must be define before other includes */
+ #   define _GNU_SOURCE
+ #endif
+@@ -446,7 +446,7 @@
+ /* For glibc 2.2.4+.  Unfortunately, it doesn't work for older	*/
+ /* versions.  Thanks to Jakub Jelinek for most of the code.	*/
+ 
+-# if defined(LINUX) /* Are others OK here, too? */ \
++# if (defined(LINUX) || defined(GLIBC_FREEBSD)) /* Are others OK here, too? */ \
+      && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2) \
+          || (__GLIBC__ == 2 && __GLIBC_MINOR__ == 2 && defined(DT_CONFIG))) 
+ 
+@@ -510,7 +510,7 @@
+   }
+ }
+ 
+-# else /* !LINUX || version(glibc) < 2.2.4 */
++# else /* !(LINUX || GLIBC_FREEBSD) || version(glibc) < 2.2.4 */
+ 
+ /* Dynamic loading code for Linux running ELF. Somewhat tested on
+  * Linux/x86, untested but hopefully should work on Linux/Alpha. 
+diff -urN src/boehm-gc/include/private/gcconfig.h newsrc/boehm-gc/include/private/gcconfig.h
+--- src/boehm-gc/include/private/gcconfig.h	2002-04-22 02:27:51.000000000 -0400
++++ newsrc/boehm-gc/include/private/gcconfig.h	2002-10-03 13:23:34.000000000 -0400
+@@ -1051,25 +1051,40 @@
+ #   endif
+ #   ifdef FREEBSD
+ #	define OS_TYPE "FREEBSD"
+-#	ifndef GC_FREEBSD_THREADS
+-#	    define MPROTECT_VDB
+-#	endif
+-#	define SIG_SUSPEND SIGUSR1
+-#	define SIG_THR_RESTART SIGUSR2
+ #	define FREEBSD_STACKBOTTOM
+ #	ifdef __ELF__
+ #	    define DYNAMIC_LOADING
+ #	endif
++#	ifdef __gnu_freebsd__
++	    /* FreeBSD with glibc.  Implies __ELF__.  */
++#	    define GLIBC_FREEBSD
++#	    if !defined(GC_LINUX_THREADS) || !defined(REDIRECT_MALLOC)
++#		define MPROTECT_VDB
++#	    endif
++#	    define SIG_SUSPEND     57 /* arbitrary signal number <= 128 */
++#	    define SIG_THR_RESTART 58 /* arbitrary signal number <= 128 */
++#	    define LINUX_DATA_START
++	    extern int _end[];
++#	    define DATAEND (_end)
++#	    define USE_MMAP	/* brk(0) doesn't return a meaningful value */
++#	else
++	    /* FreeBSD with BSD libc.  */
++#	    ifndef GC_FREEBSD_THREADS
++#		define MPROTECT_VDB
++#	    endif
++#	    define SIG_SUSPEND SIGUSR1
++#	    define SIG_THR_RESTART SIGUSR2
+ /* Handle unmapped hole i386*-*-freebsd[45]* may put between etext and edata. */
+-	extern char etext[];
+-	extern char edata[];
+-	extern char end[];
+-#	define NEED_FIND_LIMIT
+-#	define DATASTART ((ptr_t)(etext))
+-#   	define MIN(x,y) ((x) < (y) ? (x) : (y))
+-#	define DATAEND (MIN (GC_find_limit (DATASTART, TRUE), DATASTART2))
+-#	define DATASTART2 ((ptr_t)(edata))
+-#	define DATAEND2 ((ptr_t)(end))
++	    extern char etext[];
++	    extern char edata[];
++	    extern char end[];
++#	    define NEED_FIND_LIMIT
++#	    define DATASTART ((ptr_t)(etext))
++#   	    define MIN(x,y) ((x) < (y) ? (x) : (y))
++#	    define DATAEND (MIN (GC_find_limit (DATASTART, TRUE), DATASTART2))
++#	    define DATASTART2 ((ptr_t)(edata))
++#	    define DATAEND2 ((ptr_t)(end))
++#	endif
+ #   endif
+ #   ifdef NETBSD
+ #	define OS_TYPE "NETBSD"
+@@ -1764,7 +1779,7 @@
+ # if defined(GC_IRIX_THREADS) && !defined(IRIX5)
+ --> inconsistent configuration
+ # endif
+-# if defined(GC_LINUX_THREADS) && !defined(LINUX)
++# if defined(GC_LINUX_THREADS) && !(defined(LINUX) || defined(FREEBSD))
+ --> inconsistent configuration
+ # endif
+ # if defined(GC_SOLARIS_THREADS) && !defined(SUNOS5)
+@@ -1807,7 +1822,7 @@
+ /* build time, though we feel free to adjust it slightly.		*/
+ /* Define NEED_CALLINFO if we either save the call stack or 		*/
+ /* GC_ADD_CALLER is defined.						*/
+-#ifdef LINUX
++#if defined(LINUX) || defined(GLIBC_FREEBSD)
+ # include <features.h>
+ # if __GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2
+ #   define HAVE_BUILTIN_BACKTRACE
+@@ -1818,7 +1833,7 @@
+ # define CAN_SAVE_CALL_STACKS
+ # define CAN_SAVE_CALL_ARGS
+ #endif
+-#if defined(I386) && defined(LINUX)
++#if defined(I386) && (defined(LINUX) || defined(GLIBC_FREEBSD))
+     /* SAVE_CALL_CHAIN is supported if the code is compiled to save	*/
+     /* frame pointers by default, i.e. no -fomit-frame-pointer flag.	*/
+ # define CAN_SAVE_CALL_STACKS
+diff -urN src/boehm-gc/linux_threads.c newsrc/boehm-gc/linux_threads.c
+--- src/boehm-gc/linux_threads.c	2002-03-30 05:41:57.000000000 -0500
++++ newsrc/boehm-gc/linux_threads.c	2002-10-03 13:23:34.000000000 -0400
+@@ -992,6 +992,7 @@
+ 
+ #ifdef GC_LINUX_THREADS
+ /* Return the number of processors, or i<= 0 if it can't be determined.	*/
++# ifdef LINUX
+ int GC_get_nprocs()
+ {
+     /* Should be "return sysconf(_SC_NPROCESSORS_ONLN);" but that	*/
+@@ -1027,6 +1028,21 @@
+     }
+     return result;
+ }
++# endif /* LINUX */
++# ifdef FREEBSD
++#include <sys/sysctl.h>
++int GC_get_nprocs()
++{
++    int request[] = { CTL_HW, HW_NCPU };
++    int result;
++    size_t result_len = sizeof (result);
++
++    if (sysctl(request, 2, &result, &result_len, NULL, 0) < 0)
++	/* Dummy result.  */
++	result = 1;
++    return result;
++}
++# endif /* FREEBSD */
+ #endif /* GC_LINUX_THREADS */
+ 
+ /* We hold the allocation lock.	*/
+@@ -1193,7 +1209,7 @@
+     UNLOCK();
+ }
+ 
+-GC_end_blocking(void) {
++void GC_end_blocking(void) {
+     GC_thread me;
+     LOCK();   /* This will block if the world is stopped.	*/
+     me = GC_lookup_thread(pthread_self());
+diff -urN src/boehm-gc/ltconfig newsrc/boehm-gc/ltconfig
+--- src/boehm-gc/ltconfig	2002-01-07 00:57:00.000000000 -0500
++++ newsrc/boehm-gc/ltconfig	2002-10-03 13:23:34.000000000 -0400
+@@ -1867,7 +1867,21 @@
+ freebsd1*)
+   dynamic_linker=no
+   ;;
+-  
++
++freebsd*-gnu*)
++  version_type=linux
++  need_lib_prefix=no
++  need_version=no
++  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
++  soname_spec='${libname}${release}.so$major'
++  shlibpath_var=LD_LIBRARY_PATH
++  shlibpath_overrides_runpath=no
++  hardcode_into_libs=yes
++  dynamic_linker='GNU ld.so'
++  # Don't assume a particular installation location.
++  sys_lib_search_path_spec=""
++  ;;
++
+ freebsd*)
+   objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
+   version_type=freebsd-$objformat
+diff -urN src/boehm-gc/os_dep.c newsrc/boehm-gc/os_dep.c
+--- src/boehm-gc/os_dep.c	2002-04-13 03:36:32.000000000 -0400
++++ newsrc/boehm-gc/os_dep.c	2002-10-03 13:23:34.000000000 -0400
+@@ -118,7 +118,8 @@
+ # include <fcntl.h>
+ #endif
+ 
+-#if defined(SUNOS5SIGS) || defined (HURD) || defined(LINUX)
++#if defined(SUNOS5SIGS) || defined (HURD) || defined(LINUX) \
++    || defined(GLIBC_FREEBSD)
+ # ifdef SUNOS5SIGS
+ #  include <sys/siginfo.h>
+ # endif
+@@ -153,12 +154,12 @@
+   /* for recent Linux versions.  This seems to be the easiest way to	*/
+   /* cover all versions.						*/
+ 
+-# ifdef LINUX
++# if defined(LINUX) || defined(GLIBC_FREEBSD)
+ #   pragma weak __data_start
+     extern int __data_start[];
+ #   pragma weak data_start
+     extern int data_start[];
+-# endif /* LINUX */
++# endif /* LINUX || GLIBC_FREEBSD */
+   extern int _end[];
+ 
+   ptr_t GC_data_start;
+@@ -167,7 +168,7 @@
+   {
+     extern ptr_t GC_find_limit();
+ 
+-#   ifdef LINUX
++#   if defined(LINUX) || defined(GLIBC_FREEBSD)
+       /* Try the easy approaches first:	*/
+       if (__data_start != 0) {
+ 	  GC_data_start = (ptr_t)__data_start;
+@@ -177,7 +178,7 @@
+ 	  GC_data_start = (ptr_t)data_start;
+ 	  return;
+       }
+-#   endif /* LINUX */
++#   endif /* LINUX || GLIBC_FREEBSD */
+     GC_data_start = GC_find_limit((ptr_t)_end, FALSE);
+   }
+ #endif
+@@ -3060,7 +3061,8 @@
+ /* I suspect the following works for most X86 *nix variants, so 	*/
+ /* long as the frame pointer is explicitly stored.  In the case of gcc,	*/
+ /* compiler flags (e.g. -fomit-frame-pointer) determine whether it is.	*/
+-#if defined(I386) && defined(LINUX) && defined(SAVE_CALL_CHAIN)
++#if defined(I386) && (defined(LINUX) || defined(GLIBC_FREEBSD)) \
++    && defined(SAVE_CALL_CHAIN)
+ #   include <features.h>
+ 
+     struct frame {
+@@ -3109,7 +3111,7 @@
+ /* Fill in the pc and argument information for up to NFRAMES of my	*/
+ /* callers.  Ignore my frame and my callers frame.			*/
+ 
+-#ifdef LINUX
++#if defined(LINUX) || defined(GLIBC_FREEBSD)
+ # include <features.h>
+ # if __GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 || __GLIBC__ > 2
+ #   define HAVE_BUILTIN_BACKTRACE
+diff -urN src/config.guess newsrc/config.guess
+--- src/config.guess	2002-04-16 18:03:36.000000000 -0400
++++ newsrc/config.guess	2002-10-03 13:23:34.000000000 -0400
+@@ -726,7 +726,19 @@
+ 	echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
+ 	exit 0 ;;
+     *:FreeBSD:*:*)
+-	echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
++	# Determine whether the default compiler uses glibc.
++	eval $set_cc_for_build
++	sed 's/^	//' << EOF >$dummy.c
++	#include <features.h>
++	#if __GLIBC__ >= 2
++	LIBC=gnu
++	#else
++	LIBC=
++	#endif
++EOF
++	eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
++	rm -f $dummy.c
++	echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC}
+ 	exit 0 ;;
+     i*:CYGWIN*:*)
+ 	echo ${UNAME_MACHINE}-pc-cygwin
+diff -urN src/config.sub newsrc/config.sub
+--- src/config.sub	2002-03-01 18:37:07.000000000 -0500
++++ newsrc/config.sub	2002-10-03 13:23:34.000000000 -0400
+@@ -118,7 +118,7 @@
+ # Here we must recognize all the valid KERNEL-OS combinations.
+ maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
+ case $maybe_os in
+-  nto-qnx* | linux-gnu* | storm-chaos* | os2-emx* | windows32-*)
++  nto-qnx* | linux-gnu* | freebsd*-gnu* | storm-chaos* | os2-emx* | windows32-*)
+     os=-$maybe_os
+     basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
+     ;;
+diff -urN src/configure.in newsrc/configure.in
+--- src/configure.in	2002-07-09 02:54:56.000000000 -0400
++++ newsrc/configure.in	2002-10-03 13:23:34.000000000 -0400
+@@ -363,7 +363,7 @@
+   alpha*-*-*)
+     target_makefile_frag="${target_makefile_frag} config/mt-alphaieee"
+     ;;
+-  *-*-linux*)
++  *-*-linux* | *-*-freebsd*-gnu*)
+     target_makefile_frag="${target_makefile_frag} config/mt-linux"
+     ;;
+   *-*-aix4.[3456789]* | *-*-aix[56789].*)
+diff -urN src/gcc/config/alpha/freebsdgnu.h newsrc/gcc/config/alpha/freebsdgnu.h
+--- src/gcc/config/alpha/freebsdgnu.h	1969-12-31 19:00:00.000000000 -0500
++++ newsrc/gcc/config/alpha/freebsdgnu.h	2002-10-03 13:23:34.000000000 -0400
+@@ -0,0 +1,39 @@
++/* Definitions for Alpha running FreeBSD-based GNU systems with ELF format.
++   Copyright (C) 2002 Free Software Foundation, Inc.
++   Contributed by Bruno Haible.
++
++This file is part of GNU CC.
++
++GNU CC is free software; you can redistribute it and/or modify
++it under the terms of the GNU General Public License as published by
++the Free Software Foundation; either version 2, or (at your option)
++any later version.
++
++GNU CC is distributed in the hope that it will be useful,
++but WITHOUT ANY WARRANTY; without even the implied warranty of
++MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++GNU General Public License for more details.
++
++You should have received a copy of the GNU General Public License
++along with GNU CC; see the file COPYING.  If not, write to
++the Free Software Foundation, 59 Temple Place - Suite 330,
++Boston, MA 02111-1307, USA.  */
++
++#undef TARGET_VERSION
++#define TARGET_VERSION fprintf (stderr, " (Alpha FreeBSD/ELF)");
++
++/* FIXME: Is a FreeBSD-specific fallback mechanism necessary?  */
++#undef MD_FALLBACK_FRAME_STATE_FOR
++
++#undef ELF_DYNAMIC_LINKER
++#define ELF_DYNAMIC_LINKER "/lib/ld.so.1"
++
++#undef LINK_SPEC
++#define LINK_SPEC "-m elf64alpha_fbsd %{G*} %{relax:-relax}	\
++  %{O*:-O3} %{!O*:-O1}						\
++  %{shared:-shared}						\
++  %{!shared:							\
++    %{!static:							\
++      %{rdynamic:-export-dynamic}				\
++      %{!dynamic-linker:-dynamic-linker %(elf_dynamic_linker)}}	\
++    %{static:-static}}"
+diff -urN src/gcc/config/freebsdgnu.h newsrc/gcc/config/freebsdgnu.h
+--- src/gcc/config/freebsdgnu.h	1969-12-31 19:00:00.000000000 -0500
++++ newsrc/gcc/config/freebsdgnu.h	2002-10-03 13:23:34.000000000 -0400
+@@ -0,0 +1,26 @@
++/* Definitions for FreeBSD-based GNU systems with ELF format.
++   Copyright (C) 2002 Free Software Foundation, Inc.
++   Contributed by Bruno Haible.
++
++This file is part of GNU CC.
++
++GNU CC is free software; you can redistribute it and/or modify
++it under the terms of the GNU General Public License as published by
++the Free Software Foundation; either version 2, or (at your option)
++any later version.
++
++GNU CC is distributed in the hope that it will be useful,
++but WITHOUT ANY WARRANTY; without even the implied warranty of
++MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++GNU General Public License for more details.
++
++You should have received a copy of the GNU General Public License
++along with GNU CC; see the file COPYING.  If not, write to
++the Free Software Foundation, 59 Temple Place - Suite 330,
++Boston, MA 02111-1307, USA.  */
++
++#undef WCHAR_TYPE
++#define WCHAR_TYPE "int"
++
++#undef CPP_PREDEFINES
++#define CPP_PREDEFINES "-D__FreeBSD__=4 -D__ELF__ -Dunix -D__gnu_freebsd__ -Asystem=posix"
+diff -urN src/gcc/config/i386/freebsdgnu.h newsrc/gcc/config/i386/freebsdgnu.h
+--- src/gcc/config/i386/freebsdgnu.h	1969-12-31 19:00:00.000000000 -0500
++++ newsrc/gcc/config/i386/freebsdgnu.h	2002-10-03 13:23:34.000000000 -0400
+@@ -0,0 +1,35 @@
++/* Definitions for Intel 386 running FreeBSD-based GNU systems with ELF format.
++   Copyright (C) 2002 Free Software Foundation, Inc.
++   Contributed by Bruno Haible.
++
++This file is part of GNU CC.
++
++GNU CC is free software; you can redistribute it and/or modify
++it under the terms of the GNU General Public License as published by
++the Free Software Foundation; either version 2, or (at your option)
++any later version.
++
++GNU CC is distributed in the hope that it will be useful,
++but WITHOUT ANY WARRANTY; without even the implied warranty of
++MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++GNU General Public License for more details.
++
++You should have received a copy of the GNU General Public License
++along with GNU CC; see the file COPYING.  If not, write to
++the Free Software Foundation, 59 Temple Place - Suite 330,
++Boston, MA 02111-1307, USA.  */
++
++#undef TARGET_VERSION
++#define TARGET_VERSION fprintf (stderr, " (i386 FreeBSD/ELF)");
++
++/* FIXME: Is a FreeBSD-specific fallback mechanism necessary?  */
++#undef MD_FALLBACK_FRAME_STATE_FOR
++
++#undef LINK_SPEC
++#define LINK_SPEC "-m elf_i386_fbsd %{shared:-shared} \
++  %{!shared: \
++    %{!ibcs: \
++      %{!static: \
++	%{rdynamic:-export-dynamic} \
++	%{!dynamic-linker:-dynamic-linker /lib/ld.so.1}} \
++	%{static:-static}}}"
+diff -urN src/gcc/config/t-freebsd-gnu newsrc/gcc/config/t-freebsd-gnu
+--- src/gcc/config/t-freebsd-gnu	1969-12-31 19:00:00.000000000 -0500
++++ newsrc/gcc/config/t-freebsd-gnu	2002-10-03 13:23:34.000000000 -0400
+@@ -0,0 +1,19 @@
++# Don't run fixproto
++STMP_FIXPROTO =
++
++# glibc provides a limits.h, which must be combined with gcc's limits.h.
++LIMITS_H_TEST = true
++
++# Compile crtbeginS.o and crtendS.o with pic.
++CRTSTUFF_T_CFLAGS_S = -fPIC
++# Compile libgcc2.a with pic.
++TARGET_LIBGCC2_CFLAGS = -fPIC
++
++# Override t-slibgcc-elf-ver to export some libgcc symbols with
++# the symbol versions that glibc used.
++SHLIB_MAPFILES += $(srcdir)/config/libgcc-glibc.ver
++
++# Use unwind-dw2-fde-glibc
++LIB2ADDEH = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde-glibc.c \
++  $(srcdir)/unwind-sjlj.c
++LIB2ADDEHDEP = unwind.inc unwind-dw2-fde.h unwind-dw2-fde.c
+diff -urN src/gcc/config.gcc newsrc/gcc/config.gcc
+--- src/gcc/config.gcc	2002-08-06 16:50:05.000000000 -0400
++++ newsrc/gcc/config.gcc	2002-10-03 13:23:34.000000000 -0400
+@@ -361,7 +361,8 @@
+ 	;;
+ esac
+ 
+-# Common parts for GNU/Linux, GNU/Hurd, OpenBSD, NetBSD, and FreeBSD systems.
++# Common parts for GNU/Linux, GNU/Hurd, GNU/FreeBSD, OpenBSD, NetBSD, and
++# FreeBSD systems.
+ case $machine in
+ *-*-linux*)
+ 	xm_defines=POSIX
+@@ -376,6 +377,14 @@
+ 		;;
+ 	esac
+ 	;;
++*-*-freebsd*-gnu*)
++	xm_defines=POSIX
++	# GNU/FreeBSD uses ELF.
++	elf=yes
++	# GNU tools are the only tools.
++	gnu_ld=yes
++	gas=yes
++	;;
+ *-*-gnu*)
+ 	# On the Hurd, the setup is just about the same on
+ 	# each different CPU.  The specific machines that we
+@@ -569,6 +578,16 @@
+ 	extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o"
+ 	gas=yes gnu_ld=yes
+ 	;;
++alpha*-*-freebsd*-gnu*)
++	tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h freebsdgnu.h alpha/freebsdgnu.h"
++	target_cpu_default="MASK_GAS"
++	tmake_file="t-slibgcc-elf-ver t-freebsd-gnu alpha/t-crtfm alpha/t-alpha alpha/t-ieee"
++	extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o"
++	gas=yes gnu_ld=yes
++	if test x$enable_threads = xyes; then
++	  thread_file='posix'
++	fi
++	;;
+ alpha*-*-freebsd*)
+ 	tm_file="${tm_file} ${fbsd_tm_file} alpha/elf.h alpha/freebsd.h"
+ 	target_cpu_default="MASK_GAS"
+@@ -1236,6 +1255,15 @@
+ # Next line turned off because both 386BSD and BSD/386 use GNU ld.
+ #	use_collect2=yes
+ 	;;
++i[34567]86-*-freebsd*-gnu*) # i386 running FreeBSD with ELF format using glibc2
++	tm_file="${tm_file} i386/att.h dbxelf.h elfos.h svr4.h linux.h i386/linux.h freebsdgnu.h i386/freebsdgnu.h"
++	tmake_file="t-slibgcc-elf-ver t-freebsd-gnu i386/t-crtstuff"
++	extra_parts="crtbegin.o crtbeginS.o crtbeginT.o crtend.o crtendS.o"
++	float_format=i386
++	if test x$enable_threads = xyes; then
++	  thread_file='posix'
++	fi
++	;;
+ i[34567]86-*-freebsd[12] | i[34567]86-*-freebsd[12].* | i[34567]86-*-freebsd*aout*)
+ 	tm_file=i386/freebsd-aout.h
+ 	tmake_file=t-freebsd
+diff -urN src/gcc/cppfiles.c newsrc/gcc/cppfiles.c
+--- src/gcc/cppfiles.c	2002-08-15 17:34:17.000000000 -0400
++++ newsrc/gcc/cppfiles.c	2002-10-03 13:23:34.000000000 -0400
+@@ -193,11 +193,13 @@
+      cpp_reader *pfile;
+      const char *fname;
+ {
++  int saved_errno;
+   splay_tree_node node;
+   struct include_file *file;
+   char *name = xstrdup (fname);
+ 
+   _cpp_simplify_pathname (name);
++  saved_errno = errno;
+   node = splay_tree_lookup (pfile->all_include_files, (splay_tree_key) name);
+   if (node)
+     free (name);
+@@ -205,7 +207,7 @@
+     {
+       file = xcnew (struct include_file);
+       file->name = name;
+-      file->err_no = errno;
++      file->err_no = saved_errno;
+       node = splay_tree_insert (pfile->all_include_files,
+ 				(splay_tree_key) file->name,
+ 				(splay_tree_value) file);
+diff -urN src/gcc/ginclude/stddef.h newsrc/gcc/ginclude/stddef.h
+--- src/gcc/ginclude/stddef.h	2002-03-01 18:39:03.000000000 -0500
++++ newsrc/gcc/ginclude/stddef.h	2002-10-03 13:23:34.000000000 -0400
+@@ -1,4 +1,4 @@
+-/* Copyright (C) 1989, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
++/* Copyright (C) 1989, 1997-1999, 2000, 2002 Free Software Foundation, Inc.
+ 
+ This file is part of GNU CC.
+ 
+@@ -53,7 +53,7 @@
+ 
+ /* On 4.3bsd-net2, make sure ansi.h is included, so we have
+    one less case to deal with in the following.  */
+-#if defined (__BSD_NET2__) || defined (____386BSD____) || defined (__FreeBSD__) || defined(__NetBSD__)
++#if defined (__BSD_NET2__) || defined (____386BSD____) || (defined (__FreeBSD__) && !defined (__gnu_freebsd__)) || defined(__NetBSD__)
+ #include <machine/ansi.h>
+ #endif
+ 
+diff -urN src/libjava/configure newsrc/libjava/configure
+--- src/libjava/configure	2002-05-08 02:15:14.000000000 -0400
++++ newsrc/libjava/configure	2002-10-03 13:23:34.000000000 -0400
+@@ -3218,6 +3218,11 @@
+      *-*-cygwin*)
+ 	# Don't set THREADLIBS here.  Cygwin doesn't have -lpthread.
+ 	;;
++     *-*-freebsd*-gnu*)
++	# FreeBSD with glibc has -lpthread.
++	THREADLIBS=-lpthread
++	THREADSPEC=-lpthread
++	;;
+    
+      *-*-freebsd[1234]*)
+    
+diff -urN src/libjava/configure.in newsrc/libjava/configure.in
+--- src/libjava/configure.in	2002-05-08 02:06:06.000000000 -0400
++++ newsrc/libjava/configure.in	2002-10-03 13:23:34.000000000 -0400
+@@ -375,6 +375,11 @@
+      *-*-cygwin*)
+ 	# Don't set THREADLIBS here.  Cygwin doesn't have -lpthread.
+ 	;;
++     *-*-freebsd*-gnu*)
++	# FreeBSD with glibc has -lpthread.
++	THREADLIBS=-lpthread
++	THREADSPEC=-lpthread
++	;;
+ changequote(<<,>>)   
+      *-*-freebsd[1234]*)
+ changequote([,])   
+diff -urN src/libstdc++-v3/acinclude.m4 newsrc/libstdc++-v3/acinclude.m4
+--- src/libstdc++-v3/acinclude.m4	2002-09-13 01:24:39.000000000 -0400
++++ newsrc/libstdc++-v3/acinclude.m4	2002-10-03 13:23:34.000000000 -0400
+@@ -1118,7 +1118,7 @@
+   dnl Default to "generic"
+   if test x$enable_clocale_flag = xno; then
+     case x${target_os} in
+-      xlinux* | xgnu*)
++      xlinux* | xgnu* | xfreebsd*-gnu*)
+ 	AC_EGREP_CPP([_GLIBCPP_ok], [
+         #include <features.h>
+         #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) 
+@@ -1306,7 +1306,7 @@
+       # compile most of libio for linux systems.
+       if test x$has_libio = x"yes"; then
+         case "$target" in
+-          *-*-linux*)
++          *-*-linux* | *-*-freebsd*-gnu*)
+               AC_MSG_CHECKING([for glibc version >= 2.2])
+               AC_EGREP_CPP([ok], [
+             #include <features.h>
+diff -urN src/libstdc++-v3/aclocal.m4 newsrc/libstdc++-v3/aclocal.m4
+--- src/libstdc++-v3/aclocal.m4	2002-09-13 01:24:39.000000000 -0400
++++ newsrc/libstdc++-v3/aclocal.m4	2002-10-03 13:23:34.000000000 -0400
+@@ -1130,7 +1130,7 @@
+   dnl Default to "generic"
+   if test x$enable_clocale_flag = xno; then
+     case x${target_os} in
+-      xlinux* | xgnu*)
++      xlinux* | xgnu* | xfreebsd*-gnu*)
+ 	AC_EGREP_CPP([_GLIBCPP_ok], [
+         #include <features.h>
+         #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) 
+@@ -1318,7 +1318,7 @@
+       # compile most of libio for linux systems.
+       if test x$has_libio = x"yes"; then
+         case "$target" in
+-          *-*-linux*)
++          *-*-linux* | *-*-freebsd*-gnu*)
+               AC_MSG_CHECKING([for glibc version >= 2.2])
+               AC_EGREP_CPP([ok], [
+             #include <features.h>
+diff -urN src/libstdc++-v3/config/locale/gnu/c_locale.cc newsrc/libstdc++-v3/config/locale/gnu/c_locale.cc
+--- src/libstdc++-v3/config/locale/gnu/c_locale.cc	2002-09-05 17:37:09.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/c_locale.cc	2002-10-03 13:23:34.000000000 -0400
+@@ -40,6 +40,17 @@
+ 
+ namespace std 
+ {
++  extern "C" __typeof (strtol_l) __strtol_l;
++  extern "C" __typeof (strtoul_l) __strtoul_l;
++  extern "C" __typeof (strtoll_l) __strtoll_l;
++  extern "C" __typeof (strtoull_l) __strtoull_l;
++  extern "C" __typeof (strtof_l) __strtof_l;
++  extern "C" __typeof (strtod_l) __strtod_l;
++  extern "C" __typeof (strtold_l) __strtold_l;
++  extern "C" __typeof (newlocale) __newlocale;
++  extern "C" __typeof (freelocale) __freelocale;
++  extern "C" __typeof (duplocale) __duplocale;
++
+   template<>
+     void
+     __convert_to_v(const char* __s, long& __v, ios_base::iostate& __err, 
+diff -urN src/libstdc++-v3/config/locale/gnu/collate_members.cc newsrc/libstdc++-v3/config/locale/gnu/collate_members.cc
+--- src/libstdc++-v3/config/locale/gnu/collate_members.cc	2002-09-05 17:37:09.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/collate_members.cc	2002-10-03 13:23:34.000000000 -0400
+@@ -38,6 +38,11 @@
+ 
+ namespace std
+ {
++  extern "C" __typeof (strcoll_l) __strcoll_l;
++  extern "C" __typeof (strxfrm_l) __strxfrm_l;
++  extern "C" __typeof (wcscoll_l) __wcscoll_l;
++  extern "C" __typeof (wcsxfrm_l) __wcsxfrm_l;
++
+   // These are basically extensions to char_traits, and perhaps should
+   // be put there instead of here.
+   template<>
+diff -urN src/libstdc++-v3/config/locale/gnu/ctype_members.cc newsrc/libstdc++-v3/config/locale/gnu/ctype_members.cc
+--- src/libstdc++-v3/config/locale/gnu/ctype_members.cc	2002-09-05 17:37:09.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/ctype_members.cc	2002-10-03 13:23:34.000000000 -0400
+@@ -38,6 +38,11 @@
+ 
+ namespace std
+ {
++  extern "C" __typeof (wctype_l) __wctype_l;
++  extern "C" __typeof (towupper_l) __towupper_l;
++  extern "C" __typeof (towlower_l) __towlower_l;
++  extern "C" __typeof (iswctype_l) __iswctype_l;
++
+   // NB: The other ctype<char> specializations are in src/locale.cc and
+   // various /config/os/* files.
+   template<>
+diff -urN src/libstdc++-v3/config/locale/gnu/messages_members.cc newsrc/libstdc++-v3/config/locale/gnu/messages_members.cc
+--- src/libstdc++-v3/config/locale/gnu/messages_members.cc	2002-09-05 17:37:09.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/messages_members.cc	2002-10-03 13:23:34.000000000 -0400
+@@ -38,6 +38,7 @@
+ 
+ namespace std
+ {
++  extern "C" __typeof (uselocale) __uselocale;
+   // Specializations.
+   template<>
+     string
+diff -urN src/libstdc++-v3/config/locale/gnu/messages_members.h newsrc/libstdc++-v3/config/locale/gnu/messages_members.h
+--- src/libstdc++-v3/config/locale/gnu/messages_members.h	2002-09-05 17:37:09.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/messages_members.h	2002-10-03 13:23:34.000000000 -0400
+@@ -33,6 +33,8 @@
+ 
+ // Written by Benjamin Kosnik <bkoz@redhat.com>
+ 
++  extern "C" __typeof (uselocale) __uselocale;
++
+   // Non-virtual member functions.
+   template<typename _CharT>
+     typename messages<_CharT>::catalog 
+diff -urN src/libstdc++-v3/config/locale/gnu/monetary_members.cc newsrc/libstdc++-v3/config/locale/gnu/monetary_members.cc
+--- src/libstdc++-v3/config/locale/gnu/monetary_members.cc	2002-09-05 17:37:09.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/monetary_members.cc	2002-10-03 13:23:34.000000000 -0400
+@@ -38,6 +38,8 @@
+ 
+ namespace std
+ {
++  extern "C" __typeof (nl_langinfo_l) __nl_langinfo_l;
++
+   // Construct and return valid pattern consisting of some combination of:
+   // space none symbol sign value
+   money_base::pattern
+diff -urN src/libstdc++-v3/config/locale/gnu/numeric_members.cc newsrc/libstdc++-v3/config/locale/gnu/numeric_members.cc
+--- src/libstdc++-v3/config/locale/gnu/numeric_members.cc	2002-09-05 17:37:10.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/numeric_members.cc	2002-10-03 13:23:34.000000000 -0400
+@@ -38,6 +38,8 @@
+ 
+ namespace std
+ {
++  extern "C" __typeof (nl_langinfo_l) __nl_langinfo_l;
++
+   template<> 
+     void
+     numpunct<char>::_M_initialize_numpunct(__c_locale __cloc)
+diff -urN src/libstdc++-v3/config/locale/gnu/time_members.cc newsrc/libstdc++-v3/config/locale/gnu/time_members.cc
+--- src/libstdc++-v3/config/locale/gnu/time_members.cc	2002-09-05 17:37:10.000000000 -0400
++++ newsrc/libstdc++-v3/config/locale/gnu/time_members.cc	2002-10-03 13:23:34.000000000 -0400
+@@ -39,6 +39,10 @@
+ 
+ namespace std
+ {
++  extern "C" __typeof (strftime_l) __strftime_l;
++  extern "C" __typeof (wcsftime_l) __wcsftime_l;
++  extern "C" __typeof (nl_langinfo_l) __nl_langinfo_l;
++
+   template<>
+     __timepunct<char>::~__timepunct()
+     {
+diff -urN src/libstdc++-v3/configure newsrc/libstdc++-v3/configure
+--- src/libstdc++-v3/configure	2002-09-13 01:25:17.000000000 -0400
++++ newsrc/libstdc++-v3/configure	2002-10-03 13:23:34.000000000 -0400
+@@ -2793,7 +2793,7 @@
+       # compile most of libio for linux systems.
+       if test x$has_libio = x"yes"; then
+         case "$target" in
+-          *-*-linux*)
++          *-*-linux* | *-*-freebsd*-gnu*)
+               echo $ac_n "checking for glibc version >= 2.2""... $ac_c" 1>&6
+ echo "configure:2799: checking for glibc version >= 2.2" >&5
+               cat > conftest.$ac_ext <<EOF
+@@ -2927,7 +2927,7 @@
+ 
+       if test x$enable_clocale_flag = xno; then
+     case x${target_os} in
+-      xlinux* | xgnu*)
++      xlinux* | xgnu* | xfreebsd*-gnu*)
+ 	cat > conftest.$ac_ext <<EOF
+ #line 2933 "configure"
+ #include "confdefs.h"
+diff -urN src/libstdc++-v3/configure.target newsrc/libstdc++-v3/configure.target
+--- src/libstdc++-v3/configure.target	2002-09-06 17:36:37.000000000 -0400
++++ newsrc/libstdc++-v3/configure.target	2002-10-03 13:23:34.000000000 -0400
+@@ -80,6 +80,9 @@
+     os_include_dir="config/os/aix"
+     OPT_LDFLAGS="-Wl,-G"
+     ;;
++  freebsd*-gnu*)
++    os_include_dir="config/os/gnu-linux"
++    ;;
+   bsd* | freebsd* )
+     os_include_dir="config/os/bsd/freebsd"
+     ;;
+diff -urN src/ltconfig newsrc/ltconfig
+--- src/ltconfig	2001-10-02 15:40:10.000000000 -0400
++++ newsrc/ltconfig	2002-10-03 13:23:34.000000000 -0400
+@@ -1115,6 +1115,20 @@
+   dynamic_linker=no
+   ;;
+ 
++freebsd*-gnu*)
++  version_type=linux
++  need_lib_prefix=no
++  need_version=no
++  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
++  soname_spec='${libname}${release}.so$major'
++  shlibpath_var=LD_LIBRARY_PATH
++  shlibpath_overrides_runpath=no
++  hardcode_into_libs=yes
++  dynamic_linker='GNU ld.so'
++  # Don't assume a particular installation location.
++  sys_lib_search_path_spec=""
++  ;;
++
+ freebsd*)
+   objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
+   version_type=freebsd-$objformat
diff -urN gcc-3.2-3.2.1ds2/debian/rules.conf gcc-3.2-3.2.1ds2-bak/debian/rules.conf
--- gcc-3.2-3.2.1ds2/debian/rules.conf	2002-10-08 20:18:19.000000000 -0400
+++ gcc-3.2-3.2.1ds2-bak/debian/rules.conf	2002-10-08 20:26:34.000000000 -0400
@@ -77,10 +77,14 @@
   ifeq ($(DEB_HOST_GNU_SYSTEM),gnu)
     ctrl_flags += -DLIBC_DEV=libc0.3-dev
   else
-    ctrl_flags += -DLIBC_DEV="libc6-dev (>= $(libc_ver))"
+    ifeq ($(DEB_HOST_GNU_SYSTEM),freebsd)
+      ctrl_flags += -DLIBC_DEV=libc1-dev
+    else
+      ctrl_flags += -DLIBC_DEV="libc6-dev (>= $(libc_ver))"
+    endif
   endif
 endif
-ctrl_flags += -DLIBC_BUILD_DEP="libc6.1-dev (>= $(libc_ver)) | libc6-dev (>= $(libc_ver)) | libc0.3-dev"
+ctrl_flags += -DLIBC_BUILD_DEP="libc6.1-dev (>= $(libc_ver)) | libc6-dev (>= $(libc_ver)) | libc0.3-dev | libc1-dev"
 
 ifneq ($(GCC_TARGET),)
   ctrl_flags += \
diff -urN gcc-3.2-3.2.1ds2/debian/rules.defs gcc-3.2-3.2.1ds2-bak/debian/rules.defs
--- gcc-3.2-3.2.1ds2/debian/rules.defs	2002-10-08 20:18:19.000000000 -0400
+++ gcc-3.2-3.2.1ds2-bak/debian/rules.defs	2002-10-08 20:28:22.000000000 -0400
@@ -109,7 +109,7 @@
 # Java --------------------
 # java converted for V3 C++ ABI for some archs
 with_java := yes
-no_java_archs := hppa hurd-i386 mips mipsel
+no_java_archs := hppa hurd-i386 mips mipsel freebsd-i386
 ifneq ($(DEB_HOST_ARCH),i386)
   ifeq ($(DEB_HOST_ARCH), $(findstring $(DEB_HOST_ARCH),$(no_java_archs)))
     with_java := disabled for architecure $(DEB_HOST_ARCH)
@@ -132,7 +132,7 @@
 # libffi -------------------
 ifeq ($(with_31pkgs),yes)
   with_ffi := yes
-  no_ffi_archs := hppa mips mipsel hurd-i386
+  no_ffi_archs := hppa mips mipsel hurd-i386 freebsd-i386
   ifneq ($(with_java),yes)
     ifeq ($(DEB_HOST_ARCH), $(findstring $(DEB_HOST_ARCH),$(no_ffi_archs)))
       with_ffi := disabled for architecure $(DEB_HOST_ARCH)
@@ -196,7 +196,7 @@
 # the ObjC runtime with garbage collection enabled needs the Boehm GC
 with_objc_gc := yes
 # disable ObjC garbage collection library (needs libgc6)
-libgc6_no_archs := avr
+libgc6_no_archs := avr freebsd-i386
 ifneq ($(DEB_HOST_ARCH),i386)
   ifeq ($(DEB_HOST_ARCH),$(findstring $(DEB_HOST_ARCH),$(libgc6_no_archs)))
     with_objc_gc := disabled for architecture $(DEB_HOST_ARCH)
@@ -217,7 +217,7 @@
 # Ada --------------------
 with_ada := yes
 with_shared_adalib := no
-ada_no_archs := arm hurd-i386 m68k
+ada_no_archs := arm hurd-i386 m68k freebsd-i386
 ifneq ($(DEB_HOST_ARCH),i386)
   ifeq ($(DEB_HOST_ARCH), $(findstring $(DEB_HOST_ARCH),$(ada_no_archs)))
     with_ada := disabled for architecure $(DEB_HOST_ARCH)
diff -urN gcc-3.2-3.2.1ds2/debian/rules.patch gcc-3.2-3.2.1ds2-bak/debian/rules.patch
--- gcc-3.2-3.2.1ds2/debian/rules.patch	2002-10-08 20:18:19.000000000 -0400
+++ gcc-3.2-3.2.1ds2-bak/debian/rules.patch	2002-10-03 13:47:03.000000000 -0400
@@ -78,6 +78,10 @@
   debian_patches += sparc64-build
 endif
 
+ifeq ($(DEB_HOST_ARCH),freebsd-i386)
+  debian_patches += freebsd-gnu
+endif
+
 debian_patches += reporting # applied after gcc-cvs-updates
 
 patch: $(patch_stamp)

--CE+1k2dSO48ffgeK--

---------------------------------------
Received: (at 163883-close) by bugs.debian.org; 20 Oct 2002 13:08:07 +0000
>From katie@auric.debian.org Sun Oct 20 08:08:06 2002
Return-path: <katie@auric.debian.org>
Received: from auric.debian.org [206.246.226.45] (mail)
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 183FoL-0000Sl-00; Sun, 20 Oct 2002 08:08:06 -0500
Received: from katie by auric.debian.org with local (Exim 3.35 1 (Debian))
	id 183Fiw-0005aJ-00; Sun, 20 Oct 2002 09:02:30 -0400
From: Matthias Klose <doko@debian.org>
To: 163883-close@bugs.debian.org
X-Katie: $Revision: 1.26 $
Subject: Bug#163883: fixed in gcc-3.2 1:3.2.1ds3-0pre4
Message-Id: <E183Fiw-0005aJ-00@auric.debian.org>
Sender: Archive Administrator <katie@auric.debian.org>
Date: Sun, 20 Oct 2002 09:02:30 -0400
Delivered-To: 163883-close@bugs.debian.org
X-Spam-Status: No, hits=-1.8 required=5.0
	tests=LINES_OF_YELLING,PGP_SIGNATURE,SPAM_PHRASE_00_01,
	      SUPERLONG_LINE
	version=2.41
X-Spam-Level: 

We believe that the bug you reported is fixed in the latest version of
gcc-3.2, which is due to be installed in the Debian FTP archive:

cpp-3.2-doc_3.2.1-0pre4_all.deb
  to pool/main/g/gcc-3.2/cpp-3.2-doc_3.2.1-0pre4_all.deb
cpp-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/cpp-3.2_3.2.1-0pre4_i386.deb
fastjar_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/fastjar_3.2.1-0pre4_i386.deb
fixincludes_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/fixincludes_3.2.1-0pre4_i386.deb
g++-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/g++-3.2_3.2.1-0pre4_i386.deb
g77-3.2-doc_3.2.1-0pre4_all.deb
  to pool/main/g/gcc-3.2/g77-3.2-doc_3.2.1-0pre4_all.deb
g77-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/g77-3.2_3.2.1-0pre4_i386.deb
gcc-3.2-base_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/gcc-3.2-base_3.2.1-0pre4_i386.deb
gcc-3.2-doc_3.2.1-0pre4_all.deb
  to pool/main/g/gcc-3.2/gcc-3.2-doc_3.2.1-0pre4_all.deb
gcc-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/gcc-3.2_3.2.1-0pre4_i386.deb
gcc-3.2_3.2.1ds3-0pre4.diff.gz
  to pool/main/g/gcc-3.2/gcc-3.2_3.2.1ds3-0pre4.diff.gz
gcc-3.2_3.2.1ds3-0pre4.dsc
  to pool/main/g/gcc-3.2/gcc-3.2_3.2.1ds3-0pre4.dsc
gcc-3.2_3.2.1ds3.orig.tar.gz
  to pool/main/g/gcc-3.2/gcc-3.2_3.2.1ds3.orig.tar.gz
gcj-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/gcj-3.2_3.2.1-0pre4_i386.deb
gij-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/gij-3.2_3.2.1-0pre4_i386.deb
gnat-3.2-doc_3.2.1-0pre4_all.deb
  to pool/main/g/gcc-3.2/gnat-3.2-doc_3.2.1-0pre4_all.deb
gnat-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/gnat-3.2_3.2.1-0pre4_i386.deb
gobjc-3.2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/gobjc-3.2_3.2.1-0pre4_i386.deb
libffi2-dev_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libffi2-dev_3.2.1-0pre4_i386.deb
libffi2_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libffi2_3.2.1-0pre4_i386.deb
libg2c0_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libg2c0_3.2.1-0pre4_i386.deb
libgcc1_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libgcc1_3.2.1-0pre4_i386.deb
libgcj-common_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libgcj-common_3.2.1-0pre4_i386.deb
libgcj3-dev_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libgcj3-dev_3.2.1-0pre4_i386.deb
libgcj3_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libgcj3_3.2.1-0pre4_i386.deb
libgnat3.15a_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libgnat3.15a_3.2.1-0pre4_i386.deb
libobjc1_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libobjc1_3.2.1-0pre4_i386.deb
libstdc++5-dbg_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libstdc++5-dbg_3.2.1-0pre4_i386.deb
libstdc++5-dev_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libstdc++5-dev_3.2.1-0pre4_i386.deb
libstdc++5-doc_3.2.1-0pre4_all.deb
  to pool/main/g/gcc-3.2/libstdc++5-doc_3.2.1-0pre4_all.deb
libstdc++5-pic_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libstdc++5-pic_3.2.1-0pre4_i386.deb
libstdc++5_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/libstdc++5_3.2.1-0pre4_i386.deb
protoize_3.2.1-0pre4_i386.deb
  to pool/main/g/gcc-3.2/protoize_3.2.1-0pre4_i386.deb



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 163883@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Matthias Klose <doko@debian.org> (supplier of updated gcc-3.2 package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----

Format: 1.7
Date: Sun, 20 Oct 2002 10:52:49 +0200
Source: gcc-3.2
Binary: libgcj3 gcc-3.2-base libffi2-dev libstdc++5-dev cpp-3.2-doc gcc-3.2-soft-float libgcj3-dev libobjc1 libstdc++5-doc gcj-3.2 libgcc1 libgcj-common libgnat3.15a libstdc++5 protoize g77-3.2-doc fastjar gcc-3.2-doc libstdc++5-dbg gcc-3.2-nof gobjc-3.2 fixincludes libg2c0 g++-3.2 gnat-3.2-doc cpp-3.2 gij-3.2 gcc-3.2 libffi2 gnat-3.2 libstdc++5-pic g77-3.2
Architecture: source i386 all
Version: 1:3.2.1ds3-0pre4
Distribution: unstable
Urgency: high
Maintainer: Debian GCC maintainers <debian-gcc@lists.debian.org>
Changed-By: Matthias Klose <doko@debian.org>
Description: 
 cpp-3.2    - The GNU C preprocessor.
 cpp-3.2-doc - Documentation for the GNU C preprocessor (cpp).
 fastjar    - Jar creation utility
 fixincludes - Fix non-ANSI header files
 g++-3.2    - The GNU C++ compiler.
 g77-3.2    - The GNU Fortran 77 compiler.
 g77-3.2-doc - Documentation for the GNU Fortran compiler (g77).
 gcc-3.2    - The GNU C compiler.
 gcc-3.2-base - The GNU Compiler Collection (base package).
 gcc-3.2-doc - Documentation for the GNU compilers (gcc, gobjc, g++).
 gcj-3.2    - The GNU compiler for Java(TM).
 gij-3.2    - The GNU Java bytecode interpreter.
 gnat-3.2   - The GNU Ada compiler.
 gnat-3.2-doc - Documentation for the GNU Ada compiler (gnat).
 gobjc-3.2  - The GNU Objective-C compiler.
 libffi2    - Foreign Function Interface library runtime
 libffi2-dev - Foreign Function Interface library development
 libg2c0    - Runtime library for GNU Fortran 77 applications.
 libgcc1    - GCC support library.
 libgcj-common - Java runtime library (common files)
 libgcj3    - Java runtime library for use with gcj
 libgcj3-dev - Java development headers and static library for use with gcj
 libgnat3.15a - Runtime library for GNU Ada applications.
 libobjc1   - Runtime library for GNU Objective-C applications.
 libstdc++5 - The GNU stdc++ library version 3
 libstdc++5-dbg - The GNU stdc++ library version 3 (debugging files)
 libstdc++5-dev - The GNU stdc++ library version 3 (development files)
 libstdc++5-doc - The GNU stdc++ library version 3 (documentation files)
 libstdc++5-pic - The GNU stdc++ library version 3 (shared library subset kit)
 protoize   - Create/remove ANSI prototypes from C code
Closes: 157416 159650 162843 163172 163422 163883 164009
Changes: 
 gcc-3.2 (1:3.2.1ds3-0pre4) unstable; urgency=high
 .
   * gcc-3.2.1 snapshot (CVS 20021020).
     - Expansion of _Pragma within macros fixed (closes: #157416).
   * FTBS: With the switch to bison-1.50 (and 1.75), gcc-3.2 fails to build from
     source on Debian unstable systems. This is fixed in gcc HEAD, but not on
     the current release branch.
     HELP NEEDED:
     - check what is missing from the patches in debian/patches/bison.dpatch.
       This is a backport of the bison related patches, but showing regressions
       in the gcc testsuite, so it cannot be applied.
     - build gcc using byacc (bootstrap currently fails using byacc).
     - build bison-1.35 in it's own package (the current 1.35-3 package fails
       to build form source).
     - and finally ask upstream to backport the patch to the branch. It's not
       helpful not beeing able to follow the stable branch. Maybe we should
       just switch to gcc HEAD as BSD does ...
     As a terrible workaround, build the sources from CVS first on a machine,
     with bison-1.35 installed, then package the tarball, so the bison
     generated files are not rebuilt.
 .
   * re-add lost patch: configure with --enable-__cxa_atexit (closes: #163422),
     Therefore urgency high.
   * gcj-wrapper, gij-wrapper: Accept names starting with `.' (closes: #163172,
     #164009).
   * Point g++ manpage to correct g++ version (closes: #162843).
   * Support for i386-freebsd-gnu (closes: #163883).
   * s390-java.dpatch replaced with backport from cvs head (Gerhard Tonn).
   * Disable the testsuite run on the Hurd (closes: #159650).
   * s390-loop.dpatch added, fixes runtime problem (Gerhard Tonn).
   * debian/patches/bison.dpatch: Backport for bison-1.75 compatibility.
     Don't use it due to regressions.
   * debian/patches/backport-java-6865.dpatch: Directly applied in the
     included tarball because of bison problems.
   * Make fixincludes priority optional, so linda can depend on it.
   * Tighten binutils dependency.
Files: 
 6a21750559a70363f16f714a41c374a4 1827 devel standard gcc-3.2_3.2.1ds3-0pre4.dsc
 ec4ca36891c3e1df2a92117370fc5e9d 19903168 devel standard gcc-3.2_3.2.1ds3.orig.tar.gz
 17b1151a039594de725c61745106a5d3 1856522 devel standard gcc-3.2_3.2.1ds3-0pre4.diff.gz
 291a23bfd7391df724ba31e864e72ca6 84402 doc optional cpp-3.2-doc_3.2.1-0pre4_all.deb
 3156bf2162da212f56907a0d2912f527 2179094 doc optional libstdc++5-doc_3.2.1-0pre4_all.deb
 94527335747b1f71d6e6d1fc7cfe55fa 309412 doc optional g77-3.2-doc_3.2.1-0pre4_all.deb
 e47decd099a1c532427ae1ee6b4e61e9 346716 doc optional gnat-3.2-doc_3.2.1-0pre4_all.deb
 58d16b01a26b8a40e1a0ad66afdb67bf 625138 doc optional gcc-3.2-doc_3.2.1-0pre4_all.deb
 b5ef467603983ba520e1eb258b412088 120364 devel standard gcc-3.2-base_3.2.1-0pre4_i386.deb
 81f0513a8a3a105b2200d679a747f371 50712 libs standard libgcc1_3.2.1-0pre4_i386.deb
 87bbd1832de7e96f07d207487b540c71 119802 interpreters standard cpp-3.2_3.2.1-0pre4_i386.deb
 b1f73816e7c3d913e69fe974a7f58870 22732 devel optional protoize_3.2.1-0pre4_i386.deb
 38081e3d1efb5442d2eeb82a76e0fdbf 46782 devel extra fixincludes_3.2.1-0pre4_i386.deb
 9bf4b879bb879cf581e93c64e84743d0 1293064 devel optional gobjc-3.2_3.2.1-0pre4_i386.deb
 58593d277d6bd77de8e0d178c75535cf 106262 libs optional libobjc1_3.2.1-0pre4_i386.deb
 417ec9d26f674a59ca1bc154fdec78d5 1496284 devel optional gcj-3.2_3.2.1-0pre4_i386.deb
 563ee54e9929fe6fa2e4f0fd118d9ebb 11942 devel optional gij-3.2_3.2.1-0pre4_i386.deb
 38cae1f1fc74fecabbeb59c4c5d2ff48 37296 libs optional libgcj-common_3.2.1-0pre4_i386.deb
 4009a60a7c5466afcd5e79630ba5a956 2680980 libs optional libgcj3_3.2.1-0pre4_i386.deb
 a683b494310feaf90750ad5ad7618d6d 3014700 devel optional libgcj3-dev_3.2.1-0pre4_i386.deb
 119fbfcdf99de04cc21ec4c18c604277 79962 devel extra fastjar_3.2.1-0pre4_i386.deb
 5e09bf93998025b626d77dd371345bb4 52984 libs optional libffi2_3.2.1-0pre4_i386.deb
 ec0a1f8c54c705a0fc65ef64f6111023 10766 devel optional libffi2-dev_3.2.1-0pre4_i386.deb
 55e7b5a0dd180cb17c0ae188a6374c46 1541358 devel optional g++-3.2_3.2.1-0pre4_i386.deb
 529e2497a5d055c1b48dd83a72d9ab6b 250506 base standard libstdc++5_3.2.1-0pre4_i386.deb
 9f6b276dfd3485970ccef8d3ec35a674 674042 devel optional libstdc++5-dev_3.2.1-0pre4_i386.deb
 67ad5d99abd2ba20e823b512083b3b77 305614 devel extra libstdc++5-pic_3.2.1-0pre4_i386.deb
 0e749ef556b3a0eee83274172acc7567 1509100 devel extra libstdc++5-dbg_3.2.1-0pre4_i386.deb
 89eb04bb5b0e8635ee58e2448754e5c9 1426224 devel optional g77-3.2_3.2.1-0pre4_i386.deb
 c3072a59d164024902e08f150ff101b7 47558 libs optional libg2c0_3.2.1-0pre4_i386.deb
 3dfdf95c9293bd2a6903918b6250c362 5402704 devel optional gnat-3.2_3.2.1-0pre4_i386.deb
 79768c8505c39891b97a54f537cac127 37148 libs optional libgnat3.15a_3.2.1-0pre4_i386.deb
 63f712a95dcc4338eae8ae23f521f191 2250544 devel standard gcc-3.2_3.2.1-0pre4_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: noconv
Comment: Requires PGP version 2.6 or later.

iQEVAwUBPbKfyQuDzMCIcnEhAQGcLgf/e5IcpexGskfrwVMQd9H0f01MVOUyPDgQ
wfa5Lib39LfXaDdkKuBKGY1RQbSmNuv/bMkiLgawGhMUe9RhzCIq7EPPaP7l5Jkh
C7WOiw5QugasR+NdMgm079pQEJx/ONvoBIUXT1xSq8j6z32dDNn3x5ECUrtGiQ2J
CbfrU+0JUMx2twrbjbqzQAXIgbek4gCPj4ZYNbZ09NzkJWA0OR9z+MagCmH+R8JT
5dkirxEP4wA+aI+YigwEZ9wfPFRRtv42RgWKiYWr51wDmwfgJlj5LeQ8ywDUDzW+
qNZzWE7g++IYxCoH38sPODzqEZlnaxcJ/a6FRWrB7+cKMnWwPvM9MA==
=mk4D
-----END PGP SIGNATURE-----



Reply to: