| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 import("//build/config/linux/pkg_config.gni") | 5 import("//build/config/linux/pkg_config.gni") |
| 6 | 6 |
| 7 if (is_linux) { | 7 if (is_linux) { |
| 8 # This is a dependency on NSS with no libssl. On Linux we use a built-in SSL | 8 # This is a dependency on NSS with no libssl. On Linux we use a built-in SSL |
| 9 # library but the system NSS libraries. Non-Linux platforms using NSS use the | 9 # library but the system NSS libraries. Non-Linux platforms using NSS use the |
| 10 # hermetic one in //third_party/nss. | 10 # hermetic one in //third_party/nss. |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 198 "nspr/pr/src/threads/combined/pruthr.c", | 198 "nspr/pr/src/threads/combined/pruthr.c", |
| 199 "nspr/pr/src/threads/prcmon.c", | 199 "nspr/pr/src/threads/prcmon.c", |
| 200 "nspr/pr/src/threads/prcthr.c", | 200 "nspr/pr/src/threads/prcthr.c", |
| 201 "nspr/pr/src/threads/prdump.c", | 201 "nspr/pr/src/threads/prdump.c", |
| 202 "nspr/pr/src/threads/prmon.c", | 202 "nspr/pr/src/threads/prmon.c", |
| 203 "nspr/pr/src/threads/prrwlock.c", | 203 "nspr/pr/src/threads/prrwlock.c", |
| 204 "nspr/pr/src/threads/prsem.c", | 204 "nspr/pr/src/threads/prsem.c", |
| 205 "nspr/pr/src/threads/prtpd.c", | 205 "nspr/pr/src/threads/prtpd.c", |
| 206 ] | 206 ] |
| 207 | 207 |
| 208 direct_dependent_configs = [ ":nspr_config" ] | 208 public_configs = [ ":nspr_config" ] |
| 209 | 209 |
| 210 configs -= [ | 210 configs -= [ |
| 211 "//build/config/compiler:chromium_code", | 211 "//build/config/compiler:chromium_code", |
| 212 ] | 212 ] |
| 213 if (is_win) { | 213 if (is_win) { |
| 214 configs -= [ | 214 configs -= [ |
| 215 "//build/config/win:unicode", # Requires 8-bit mode. | 215 "//build/config/win:unicode", # Requires 8-bit mode. |
| 216 "//build/config/win:lean_and_mean", # Won"t compile with lean and mean. | 216 "//build/config/win:lean_and_mean", # Won"t compile with lean and mean. |
| 217 ] | 217 ] |
| 218 } | 218 } |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 341 | 341 |
| 342 component("nss") { | 342 component("nss") { |
| 343 output_name = "crnss" | 343 output_name = "crnss" |
| 344 sources = [ | 344 sources = [ |
| 345 # Ensure at least one object file is produced, so that MSVC does not | 345 # Ensure at least one object file is produced, so that MSVC does not |
| 346 # warn when creating the static/shared library. See the note for | 346 # warn when creating the static/shared library. See the note for |
| 347 # the "nssckbi" target for why the "nss" target was split as such. | 347 # the "nssckbi" target for why the "nss" target was split as such. |
| 348 "nss/lib/nss/nssver.c", | 348 "nss/lib/nss/nssver.c", |
| 349 ] | 349 ] |
| 350 | 350 |
| 351 deps = [ ":nss_static" ] | 351 public_deps = [ ":nss_static" ] |
| 352 | 352 |
| 353 if (include_nss_root_certs) { | 353 if (include_nss_root_certs) { |
| 354 deps += [ ":nssckbi" ] | 354 public_deps += [ ":nssckbi" ] |
| 355 } | 355 } |
| 356 | 356 |
| 357 if (component_mode == "shared_library") { | 357 if (component_mode == "shared_library") { |
| 358 if (is_mac) { | 358 if (is_mac) { |
| 359 ldflags = [ "-all_load" ] | 359 ldflags = [ "-all_load" ] |
| 360 } else if (is_win) { | 360 } else if (is_win) { |
| 361 # Pass the def file to the linker. | 361 # Pass the def file to the linker. |
| 362 ldflags = [ rebase_path("nss/exports_win.def", root_build_dir) ] | 362 ldflags = [ rebase_path("nss/exports_win.def", root_build_dir) ] |
| 363 } | 363 } |
| 364 } | 364 } |
| 365 | |
| 366 forward_dependent_configs_from = deps | |
| 367 } | 365 } |
| 368 | 366 |
| 369 config("nssckbi_config") { | 367 config("nssckbi_config") { |
| 370 include_dirs = [ "nss/lib/ckfw/builtins" ] | 368 include_dirs = [ "nss/lib/ckfw/builtins" ] |
| 371 } | 369 } |
| 372 | 370 |
| 373 # This is really more of a pseudo-target to work around the fact that | 371 # This is really more of a pseudo-target to work around the fact that |
| 374 # a single static_library target cannot contain two object files of the | 372 # a single static_library target cannot contain two object files of the |
| 375 # same name (hash.o / hash.obj). Logically, this is part of the | 373 # same name (hash.o / hash.obj). Logically, this is part of the |
| 376 # "nss_static" target. By separating it out, it creates a possible | 374 # "nss_static" target. By separating it out, it creates a possible |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 434 ] | 432 ] |
| 435 | 433 |
| 436 if (is_win) { | 434 if (is_win) { |
| 437 configs -= [ | 435 configs -= [ |
| 438 "//build/config/win:unicode", # Requires 8-bit mode. | 436 "//build/config/win:unicode", # Requires 8-bit mode. |
| 439 ] | 437 ] |
| 440 } | 438 } |
| 441 configs += [ "//build/config/compiler:no_chromium_code" ] | 439 configs += [ "//build/config/compiler:no_chromium_code" ] |
| 442 | 440 |
| 443 include_dirs = [ "nss/lib/ckfw" ] | 441 include_dirs = [ "nss/lib/ckfw" ] |
| 444 direct_dependent_configs = [ ":nssckbi_config" ] | 442 public_configs = [ ":nssckbi_config" ] |
| 445 | 443 |
| 446 deps = [ | 444 public_deps = [ |
| 447 ":nss_static", | 445 ":nss_static", |
| 448 ] | 446 ] |
| 449 forward_dependent_configs_from = deps | |
| 450 } | 447 } |
| 451 | 448 |
| 452 config("nss_static_config") { | 449 config("nss_static_config") { |
| 453 defines = [ | 450 defines = [ |
| 454 "NSS_STATIC", | 451 "NSS_STATIC", |
| 455 "NSS_USE_STATIC_LIBS", | 452 "NSS_USE_STATIC_LIBS", |
| 456 "USE_UTIL_DIRECTLY", | 453 "USE_UTIL_DIRECTLY", |
| 457 ] | 454 ] |
| 458 if (is_win) { | 455 if (is_win) { |
| 459 defines += [ "_WINDOWS" ] | 456 defines += [ "_WINDOWS" ] |
| (...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 834 | 831 |
| 835 configs -= [ | 832 configs -= [ |
| 836 "//build/config/compiler:chromium_code" | 833 "//build/config/compiler:chromium_code" |
| 837 ] | 834 ] |
| 838 if (is_win) { | 835 if (is_win) { |
| 839 configs -= [ | 836 configs -= [ |
| 840 "//build/config/win:unicode", # Requires 8-bit mode. | 837 "//build/config/win:unicode", # Requires 8-bit mode. |
| 841 ] | 838 ] |
| 842 } | 839 } |
| 843 configs += [ "//build/config/compiler:no_chromium_code" ] | 840 configs += [ "//build/config/compiler:no_chromium_code" ] |
| 844 direct_dependent_configs = [ ":nss_static_config" ] | 841 public_configs = [ ":nss_static_config" ] |
| 845 | 842 |
| 846 cflags = [] | 843 cflags = [] |
| 847 | 844 |
| 848 # Only need the defines and includes not in nss_static_config. | 845 # Only need the defines and includes not in nss_static_config. |
| 849 defines = [ | 846 defines = [ |
| 850 "MP_API_COMPATIBLE", | 847 "MP_API_COMPATIBLE", |
| 851 "NSS_DISABLE_DBM", | 848 "NSS_DISABLE_DBM", |
| 852 "RIJNDAEL_INCLUDE_TABLES", | 849 "RIJNDAEL_INCLUDE_TABLES", |
| 853 "SHLIB_VERSION=\"3\"", | 850 "SHLIB_VERSION=\"3\"", |
| 854 "SOFTOKEN_SHLIB_VERSION=\"3\"", | 851 "SOFTOKEN_SHLIB_VERSION=\"3\"", |
| (...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1141 "-Wno-incompatible-pointer-types", | 1138 "-Wno-incompatible-pointer-types", |
| 1142 # nss prefers `a && b || c` over `(a && b) || c`. | 1139 # nss prefers `a && b || c` over `(a && b) || c`. |
| 1143 "-Wno-logical-op-parentheses", | 1140 "-Wno-logical-op-parentheses", |
| 1144 # nss doesn"t use exhaustive switches on enums | 1141 # nss doesn"t use exhaustive switches on enums |
| 1145 "-Wno-switch", | 1142 "-Wno-switch", |
| 1146 # nss has some `unsigned < 0` checks. | 1143 # nss has some `unsigned < 0` checks. |
| 1147 "-Wno-tautological-compare", | 1144 "-Wno-tautological-compare", |
| 1148 ] | 1145 ] |
| 1149 } | 1146 } |
| 1150 | 1147 |
| 1148 public_deps = [ |
| 1149 ":nspr", |
| 1150 ] |
| 1151 deps = [ | 1151 deps = [ |
| 1152 ":nspr", | 1152 ":nspr", |
| 1153 "//third_party/sqlite", | 1153 "//third_party/sqlite", |
| 1154 ] | 1154 ] |
| 1155 | |
| 1156 forward_dependent_configs_from = [ ":nspr" ] | |
| 1157 } | 1155 } |
| 1158 } # Windows/Mac/iOS. | 1156 } # Windows/Mac/iOS. |
| 1159 | 1157 |
| OLD | NEW |