Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2199)

Unified Diff: crypto/BUILD.gn

Issue 1312463005: Compile remoting client plugin with GN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/config/crypto.gni ('k') | jingle/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: crypto/BUILD.gn
diff --git a/crypto/BUILD.gn b/crypto/BUILD.gn
index a0cd1ca7aff1bc9155d401988f9632d618d71e9a..af78cbf81022efd2c86ed6ae3a020b0e142f6bc5 100644
--- a/crypto/BUILD.gn
+++ b/crypto/BUILD.gn
@@ -5,203 +5,194 @@
import("//build/config/crypto.gni")
import("//testing/test.gni")
-if (is_nacl) {
- component("crypto") {
- output_name = "crcrypto" # Avoid colliding with OpenSSL's libcrypto.
- sources = [
- "random.cc",
- "random.h",
+component("crypto") {
+ output_name = "crcrypto" # Avoid colliding with OpenSSL's libcrypto.
+ sources = [
+ "aead_openssl.cc",
+ "aead_openssl.h",
+ "aes_128_gcm_helpers_nss.cc",
+ "aes_128_gcm_helpers_nss.h",
+ "apple_keychain.h",
+ "apple_keychain_ios.mm",
+ "apple_keychain_mac.mm",
+ "capi_util.cc",
+ "capi_util.h",
+ "crypto_export.h",
+ "cssm_init.cc",
+ "cssm_init.h",
+ "curve25519-donna.c",
+ "curve25519.cc",
+ "curve25519.h",
+ "ec_private_key.h",
+ "ec_private_key_nss.cc",
+ "ec_private_key_openssl.cc",
+ "ec_signature_creator.cc",
+ "ec_signature_creator.h",
+ "ec_signature_creator_impl.h",
+ "ec_signature_creator_nss.cc",
+ "ec_signature_creator_openssl.cc",
+ "encryptor.cc",
+ "encryptor.h",
+ "encryptor_nss.cc",
+ "encryptor_openssl.cc",
+ "ghash.cc",
+ "ghash.h",
+ "hkdf.cc",
+ "hkdf.h",
+ "hmac.cc",
+ "hmac.h",
+ "hmac_nss.cc",
+ "hmac_openssl.cc",
+ "mac_security_services_lock.cc",
+ "mac_security_services_lock.h",
+
+ # TODO(brettw) these mocks should be moved to a test_support_crypto target
+ # if possible.
+ "mock_apple_keychain.cc",
+ "mock_apple_keychain.h",
+ "mock_apple_keychain_ios.cc",
+ "mock_apple_keychain_mac.cc",
+ "nss_key_util.cc",
+ "nss_key_util.h",
+ "nss_util.cc",
+ "nss_util.h",
+ "nss_util_internal.h",
+ "openssl_bio_string.cc",
+ "openssl_bio_string.h",
+ "openssl_util.cc",
+ "openssl_util.h",
+ "p224.cc",
+ "p224.h",
+ "p224_spake.cc",
+ "p224_spake.h",
+ "random.cc",
+ "random.h",
+ "rsa_private_key.cc",
+ "rsa_private_key.h",
+ "rsa_private_key_nss.cc",
+ "rsa_private_key_openssl.cc",
+ "scoped_capi_types.h",
+ "scoped_nss_types.h",
+ "secure_hash.h",
+ "secure_hash_default.cc",
+ "secure_hash_openssl.cc",
+ "secure_util.cc",
+ "secure_util.h",
+ "sha2.cc",
+ "sha2.h",
+ "signature_creator.h",
+ "signature_creator_nss.cc",
+ "signature_creator_openssl.cc",
+ "signature_verifier.h",
+ "signature_verifier_nss.cc",
+ "signature_verifier_openssl.cc",
+ "symmetric_key.h",
+ "symmetric_key_nss.cc",
+ "symmetric_key_openssl.cc",
+ "third_party/nss/chromium-blapi.h",
+ "third_party/nss/chromium-blapit.h",
+ "third_party/nss/chromium-nss.h",
+ "third_party/nss/chromium-sha256.h",
+ "third_party/nss/pk11akey.cc",
+ "third_party/nss/rsawrapr.c",
+ "third_party/nss/secsign.cc",
+ "third_party/nss/sha512.cc",
+ ]
+
+ # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
+ configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
+
+ deps = [
+ ":platform",
+ "//base",
+ "//base/third_party/dynamic_annotations",
+ ]
+
+ if (!is_mac && !is_ios) {
+ sources -= [
+ "apple_keychain.h",
+ "mock_apple_keychain.cc",
+ "mock_apple_keychain.h",
]
- deps = [
- "//base",
+ }
+
+ if (!is_mac) {
+ sources -= [
+ "cssm_init.cc",
+ "cssm_init.h",
+ "mac_security_services_lock.cc",
+ "mac_security_services_lock.h",
]
}
-} else {
- component("crypto") {
- output_name = "crcrypto" # Avoid colliding with OpenSSL's libcrypto.
- sources = [
- "aead_openssl.cc",
- "aead_openssl.h",
- "aes_128_gcm_helpers_nss.cc",
- "aes_128_gcm_helpers_nss.h",
- "apple_keychain.h",
- "apple_keychain_ios.mm",
- "apple_keychain_mac.mm",
+ if (!is_win) {
+ sources -= [
"capi_util.cc",
"capi_util.h",
- "crypto_export.h",
- "cssm_init.cc",
- "cssm_init.h",
- "curve25519-donna.c",
- "curve25519.cc",
- "curve25519.h",
- "ec_private_key.h",
+ ]
+ }
+
+ if (is_android) {
+ deps += [ "//third_party/android_tools:cpu_features" ]
+ }
+
+ if (use_openssl) {
+ # Remove NSS files when using OpenSSL
+ sources -= [
+ "aes_128_gcm_helpers_nss.cc",
+ "aes_128_gcm_helpers_nss.h",
"ec_private_key_nss.cc",
- "ec_private_key_openssl.cc",
- "ec_signature_creator.cc",
- "ec_signature_creator.h",
- "ec_signature_creator_impl.h",
"ec_signature_creator_nss.cc",
- "ec_signature_creator_openssl.cc",
- "encryptor.cc",
- "encryptor.h",
"encryptor_nss.cc",
- "encryptor_openssl.cc",
- "ghash.cc",
- "ghash.h",
- "hkdf.cc",
- "hkdf.h",
- "hmac.cc",
- "hmac.h",
"hmac_nss.cc",
- "hmac_openssl.cc",
- "mac_security_services_lock.cc",
- "mac_security_services_lock.h",
-
- # TODO(brettw) these mocks should be moved to a test_support_crypto target
- # if possible.
- "mock_apple_keychain.cc",
- "mock_apple_keychain.h",
- "mock_apple_keychain_ios.cc",
- "mock_apple_keychain_mac.cc",
- "nss_key_util.cc",
- "nss_key_util.h",
- "nss_util.cc",
- "nss_util.h",
- "nss_util_internal.h",
- "openssl_bio_string.cc",
- "openssl_bio_string.h",
- "openssl_util.cc",
- "openssl_util.h",
- "p224.cc",
- "p224.h",
- "p224_spake.cc",
- "p224_spake.h",
- "random.cc",
- "random.h",
- "rsa_private_key.cc",
- "rsa_private_key.h",
"rsa_private_key_nss.cc",
- "rsa_private_key_openssl.cc",
- "scoped_capi_types.h",
- "scoped_nss_types.h",
- "secure_hash.h",
"secure_hash_default.cc",
- "secure_hash_openssl.cc",
- "secure_util.cc",
- "secure_util.h",
- "sha2.cc",
- "sha2.h",
- "signature_creator.h",
"signature_creator_nss.cc",
- "signature_creator_openssl.cc",
- "signature_verifier.h",
"signature_verifier_nss.cc",
- "signature_verifier_openssl.cc",
- "symmetric_key.h",
"symmetric_key_nss.cc",
- "symmetric_key_openssl.cc",
"third_party/nss/chromium-blapi.h",
"third_party/nss/chromium-blapit.h",
"third_party/nss/chromium-nss.h",
- "third_party/nss/chromium-sha256.h",
"third_party/nss/pk11akey.cc",
"third_party/nss/rsawrapr.c",
"third_party/nss/secsign.cc",
- "third_party/nss/sha512.cc",
]
-
- # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
- configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
-
- deps = [
- ":platform",
- "//base",
- "//base/third_party/dynamic_annotations",
+ } else {
+ # Remove OpenSSL when using NSS.
+ sources -= [
+ "aead_openssl.cc",
+ "aead_openssl.h",
+ "ec_private_key_openssl.cc",
+ "ec_signature_creator_openssl.cc",
+ "encryptor_openssl.cc",
+ "hmac_openssl.cc",
+ "openssl_bio_string.cc",
+ "openssl_bio_string.h",
+ "openssl_util.cc",
+ "openssl_util.h",
+ "rsa_private_key_openssl.cc",
+ "secure_hash_openssl.cc",
+ "signature_creator_openssl.cc",
+ "signature_verifier_openssl.cc",
+ "symmetric_key_openssl.cc",
]
+ }
- if (!is_mac && !is_ios) {
- sources -= [
- "apple_keychain.h",
- "mock_apple_keychain.cc",
- "mock_apple_keychain.h",
- ]
- }
-
- if (!is_mac) {
- sources -= [
- "cssm_init.cc",
- "cssm_init.h",
- "mac_security_services_lock.cc",
- "mac_security_services_lock.h",
- ]
- }
- if (!is_win) {
- sources -= [
- "capi_util.cc",
- "capi_util.h",
- ]
- }
-
- if (is_android) {
- deps += [ "//third_party/android_tools:cpu_features" ]
- }
-
- if (use_openssl) {
- # Remove NSS files when using OpenSSL
- sources -= [
- "aes_128_gcm_helpers_nss.cc",
- "aes_128_gcm_helpers_nss.h",
- "ec_private_key_nss.cc",
- "ec_signature_creator_nss.cc",
- "encryptor_nss.cc",
- "hmac_nss.cc",
- "rsa_private_key_nss.cc",
- "secure_hash_default.cc",
- "signature_creator_nss.cc",
- "signature_verifier_nss.cc",
- "symmetric_key_nss.cc",
- "third_party/nss/chromium-blapi.h",
- "third_party/nss/chromium-blapit.h",
- "third_party/nss/chromium-nss.h",
- "third_party/nss/pk11akey.cc",
- "third_party/nss/rsawrapr.c",
- "third_party/nss/secsign.cc",
- ]
- } else {
- # Remove OpenSSL when using NSS.
- sources -= [
- "aead_openssl.cc",
- "aead_openssl.h",
- "ec_private_key_openssl.cc",
- "ec_signature_creator_openssl.cc",
- "encryptor_openssl.cc",
- "hmac_openssl.cc",
- "openssl_bio_string.cc",
- "openssl_bio_string.h",
- "openssl_util.cc",
- "openssl_util.h",
- "rsa_private_key_openssl.cc",
- "secure_hash_openssl.cc",
- "signature_creator_openssl.cc",
- "signature_verifier_openssl.cc",
- "symmetric_key_openssl.cc",
- ]
- }
+ # Some files are built when NSS is used at all, either for the internal crypto
+ # library or the platform certificate library.
+ if (use_openssl && !use_nss_certs) {
+ sources -= [
+ "nss_key_util.cc",
+ "nss_key_util.h",
+ "nss_util.cc",
+ "nss_util.h",
+ "nss_util_internal.h",
+ ]
+ }
- # Some files are built when NSS is used at all, either for the internal crypto
- # library or the platform certificate library.
- if (use_openssl && !use_nss_certs) {
- sources -= [
- "nss_key_util.cc",
- "nss_key_util.h",
- "nss_util.cc",
- "nss_util.h",
- "nss_util_internal.h",
- ]
- }
+ defines = [ "CRYPTO_IMPLEMENTATION" ]
- defines = [ "CRYPTO_IMPLEMENTATION" ]
+ if (is_nacl) {
+ deps += [ "//native_client_sdk/src/libraries/nacl_io" ]
}
}
« no previous file with comments | « build/config/crypto.gni ('k') | jingle/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698