OLD | NEW |
1 #!/bin/bash | 1 #!/bin/bash |
2 # Copyright 2012 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2012 The Native Client Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # be found in the LICENSE file. | 4 # found in the LICENSE file. |
5 # | 5 # |
6 #@ This script creates the mips trusted SDK. | 6 #@ This script creates the mips trusted SDK. |
7 #@ It must be run from the native_client directory. | 7 #@ It must be run from the native_client directory. |
8 | 8 |
9 # This script is intended to build a mipsel-linux-gnu cross compilation | 9 # This script is intended to build a mipsel-linux-gnu cross compilation |
10 # toolchain that runs on x86 linux and generates code for a little-endian, | 10 # toolchain that runs on x86 linux and generates code for a little-endian, |
11 # hard-float, mips32 target. | 11 # hard-float, mips32 target. |
12 # | 12 # |
13 # It expects the host machine to have relatively recent versions of GMP (4.2.0 | 13 # It expects the host machine to have relatively recent versions of GMP (4.2.0 |
14 # or later), MPFR (2.4.2), and MPC (0.8.1) in order to build the GCC. | 14 # or later), MPFR (2.4.2), and MPC (0.8.1) in order to build the GCC. |
(...skipping 529 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
544 ln -s ../../lib/libdl.so.2 libdl.so | 544 ln -s ../../lib/libdl.so.2 libdl.so |
545 | 545 |
546 rm -f librt.so | 546 rm -f librt.so |
547 ln -s ../../lib/librt.so.1 librt.so | 547 ln -s ../../lib/librt.so.1 librt.so |
548 | 548 |
549 rm -f libpcre.so | 549 rm -f libpcre.so |
550 ln -s ../../lib/libpcre.so.3 libpcre.so | 550 ln -s ../../lib/libpcre.so.3 libpcre.so |
551 | 551 |
552 rm -f libresolv.so | 552 rm -f libresolv.so |
553 ln -s ../../lib/libresolv.so.2 libresolv.so | 553 ln -s ../../lib/libresolv.so.2 libresolv.so |
| 554 |
| 555 ln -s ../../../mipsel-linux-gnu/lib/libstdc++.so.6.0.17 . |
| 556 ln -s libstdc++.so.6.0.17 libstdc++.so.6 |
| 557 ln -s libstdc++.so.6.0.17 libstdc++.so |
| 558 |
| 559 ln -s ../../../mipsel-linux-gnu/lib/libgcc_s.so.1 . |
| 560 ln -s libgcc_s.so.1 libgcc_s.so |
554 } | 561 } |
555 | 562 |
556 BuildAndInstallQemu() { | 563 BuildAndInstallQemu() { |
557 local saved_dir=$(pwd) | 564 local saved_dir=$(pwd) |
558 local tmpdir="${TMP}/qemu-mips.nacl" | 565 local tmpdir="${TMP}/qemu-mips.nacl" |
559 local tarball="qemu-0.12.5.tar.gz" | 566 local tarball="qemu-0.12.5.tar.gz" |
560 | 567 |
561 Banner "Building qemu in ${tmpdir}" | 568 Banner "Building qemu in ${tmpdir}" |
562 | 569 |
563 rm -rf ${tmpdir} | 570 rm -rf ${tmpdir} |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
626 InstallTrustedLinkerScript | 633 InstallTrustedLinkerScript |
627 BuildAndInstallQemu | 634 BuildAndInstallQemu |
628 CreateTarBall $1 | 635 CreateTarBall $1 |
629 | 636 |
630 else | 637 else |
631 Usage | 638 Usage |
632 exit -1 | 639 exit -1 |
633 | 640 |
634 fi | 641 fi |
635 | 642 |
OLD | NEW |