Quoting Alexander von Gluck <kallisti5@xxxxxxxxxxx>:
Quoting François Revol <revol@xxxxxxx>:Do the build tools in the svn trunk have to stay virgin? I am trying to get Haiku PPC to compile on GCC 4 and and finding some needed patches. (mostly -Werror removal stuff)Hmm depends if you have the latest gcc build or an older version, it was updated some weeks ago... If not something like this will work around it: Index: build/jam/BuildSetup =================================================================== --- build/jam/BuildSetup (révision 29758) +++ build/jam/BuildSetup (copie de travail) @@ -990,10 +990,10 @@ } else { # -Wuninitialized gives too many false positives. rule EnableWerror dirTokens : scope { - AppendToConfigVar CCFLAGS : HAIKU_TOP $(dirTokens) - : -Werror -Wno-error=uninitialized : $(scope) ; - AppendToConfigVar C++FLAGS : HAIKU_TOP $(dirTokens) - : -Werror -Wno-error=uninitialized : $(scope) ; +# AppendToConfigVar CCFLAGS : HAIKU_TOP $(dirTokens) +# : -Werror -Wno-error=uninitialized : $(scope) ; +# AppendToConfigVar C++FLAGS : HAIKU_TOP $(dirTokens) +# : -Werror -Wno-error=uninitialized : $(scope) ; } } François. -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.I was able to get it fixed with a little less. alex@eris:~/haiku/buildtools/binutils/gas$ svn diff Index: configure =================================================================== --- configure (revision 29763) +++ configure (working copy) @@ -10626,7 +10626,7 @@ NO_WERROR= if test "${ERROR_ON_WARNING}" = yes ; then - GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror" + GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS" NO_WERROR="-Wno-error" fi buildtools gcc4 ppc compiled successfully on x86_64 Linux after that :)I noticed that build/scripts/build_cross_tools does the following for binutils:CFLAGS="-O2" CXXFLAGS="-O2" $buildToolsDir/binutils/configure \ --prefix=$installDir --target=i586-pc-haiku --disable-nls \ --enable-shared=yes --disable-werror || exit 1 but build/scripts/build_cross_tools_gcc4 does this: CFLAGS="-O2" CXXFLAGS="-O2" $binutilsSourceDir/configure \ --prefix=$installDir --target=$haikuMachine --disable-nls \ --disable-shared --disable-multilib || exit 1Maybe build_cross_tools_gcc4 should have --disable-werror like build_cross_tools does? (i've yet to test this.. but it's on my todo list)Thanks! Alexander von Gluck IV PGP ID: 0x2414F7DC http://unixzen.com"The way to find what the mainstream will do tomorrow is to associate with the lunatic fringe today." -- 1995, Jean-Louis Gassée-- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.
Ok, the following diff does work for me to fix binutils/gas compile for ppc target on x86_64 Linux. This patch is also a lot more correct.
Any objections to it's inclusion? Maybe someone to include it as I have no svn commit access? :) In Haiku source tree: Index: build/scripts/build_cross_tools_gcc4 =================================================================== --- build/scripts/build_cross_tools_gcc4 (revision 29767) +++ build/scripts/build_cross_tools_gcc4 (working copy) @@ -89,7 +89,7 @@ cd $binutilsObjDir CFLAGS="-O2" CXXFLAGS="-O2" $binutilsSourceDir/configure \ --prefix=$installDir --target=$haikuMachine --disable-nls \ - --disable-shared --disable-multilib || exit 1 + --disable-shared --disable-multilib --disable-werror || exit 1 $MAKE || exit 1 $MAKE install || exit 1 Thanks! Alexander von Gluck IV PGP ID: 0x2414F7DC http://unixzen.com"The way to find what the mainstream will do tomorrow is to associate with the lunatic fringe today." -- 1995, Jean-Louis Gassée
-- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.