--- On Tue, 10/7/08, Peter Jeremy wrote:

> On 2008-Oct-06 06:19:34 -0700, Unga
> wrote:
> >The FreeBSD stable comes with gcc-4.2.1 but the sources

> are scattered
> >over the /usr/src, therefore, I find it difficult to

> re-create the
> >gcc-4.2.1 to its original directory layout to make a

> patch.
>
> The original sources for gcc can be found in
> /usr/src/contrib/gcc -
> note that this is not a complete gcc 4.2.1 distribution as
> parts of
> gcc that are not relevant for FreeBSD have been deleted.
> Refer to the
> FREEBSD-* files for details.
>


Here is how I did that:

1. Unpack original GCC sources
tar -xjf gcc-4.2.1.tar.bz2
mv -v gcc-4.2.1 gcc-4.2.1.orig

2. Bring under one roof FreeBSD-modified GCC sources
mkdir -pv gcc-4.2.1
cd gcc-4.2.1

cp -R /usr/src/contrib/gcc .
cp -R /usr/src/contrib/gcclibs/ .
cp -R /usr/src/contrib/libobjc .
cp -R /usr/src/contrib/libstdc++ libstdc++-v3

cd ..

3. Make a patch
diff -aur gcc-4.2.1.orig gcc-4.2.1 >& FreeBSD-gcc.patch


Now the question is have I collected all the GCC sources from FreeBSD source tree? Have I missed any?


Now I unpacked the gcc-4.2.1.tar.bz2 into some other directory and applied this FreeBSD-gcc.patch. Ran configure and compiled. It develop following error:
.../../gcc-4.2.1/gcc/c-format.c:1780: error: 'flag_format_extensions' undeclared (first use in this function)
.../../gcc-4.2.1/gcc/c-format.c:1780: error: (Each undeclared identifier is reported only once
.../../gcc-4.2.1/gcc/c-format.c:1780: error: for each function it appears in.)
gmake[2]: *** [c-format.o] Error 1

So where is the flag_format_extensions is declared in FreeBSD?

Best regards
Unga




_______________________________________________
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/lis...freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org"