| OLD | NEW |
| 1 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2011 The Chromium 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 # This GYP file defines untrusted (NaCl) targets. All targets in this | 5 # This GYP file defines untrusted (NaCl) targets. All targets in this |
| 6 # file should be conditionally depended upon via 'disable_nacl!=1' to avoid | 6 # file should be conditionally depended upon via 'disable_nacl!=1' to avoid |
| 7 # requiring NaCl sources for building. | 7 # requiring NaCl sources for building. |
| 8 | 8 |
| 9 { | 9 { |
| 10 'includes': [ | 10 'includes': [ |
| 11 '../native_client/build/untrusted.gypi', | 11 '../native_client/build/untrusted.gypi', |
| 12 'ppapi_sources.gypi', | 12 'ppapi_sources.gypi', |
| 13 ], | 13 ], |
| 14 'targets': [ | 14 'targets': [ |
| 15 { | 15 { |
| 16 'target_name': 'ppapi_cpp_lib', | 16 'target_name': 'ppapi_cpp_lib', |
| 17 'type': 'none', | 17 'type': 'none', |
| 18 'variables': { | 18 'variables': { |
| 19 'nlib_target': 'libppapi_cpp.a', | 19 'nlib_target': 'libppapi_cpp.a', |
| 20 'build_glibc': 0, | 20 'build_glibc': 1, |
| 21 'build_newlib': 1, | 21 'build_newlib': 1, |
| 22 'sources': [ | 22 'sources': [ |
| 23 '<@(cpp_source_files)', | 23 '<@(cpp_source_files)', |
| 24 'cpp/module_embedder.h', | 24 'cpp/module_embedder.h', |
| 25 'cpp/ppp_entrypoints.cc', | 25 'cpp/ppp_entrypoints.cc', |
| 26 ], | 26 ], |
| 27 }, | 27 }, |
| 28 'dependencies': [ | 28 'dependencies': [ |
| 29 '<(DEPTH)/native_client/tools.gyp:prep_toolchain', | 29 '<(DEPTH)/native_client/tools.gyp:prep_toolchain', |
| 30 ], | 30 ], |
| 31 }, | 31 }, |
| 32 { | 32 { |
| 33 'target_name': 'ppapi_nacl_tests', | 33 'target_name': 'ppapi_nacl_tests', |
| 34 'type': 'none', | 34 'type': 'none', |
| 35 'dependencies': [ | 35 'dependencies': [ |
| 36 'ppapi_cpp_lib', | 36 'ppapi_cpp_lib', |
| 37 'native_client/native_client.gyp:ppapi_lib', | 37 'native_client/native_client.gyp:ppapi_lib', |
| 38 'native_client/native_client.gyp:nacl_irt', | 38 'native_client/native_client.gyp:nacl_irt', |
| 39 ], | 39 ], |
| 40 'variables': { | 40 'variables': { |
| 41 'nexe_target': 'ppapi_nacl_tests', | 41 'nexe_target': 'ppapi_nacl_tests', |
| 42 'build_glibc': 0, | 42 'build_glibc': 1, |
| 43 'build_newlib': 1, | 43 'build_newlib': 1, |
| 44 'nmf%': '<(PRODUCT_DIR)/>(nexe_target)_glibc.nmf', |
| 45 'tc_lib64%': '>(nacl_glibc_tc_root)/x86_64-nacl/lib64', |
| 46 'tc_lib32%': '>(nacl_glibc_tc_root)/x86_64-nacl/lib32', |
| 44 'include_dirs': [ | 47 'include_dirs': [ |
| 45 'lib/gl/include', | 48 'lib/gl/include', |
| 46 '..', | 49 '..', |
| 47 ], | 50 ], |
| 48 'link_flags': [ | 51 'link_flags': [ |
| 49 '-lppapi_cpp', | 52 '-lppapi_cpp', |
| 50 '-lppapi', | 53 '-lppapi', |
| 51 ], | 54 ], |
| 52 'extra_deps64': [ | 55 'extra_deps_newlib64': [ |
| 53 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libppapi_cpp.a', | 56 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libppapi_cpp.a', |
| 54 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libppapi.a', | 57 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib64/libppapi.a', |
| 55 ], | 58 ], |
| 56 'extra_deps32': [ | 59 'extra_deps_newlib32': [ |
| 57 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libppapi_cpp.a', | 60 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libppapi_cpp.a', |
| 58 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libppapi.a', | 61 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/lib32/libppapi.a', |
| 59 ], | 62 ], |
| 63 'extra_deps_glibc64': [ |
| 64 '<(SHARED_INTERMEDIATE_DIR)/tc_glibc/lib64/libppapi_cpp.a', |
| 65 '<(SHARED_INTERMEDIATE_DIR)/tc_glibc/lib64/libppapi.a', |
| 66 ], |
| 67 'extra_deps_glibc32': [ |
| 68 '<(SHARED_INTERMEDIATE_DIR)/tc_glibc/lib32/libppapi_cpp.a', |
| 69 '<(SHARED_INTERMEDIATE_DIR)/tc_glibc/lib32/libppapi.a', |
| 70 ], |
| 60 'extra_deps_arm': [ | 71 'extra_deps_arm': [ |
| 61 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libppapi_cpp.a', | 72 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libppapi_cpp.a', |
| 62 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libppapi.a', | 73 '<(SHARED_INTERMEDIATE_DIR)/tc_newlib/libarm/libppapi.a', |
| 63 ], | 74 ], |
| 64 'sources': [ | 75 'sources': [ |
| 65 '<@(test_common_source_files)', | 76 '<@(test_common_source_files)', |
| 66 '<@(test_nacl_source_files)', | 77 '<@(test_nacl_source_files)', |
| 67 ], | 78 ], |
| 68 }, | 79 }, |
| 80 'actions': [ |
| 81 { |
| 82 'action_name': 'Generate NMF file and copy libs', |
| 83 'inputs': ['>(out64)', '>(out32)'], |
| 84 # NOTE: There is no explicit dependency for the lib32 |
| 85 # and lib64 directories created in the PRODUCT_DIR. |
| 86 # They are created as a side-effect of NMF creation. |
| 87 'outputs': ['>(nmf)'], |
| 88 'action': [ |
| 89 '>(python_exe)', |
| 90 '<(DEPTH)/native_client_sdk/src/tools/create_nmf.py', |
| 91 '>@(_inputs)', |
| 92 '--library-path=>(tc_lib64)', |
| 93 '--library-path=>(tc_lib32)', |
| 94 '--output=>(nmf)', |
| 95 '--stage-dependencies=<(PRODUCT_DIR)', |
| 96 ], |
| 97 }, |
| 98 ], |
| 69 }, | 99 }, |
| 70 ], | 100 ], |
| 71 } | 101 } |
| OLD | NEW |