OLD | NEW |
1 #!/bin/bash | 1 #!/bin/bash |
2 # Copyright (c) 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 be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 # | 5 # |
6 #@ PNaCl toolchain build script | 6 #@ PNaCl toolchain build script |
7 #@------------------------------------------------------------------- | 7 #@------------------------------------------------------------------- |
8 #@ This script builds the ARM and PNaCl untrusted toolchains. | 8 #@ This script builds the ARM and PNaCl untrusted toolchains. |
9 #@ It MUST be run from the native_client/ directory. | 9 #@ It MUST be run from the native_client/ directory. |
10 ###################################################################### | 10 ###################################################################### |
(...skipping 2480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2491 mkdir -p ${destdir} | 2491 mkdir -p ${destdir} |
2492 # The NaCl headers insist on having a platform macro such as | 2492 # The NaCl headers insist on having a platform macro such as |
2493 # NACL_LINUX defined, but nonsfi/irt/irt_interfaces.c does not | 2493 # NACL_LINUX defined, but nonsfi/irt/irt_interfaces.c does not |
2494 # itself use any of these macros, so defining NACL_LINUX here even | 2494 # itself use any of these macros, so defining NACL_LINUX here even |
2495 # on non-Linux systems is OK. | 2495 # on non-Linux systems is OK. |
2496 gcc -m32 -O2 -Wall -Werror -I${NACL_ROOT}/.. -c \ | 2496 gcc -m32 -O2 -Wall -Werror -I${NACL_ROOT}/.. -c \ |
2497 -DNACL_LINUX=1 -DDEFINE_MAIN \ | 2497 -DNACL_LINUX=1 -DDEFINE_MAIN \ |
2498 ${NACL_ROOT}/src/nonsfi/irt/irt_interfaces.c \ | 2498 ${NACL_ROOT}/src/nonsfi/irt/irt_interfaces.c \ |
2499 -o ${destdir}/unsandboxed_irt.o | 2499 -o ${destdir}/unsandboxed_irt.o |
2500 gcc -m32 -O2 -Wall -Werror -I${NACL_ROOT}/.. -c \ | 2500 gcc -m32 -O2 -Wall -Werror -I${NACL_ROOT}/.. -c \ |
| 2501 ${NACL_ROOT}/src/nonsfi/irt/irt_random.c \ |
| 2502 -o ${destdir}/irt_random.o |
| 2503 gcc -m32 -O2 -Wall -Werror -I${NACL_ROOT}/.. -c \ |
2501 ${NACL_ROOT}/src/untrusted/irt/irt_query_list.c \ | 2504 ${NACL_ROOT}/src/untrusted/irt/irt_query_list.c \ |
2502 -o ${destdir}/irt_query_list.o | 2505 -o ${destdir}/irt_query_list.o |
2503 fi | 2506 fi |
2504 } | 2507 } |
2505 | 2508 |
2506 | 2509 |
2507 # Build the dummy "libpnacl_irt_shim.a", which is useful for building | 2510 # Build the dummy "libpnacl_irt_shim.a", which is useful for building |
2508 # commandline programs. It cannot be used to build PPAPI programs | 2511 # commandline programs. It cannot be used to build PPAPI programs |
2509 # because it does not actually shim the PPAPI interfaces. | 2512 # because it does not actually shim the PPAPI interfaces. |
2510 # The library is named the same as the real PPAPI shim to ensure that | 2513 # The library is named the same as the real PPAPI shim to ensure that |
(...skipping 863 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3374 | 3377 |
3375 if [ "$(type -t $1)" != "function" ]; then | 3378 if [ "$(type -t $1)" != "function" ]; then |
3376 #Usage | 3379 #Usage |
3377 echo "ERROR: unknown function '$1'." >&2 | 3380 echo "ERROR: unknown function '$1'." >&2 |
3378 echo "For help, try:" | 3381 echo "For help, try:" |
3379 echo " $0 help" | 3382 echo " $0 help" |
3380 exit 1 | 3383 exit 1 |
3381 fi | 3384 fi |
3382 | 3385 |
3383 "$@" | 3386 "$@" |
OLD | NEW |