Chromium Code Reviews| Index: BUILD.gn |
| diff --git a/BUILD.gn b/BUILD.gn |
| index 3e8496e0f22a666e798b8c3c2eed569b39a0b74f..7c82d8c60b8c19acfb9dd94e27614de4b2060b05 100644 |
| --- a/BUILD.gn |
| +++ b/BUILD.gn |
| @@ -10,6 +10,8 @@ import("//third_party/yasm/yasm_assemble.gni") |
| if (is_posix && !is_mac) { |
| os_category = "linux" |
| +} if (is_nacl) { |
|
Johann
2015/09/03 02:14:51
this doesn't seem necessary, but if you want to ke
Sergey Ulanov
2015/09/03 04:25:20
Actually with your other suggestion below os_categ
|
| + os_category = "nacl" |
| } else { |
| os_category = current_os |
| } |
| @@ -35,10 +37,18 @@ if (current_cpu == "x86") { |
| cpu_arch_full = current_cpu |
| } |
| +if (os_category == "nacl") { |
|
Johann
2015/09/03 02:14:51
this could be if(is_nacl), yeah?
Sergey Ulanov
2015/09/03 04:25:20
Done.
|
| + platform_include_dir = |
| + "//third_party/libvpx/source/config/$os_category" |
|
Johann
2015/09/03 02:14:51
this could be hard coded source/config/nacl
Sergey Ulanov
2015/09/03 04:25:20
Done.
|
| +} else { |
| + platform_include_dir = |
| + "//third_party/libvpx/source/config/$os_category/$cpu_arch_full" |
| +} |
| + |
| config("libvpx_config") { |
| include_dirs = [ |
| "//third_party/libvpx/source/config", |
| - "//third_party/libvpx/source/config/$os_category/$cpu_arch_full", |
| + platform_include_dir, |
| "//third_party/libvpx/source/libvpx", |
| "$root_gen_dir/third_party/libvpx", # Provides vpx_rtcd.h. |
| ] |
| @@ -77,9 +87,9 @@ if (current_cpu == "x86" || current_cpu == "x64") { |
| defines = [ "CHROMIUM" ] |
| include_dirs = [ |
| - "//third_party/libvpx/source/config/$os_category/$cpu_arch_full", |
| + platform_include_dir, |
| "//third_party/libvpx/source/config", |
| - "//third_party/libvpx/source/libvpx", |
| + "//third_party/libvpx/source/libvpx", |
| target_gen_dir |
| ] |
| } |
| @@ -214,7 +224,9 @@ static_library("libvpx") { |
| configs += [ "//build/config/compiler:optimize_max" ] |
| } |
| - if (current_cpu == "x86") { |
| + if (is_nacl) { |
| + sources = libvpx_srcs_generic |
| + } if (current_cpu == "x86") { |
|
Johann
2015/09/03 02:14:51
else if?
Sergey Ulanov
2015/09/03 04:25:20
Yes, of course! Thanks for catching it!
|
| sources = libvpx_srcs_x86 |
| } else if (current_cpu == "x64") { |
| if (is_msan) { |