| OLD | NEW |
| 1 # Copyright (c) 2013 The Native Client Authors. All rights reserved. | 1 # Copyright (c) 2013 The Native Client Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 EXTRA_CONFIGURE_ARGS="--enable-x11=no" | 5 EXTRA_CONFIGURE_ARGS="--enable-x11=no" |
| 6 EXECUTABLES="util/rgb2gif${NACL_EXEEXT}" | 6 EXECUTABLES="util/rgb2gif${NACL_EXEEXT}" |
| 7 | 7 |
| 8 RunTest() { | 8 RunTest() { |
| 9 util/rgb2gif -s 320 200 < ${SRC_DIR}/tests/porsche.rgb > porsche.gif | 9 echo "Running util/rgb2gif on porsche.rgb" |
| 10 util/rgb2gif -s 320 200 < ${SRC_DIR}/tests/porsche.rgb > porsche.gif |
| 10 # TODO(sbc): do some basic checks on the resulting porsche.gif | 11 # TODO(sbc): do some basic checks on the resulting porsche.gif |
| 11 } | 12 } |
| 12 | 13 |
| 13 TestStep() { | 14 TestStep() { |
| 14 if [ "${NACL_LIBC}" = "glibc" ]; then | 15 if [[ ${NACL_LIBC} == glibc ]]; then |
| 15 # TODO(sbc): find out why glibc version of rgb2gif is crashing | 16 # TODO(sbc): find out why glibc version of rgb2gif is crashing |
| 16 return | 17 return |
| 17 fi | 18 fi |
| 18 | 19 |
| 19 if [ "${NACL_ARCH}" = "pnacl" ]; then | 20 RunTest |
| 20 local pexe=rgb2gif${NACL_EXEEXT} | 21 |
| 21 (cd util; | 22 if [[ ${NACL_ARCH} == pnacl ]]; then |
| 22 TranslateAndWriteLauncherScript ${pexe} x86-32 rgb2gif.x86-32.nexe rgb2gif) | 23 # Re-run tests with arm and x86-32 translations |
| 24 WriteLauncherScript util/rgb2gif rgb2gif.x86-32.nexe |
| 23 RunTest | 25 RunTest |
| 24 (cd util; | 26 WriteLauncherScript util/rgb2gif rgb2gif.arm.nexe |
| 25 TranslateAndWriteLauncherScript ${pexe} x86-64 rgb2gif.x86-64.nexe rgb2gif) | |
| 26 RunTest | |
| 27 else | |
| 28 RunTest | 27 RunTest |
| 29 fi | 28 fi |
| 30 } | 29 } |
| 31 | 30 |
| 32 | 31 |
| 33 BuildStep() { | 32 BuildStep() { |
| 34 # Limit the subdirecorties that get built by make. This is to | 33 # Limit the subdirecorties that get built by make. This is to |
| 35 # avoid the 'doc' directory which has a dependency on 'xmlto'. | 34 # avoid the 'doc' directory which has a dependency on 'xmlto'. |
| 36 # If 'xmlto' were added to the host build dependencies this could | 35 # If 'xmlto' were added to the host build dependencies this could |
| 37 # be removed. | 36 # be removed. |
| 38 export PATH=${NACL_BIN_PATH}:${PATH} | 37 export PATH=${NACL_BIN_PATH}:${PATH} |
| 39 make -j${OS_JOBS} SUBDIRS="lib util" | 38 make -j${OS_JOBS} SUBDIRS="lib util" |
| 40 } | 39 } |
| OLD | NEW |