| OLD | NEW |
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2011 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 source pkg_info | |
| 7 source ../../build_tools/common.sh | |
| 8 | 6 |
| 9 TestStep() { | 7 TestStep() { |
| 10 Banner "Testing ${PACKAGE_NAME}" | 8 Banner "Testing ${PACKAGE_NAME}" |
| 11 if [ ${NACL_ARCH} == "pnacl" ]; then | 9 if [ ${NACL_ARCH} == "pnacl" ]; then |
| 12 local pexe=test/yajl_test | 10 local pexe=test/yajl_test |
| 13 local script=${NACL_BUILD_DIR}/yajl_test.sh | 11 local script=${BUILD_DIR}/yajl_test.sh |
| 14 TranslateAndWriteSelLdrScript ${pexe} x86-32 ${pexe}.x86-32.nexe ${script} | 12 TranslateAndWriteSelLdrScript ${pexe} x86-32 ${pexe}.x86-32.nexe ${script} |
| 15 (cd ../test && ./run_tests.sh ${script}) | 13 (cd ../test && ./run_tests.sh ${script}) |
| 16 TranslateAndWriteSelLdrScript ${pexe} x86-64 ${pexe}.x86-64.nexe ${script} | 14 TranslateAndWriteSelLdrScript ${pexe} x86-64 ${pexe}.x86-64.nexe ${script} |
| 17 (cd ../test && ./run_tests.sh ${script}) | 15 (cd ../test && ./run_tests.sh ${script}) |
| 18 else | 16 else |
| 19 local script=${NACL_BUILD_DIR}/yajl_test.sh | 17 local script=${BUILD_DIR}/yajl_test.sh |
| 20 local nexe=test/yajl_test | 18 local nexe=test/yajl_test |
| 21 | 19 |
| 22 WriteSelLdrScript ${script} ${nexe} | 20 WriteSelLdrScript ${script} ${nexe} |
| 23 (cd ../test && LogExecute ./run_tests.sh ${script}) | 21 (cd ../test && LogExecute ./run_tests.sh ${script}) |
| 24 fi | 22 fi |
| 25 } | 23 } |
| 26 | 24 |
| 27 | 25 |
| 28 ConfigureStep() { | 26 ConfigureStep() { |
| 29 EXTRA_CMAKE_ARGS="-DBUILD_SHARED=${NACL_GLIBC}" | 27 EXTRA_CMAKE_ARGS="-DBUILD_SHARED=${NACL_GLIBC}" |
| 30 CMakeConfigureStep | 28 CMakeConfigureStep |
| 31 } | 29 } |
| 32 | 30 |
| 33 | 31 |
| 34 BuildStep() { | 32 BuildStep() { |
| 35 Banner "Build ${PACKAGE_NAME}" | 33 Banner "Build ${PACKAGE_NAME}" |
| 36 echo "Directory: $(pwd)" | 34 echo "Directory: $(pwd)" |
| 37 make all -j${OS_JOBS} | 35 make all -j${OS_JOBS} |
| 38 } | 36 } |
| 39 | |
| 40 | |
| 41 PackageInstall | |
| 42 exit 0 | |
| OLD | NEW |