Subversion Repositories HelenOS

Rev

Rev 1847 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

#! /bin/bash

BASE="$HOME/HelenOS.export"
TARGETS="amd64 ia32 ia64 mips32gbe mips32gle ppc32 ppc64 sparc64"
OUTPUT="$HOME/arch"

for TARGET in $TARGETS ; do
    if [ "$TARGET" == "mips32gbe" ]; then
        UTARGET="mips32eb"
    elif [ "$TARGET" == "mips32gle" ]; then
        UTARGET="mips32"
    else
        UTARGET="$TARGET"
    fi
    
    rm -fr "$OUTPUT/$TARGET"
    mkdir -p "$OUTPUT/$TARGET/include"
    
    cd "$BASE"
    make distclean
    make "PLATFORM=$TARGET" "COMPILER=cross" "CONFIG_DEBUG=n"
    
    cp -v "$BASE/uspace/libc/arch/$UTARGET/src/entry.o" "$OUTPUT/$TARGET"
    cp -v "$BASE/uspace/libc/arch/$UTARGET/_link.ld" "$OUTPUT/$TARGET"
    cp -v "$BASE/uspace/libc/libc.a" "$OUTPUT/$TARGET"
    cp -v "$BASE/uspace/softint/libsoftint.a" "$OUTPUT/$TARGET"
    cp -v "$BASE/uspace/softfloat/libsoftfloat.a" "$OUTPUT/$TARGET"
    cp -v -R -L "$BASE/uspace/libc/include" "$OUTPUT/$TARGET"
done