When building the gcc 4 cross tools we now configure for machine
i586-pc-haiku. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15345 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -72,13 +72,13 @@ rm -rf $installDir $objDir
|
|||||||
|
|
||||||
mkdir -p $installDir $objDir $binutilsObjDir $gccObjDir $tmpIncludeDir \
|
mkdir -p $installDir $objDir $binutilsObjDir $gccObjDir $tmpIncludeDir \
|
||||||
$tmpLibDir || exit 1
|
$tmpLibDir || exit 1
|
||||||
mkdir -p $installDir/lib/gcc/i586-pc-beos/$gccVersion
|
mkdir -p $installDir/lib/gcc/i586-pc-haiku/$gccVersion
|
||||||
|
|
||||||
# build binutils
|
# build binutils
|
||||||
cd $binutilsObjDir
|
cd $binutilsObjDir
|
||||||
CFLAGS="-O2" CXXFLAGS="-O2" $binutilsSourceDir/configure \
|
CFLAGS="-O2" CXXFLAGS="-O2" $binutilsSourceDir/configure \
|
||||||
--prefix=$installDir --target=i586-pc-beos --disable-nls \
|
--prefix=$installDir --target=i586-pc-haiku --disable-nls \
|
||||||
--enable-shared=yes || exit 1
|
--disable-shared || exit 1
|
||||||
$make || exit 1
|
$make || exit 1
|
||||||
$make install || exit 1
|
$make install || exit 1
|
||||||
|
|
||||||
@@ -108,7 +108,7 @@ copy_headers $haikuSourceDir/headers/posix $tmpIncludeDir/posix
|
|||||||
# configure gcc
|
# configure gcc
|
||||||
cd $gccObjDir
|
cd $gccObjDir
|
||||||
CFLAGS="-O2" CXXFLAGS="-O2" $gccSourceDir/configure --prefix=$installDir \
|
CFLAGS="-O2" CXXFLAGS="-O2" $gccSourceDir/configure --prefix=$installDir \
|
||||||
--target=i586-pc-beos --disable-nls --enable-shared=yes \
|
--target=i586-pc-haiku --disable-nls --disable-shared \
|
||||||
--enable-languages=c,c++ --with-headers=$tmpIncludeDir \
|
--enable-languages=c,c++ --with-headers=$tmpIncludeDir \
|
||||||
--with-libs=$tmpLibDir || exit 1
|
--with-libs=$tmpLibDir || exit 1
|
||||||
|
|
||||||
@@ -128,7 +128,7 @@ $make install || {
|
|||||||
|
|
||||||
# remove the system headers from the installation dir
|
# remove the system headers from the installation dir
|
||||||
# Only the ones from the source tree should be used.
|
# Only the ones from the source tree should be used.
|
||||||
sysIncludeDir=$installDir/i586-pc-beos/sys-include
|
sysIncludeDir=$installDir/i586-pc-haiku/sys-include
|
||||||
rm -rf $sysIncludeDir/be $sysIncludeDir/posix
|
rm -rf $sysIncludeDir/be $sysIncludeDir/posix
|
||||||
|
|
||||||
# remove the objects dir
|
# remove the objects dir
|
||||||
|
|||||||
@@ -164,6 +164,9 @@ cd $currentDir
|
|||||||
#
|
#
|
||||||
platform=`uname`
|
platform=`uname`
|
||||||
haikuGCCVersion=
|
haikuGCCVersion=
|
||||||
|
haikuGCCMachine=i586-pc-beos
|
||||||
|
# TODO: Should be specifiable via parameters, when configure builds the
|
||||||
|
# cross tools.
|
||||||
haikuStaticLibStdCxx=
|
haikuStaticLibStdCxx=
|
||||||
haikuSharedLibStdCxx=
|
haikuSharedLibStdCxx=
|
||||||
haikuStaticLibSupCxx=
|
haikuStaticLibSupCxx=
|
||||||
@@ -202,6 +205,7 @@ while [ $# \> 0 ] ; do
|
|||||||
--build-cross-tools) assertparam "$1" $#; buildCrossTools=$2; shift 2;;
|
--build-cross-tools) assertparam "$1" $#; buildCrossTools=$2; shift 2;;
|
||||||
--build-cross-tools-gcc4) assertparam "$1" $#; buildCrossTools=$2;
|
--build-cross-tools-gcc4) assertparam "$1" $#; buildCrossTools=$2;
|
||||||
buildCrossToolsScript="${buildCrossToolsScript}_gcc4";
|
buildCrossToolsScript="${buildCrossToolsScript}_gcc4";
|
||||||
|
haikuGCCMachine=i586-pc-haiku;
|
||||||
shift 2;;
|
shift 2;;
|
||||||
--help | -h) usage; exit 0;;
|
--help | -h) usage; exit 0;;
|
||||||
*) echo Invalid argument: \`$1\'; exit 1;;
|
*) echo Invalid argument: \`$1\'; exit 1;;
|
||||||
@@ -250,7 +254,7 @@ mkdir -p $buildOutputDir || exit 1
|
|||||||
if [ -n "$buildCrossTools" ]; then
|
if [ -n "$buildCrossTools" ]; then
|
||||||
"$buildCrossToolsScript" "$sourceDir" "$buildCrossTools" \
|
"$buildCrossToolsScript" "$sourceDir" "$buildCrossTools" \
|
||||||
$outputDir || exit 1
|
$outputDir || exit 1
|
||||||
crossToolsPrefix=$outputDir/cross-tools/bin/i586-pc-beos-
|
crossToolsPrefix=$outputDir/cross-tools/bin/${haikuGCCMachine}-
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# cross tools
|
# cross tools
|
||||||
|
|||||||
Reference in New Issue
Block a user