| OLD | NEW |
| 1 # -*- python -*- | 1 # -*- python -*- |
| 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 # This is a pepper audio example from examples/audio. | 6 # This is a pepper audio example from examples/audio. |
| 7 | 7 |
| 8 Import('env') | 8 Import('env') |
| 9 | 9 |
| 10 env.Prepend(CPPDEFINES=['XP_UNIX']) | 10 env.Prepend(CPPDEFINES=['XP_UNIX']) |
| 11 | 11 |
| 12 nexe_name = 'ppapi_example_audio_%s.nexe' % env.get('TARGET_FULLARCH') | 12 nexe_name = 'ppapi_example_audio_%s' % env.get('TARGET_FULLARCH') |
| 13 nexe = env.ComponentProgram(nexe_name, | 13 nexe = env.ComponentProgram(nexe_name, |
| 14 [ 'audio.cc' ], | 14 [ 'audio.cc' ], |
| 15 EXTRA_LIBS=['${PPAPI_LIBS}', | 15 EXTRA_LIBS=['${PPAPI_LIBS}', |
| 16 'ppapi_cpp', | 16 'ppapi_cpp', |
| 17 'platform', | 17 'platform', |
| 18 'gio', | 18 'gio', |
| 19 'pthread', | 19 'pthread', |
| 20 'm']) | 20 'm']) |
| 21 | 21 |
| 22 # Note that the html is required to run this program. | 22 # Note that the html is required to run this program. |
| 23 env.Publish(nexe_name, 'run', | 23 env.Publish(nexe_name, 'run', |
| 24 ['ppapi_example_audio.html' , 'ppapi_example_audio.nmf']) | 24 ['ppapi_example_audio.html' , 'ppapi_example_audio.nmf']) |
| 25 | 25 |
| 26 test = env.PPAPIBrowserTester('ppapi_example_audio_test.out', | 26 test = env.PPAPIBrowserTester('ppapi_example_audio_test.out', |
| 27 url='ppapi_example_audio.html#mute', | 27 url='ppapi_example_audio.html#mute', |
| 28 files=[nexe, | 28 files=[nexe, |
| 29 env.File('ppapi_example_audio.nmf'), | 29 env.File('ppapi_example_audio.nmf'), |
| 30 env.File('ppapi_example_audio.html')], | 30 env.File('ppapi_example_audio.html')], |
| 31 args=['--enable_experimental_js']) | 31 args=['--enable_experimental_js']) |
| 32 | 32 |
| 33 # Though this tests passes locally, it does not pass on the Windows | 33 # Though this tests passes locally, it does not pass on the Windows |
| 34 # and Linux buildbots, which do not have audio devices. Although | 34 # and Linux buildbots, which do not have audio devices. Although |
| 35 # StartPlayback() and StopPlayback() succeed, the audio callback is | 35 # StartPlayback() and StopPlayback() succeed, the audio callback is |
| 36 # not called. However, this does work on the Mac buildbots. | 36 # not called. However, this does work on the Mac buildbots. |
| 37 is_broken = env.PPAPIBrowserTesterIsBroken() or not env.Bit('host_mac') | 37 is_broken = env.PPAPIBrowserTesterIsBroken() or not env.Bit('host_mac') |
| 38 env.AddNodeToTestSuite(test, | 38 env.AddNodeToTestSuite(test, |
| 39 ['chrome_browser_tests'], | 39 ['chrome_browser_tests'], |
| 40 'run_ppapi_example_audio_test', | 40 'run_ppapi_example_audio_test', |
| 41 is_broken=is_broken) | 41 is_broken=is_broken) |
| OLD | NEW |