OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [bld-all.sh] - Diff between revs 448 and 454

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 448 Rev 454
Line 660... Line 660...
 
 
}       # gnu_make
}       # gnu_make
 
 
 
 
# ------------------------------------------------------------------------------
# ------------------------------------------------------------------------------
# Conditionally relocate the newlib headers and libraries.
 
function relocate_newlib {
 
    if [ "true" == "${newlib_flag}" ]
 
    then
 
        echo "bld-all.sh: Relocating newlib (no-op)"
 
    fi
 
}       # relocate_newlib
 
 
 
 
 
# ------------------------------------------------------------------------------
 
# Conditionally configure and install the Linux headers
# Conditionally configure and install the Linux headers
 
 
# @param[in] $1       The prefix to use for installation.
# @param[in] $1       The prefix to use for installation.
function install_linux_headers {
function install_linux_headers {
    this_prefix=$1
    this_prefix=$1
Line 855... Line 845...
    # Install all
    # Install all
    gnu_make ${install_flag} ${bd_elf} install-binutils install-gas install-ld \
    gnu_make ${install_flag} ${bd_elf} install-binutils install-gas install-ld \
        install-gcc install-target-libgcc install-target-libstdc++-v3 \
        install-gcc install-target-libgcc install-target-libstdc++-v3 \
        ${newlib_install}
        ${newlib_install}
    gnu_make ${install_flag} ${bd_elf_gdb} install-sim install-gdb
    gnu_make ${install_flag} ${bd_elf_gdb} install-sim install-gdb
    relocate_newlib
 
fi
fi
 
 
# Build the uClibc (or32-linux) tool chain
# Build the uClibc (or32-linux) tool chain
if [ "true" == "${or32_linux_flag}" ]
if [ "true" == "${or32_linux_flag}" ]
then
then
Line 882... Line 871...
 
 
        # Make a clean temporary install directory.
        # Make a clean temporary install directory.
        rm -rf ${prefix_tmp}
        rm -rf ${prefix_tmp}
        mkdir ${prefix_tmp}
        mkdir ${prefix_tmp}
 
 
 
        # For header building we use just single threads, or we don't find
 
        # pthread.h.
 
        thread_config="--enable-threads=single --disable-tls"
 
 
        # To create the headers we only use C
        # To create the headers we only use C
        gnu_config ${config_flag} ${prefix_tmp} ${bd_linux} ../${unisrc_dir} \
        gnu_config ${config_flag} ${prefix_tmp} ${bd_linux} ../${unisrc_dir} \
            "c" "--without-headers --enable-threads=single"
            "c" "--without-headers ${thread_config}"
        gnu_make ${build_flag} ${bd_linux} all-build all-binutils all-gas all-ld
        gnu_make ${build_flag} ${bd_linux} all-build all-binutils all-gas all-ld
        gnu_make ${build_flag} ${bd_linux} all-gcc
        gnu_make ${build_flag} ${bd_linux} all-gcc
        gnu_make ${build_flag} ${bd_linux} all-target-libgcc
        gnu_make ${build_flag} ${bd_linux} all-target-libgcc
        gnu_make ${install_flag} ${bd_linux} install-binutils install-gas \
        gnu_make ${install_flag} ${bd_linux} install-binutils install-gas \
            install-ld
            install-ld
Line 915... Line 908...
    # Stage 2 GCC uses the headers installed from stage 1.
    # Stage 2 GCC uses the headers installed from stage 1.
    if [ "true" == "${uclibc_stage2_flag}" ]
    if [ "true" == "${uclibc_stage2_flag}" ]
    then
    then
        echo "bld-all.sh: uClibc GCC stage 2"
        echo "bld-all.sh: uClibc GCC stage 2"
 
 
        # FIXME: uclibc is supposed to provide thread support, but doesn't.
        # uClibc now supports POSIX threads, but not TLS
        thread_hack="--disable-threads --disable-libgomp"
        thread_config="--enable-threads=posix --disable-tls"
 
 
        gnu_config ${config_flag} ${prefix} ${bd_linux} ../${unisrc_dir} \
        gnu_config ${config_flag} ${prefix} ${bd_linux} ../${unisrc_dir} \
            "${languages}" \
            "${languages}" \
            "--with-headers=${prefix_tmp}/or32-linux/include $thread_hack"
            "--with-headers=${prefix_tmp}/or32-linux/include ${thread_config}"
        gnu_make ${build_flag} ${bd_linux} all-build all-binutils all-gas all-ld
        gnu_make ${build_flag} ${bd_linux} all-build all-binutils all-gas all-ld
        gnu_make ${build_flag} ${bd_linux} all-gcc
        gnu_make ${build_flag} ${bd_linux} all-gcc
        gnu_make ${build_flag} ${bd_linux} all-target-libgcc
        gnu_make ${build_flag} ${bd_linux} all-target-libgcc
        gnu_make ${install_flag} ${bd_linux} install-binutils install-gas \
        gnu_make ${install_flag} ${bd_linux} install-binutils install-gas \
            install-ld
            install-ld
        gnu_make ${install_flag} ${bd_linux} install-gcc install-target-libgcc
        gnu_make ${install_flag} ${bd_linux} install-gcc install-target-libgcc
 
 
        unset thread_hack
 
 
 
        # We need to build uClibc before building the C++ libraries, which in
        # We need to build uClibc before building the C++ libraries, which in
        # turn needs the Linux headers
        # turn needs the Linux headers
        export PATH=${prefix}/bin:${PATH}
        export PATH=${prefix}/bin:${PATH}
        install_linux_headers ${prefix}
        install_linux_headers ${prefix}
        uclibc_config ${prefix}
        uclibc_config ${prefix}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.