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 font example from ppapi/examples/font. | 6 # This is a Pepper font example from ppapi/examples/font. |
7 | 7 |
8 Import('env') | 8 Import('env') |
9 | 9 |
10 env.Prepend(CPPDEFINES=['XP_UNIX']) | 10 env.Prepend(CPPDEFINES=['XP_UNIX']) |
11 env.Replace(TEST_DIR='${SOURCE_ROOT}/ppapi/native_client/tests/' + | |
12 'ppapi_example_font/') | |
13 | 11 |
14 # Adjust compiler flags to the more forgiving standards used in | 12 # Adjust compiler flags to the more forgiving standards used in |
15 # ppapi/examples/*. | 13 # ppapi/examples/*. |
16 env.FilterOut(CCFLAGS=['-Werror', '-pedantic']) | 14 env.FilterOut(CCFLAGS=['-Werror', '-pedantic']) |
17 env.Append(CCFLAGS=['-Wformat=0']) | 15 env.Append(CCFLAGS=['-Wformat=0']) |
18 | 16 |
19 nexe_name = 'ppapi_example_font_${TARGET_FULLARCH}' | 17 nexe_name = 'ppapi_example_font_${TARGET_FULLARCH}' |
20 obj = env.ComponentObject( | 18 obj = env.ComponentObject( |
21 'simple_font', | 19 'simple_font', |
22 '$SOURCE_ROOT/ppapi/examples/font/simple_font.cc' | 20 '$SOURCE_ROOT/ppapi/examples/font/simple_font.cc' |
23 ) | 21 ) |
24 nexe = env.ComponentProgram(nexe_name, [obj], | 22 nexe = env.ComponentProgram(nexe_name, [obj], |
25 EXTRA_LIBS=['${PPAPI_LIBS}', 'ppapi_cpp']) | 23 EXTRA_LIBS=['${PPAPI_LIBS}', 'ppapi_cpp']) |
26 | 24 |
27 # Note that the html is required to run this program. | 25 # Note that the html is required to run this program. |
28 env.Publish(nexe_name, 'run', | 26 env.Publish(nexe_name, 'run', |
29 ['ppapi_example_font.html']) | 27 ['ppapi_example_font.html', 'ppapi_example_font.nmf']) |
30 | 28 |
31 test = env.PPAPIBrowserTester('ppapi_example_font_test.out', | 29 test = env.PPAPIBrowserTester('ppapi_example_font_test.out', |
32 url='ppapi_example_font.html', | 30 url='ppapi_example_font.html', |
33 nmf='${TEST_DIR}/ppapi_example_font.nmf', | |
34 files=env.ExtractPublishedFiles(nexe_name)) | 31 files=env.ExtractPublishedFiles(nexe_name)) |
35 | 32 |
36 env.AddNodeToTestSuite(test, | 33 env.AddNodeToTestSuite(test, |
37 ['chrome_browser_tests'], | 34 ['chrome_browser_tests'], |
38 'run_ppapi_example_font_test', | 35 'run_ppapi_example_font_test', |
39 is_broken=env.PPAPIBrowserTesterIsBroken()) | 36 is_broken=env.PPAPIBrowserTesterIsBroken()) |
OLD | NEW |