| Index: src/trusted/validator_mips/testdata/compile_tests.sh
|
| ===================================================================
|
| --- src/trusted/validator_mips/testdata/compile_tests.sh (revision 0)
|
| +++ src/trusted/validator_mips/testdata/compile_tests.sh (revision 0)
|
| @@ -0,0 +1,54 @@
|
| +#!/bin/bash
|
| +# Copyright 2012 The Native Client Authors. All rights reserved.
|
| +# Use of this source code is governed by a BSD-style license that can
|
| +# be found in the LICENSE file.
|
| +# Copyright 2012 MIPS Technologies / RT-RK
|
| +
|
| +set -eu
|
| +
|
| +# Get the path to the Mips cross-compiler.
|
| +
|
| +dir=$(pwd)
|
| +cd ../../../..
|
| +topdir=$(pwd)
|
| +tools="$topdir/toolchain/pnacl_linux_i686_newlib/pkg/binutils/bin"
|
| +cd $dir
|
| +
|
| +readonly MIPSEL_LD="$tools/mipsel-pc-nacl-ld"
|
| +readonly MIPSEL_AS="$tools/mipsel-pc-nacl-as"
|
| +readonly MIPS_LD="$tools/mips-pc-nacl-ld"
|
| +readonly MIPS_AS="$tools/mips-pc-nacl-as"
|
| +
|
| +
|
| +for test_file in *.S ; do
|
| + object_file=${test_file%.*}.o
|
| + mips_nexe_file=mips/${test_file%.*}.nexe
|
| + mipsel_nexe_file=mipsel/${test_file%.*}.nexe
|
| + special_link_options="--section-start .text=0xFFFA000"
|
| +
|
| + echo "compiling (Mips) $test_file -> $mips_nexe_file"
|
| + ${MIPS_AS} -mips32r2 -mdsp\
|
| + $test_file -o $object_file
|
| + if [ $test_file == "test_invalid_dest.S" ]
|
| + then
|
| + ${MIPS_LD} $special_link_options -static -nodefaultlibs -nostdlib \
|
| + -m elf32btsmip_nacl $object_file -o $mips_nexe_file
|
| + else
|
| + ${MIPS_LD} -static -nodefaultlibs -nostdlib \
|
| + -m elf32btsmip_nacl $object_file -o $mips_nexe_file
|
| + fi
|
| +
|
| + echo "compiling (Mipsel) $test_file -> $mipsel_nexe_file"
|
| + ${MIPSEL_AS} -mips32r2 -EL -mdsp\
|
| + $test_file -o $object_file
|
| + if [ $test_file == "test_invalid_dest.S" ]
|
| + then
|
| + ${MIPSEL_LD} $special_link_options -static -nodefaultlibs -nostdlib \
|
| + -m elf32ltsmip_nacl $object_file -o $mipsel_nexe_file
|
| + else
|
| + ${MIPSEL_LD} -static -nodefaultlibs -nostdlib \
|
| + -m elf32ltsmip_nacl $object_file -o $mipsel_nexe_file
|
| + fi
|
| + rm $object_file
|
| +done
|
| +
|
|
|
| Property changes on: src/trusted/validator_mips/testdata/compile_tests.sh
|
| ___________________________________________________________________
|
| Added: svn:executable
|
| + *
|
|
|
|
|