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

Side by Side Diff: components/os_crypt/BUILD.gn

Issue 2086123003: Move KWalletDBus util from the Password Manager to OSCrypt. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
« no previous file with comments | « components/os_crypt.gypi ('k') | components/os_crypt/DEPS » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/features.gni")
5 import("//build/config/ui.gni") 6 import("//build/config/ui.gni")
6 7
7 source_set("os_crypt") { 8 source_set("os_crypt") {
8 sources = [ 9 sources = [
9 "ie7_password_win.cc", 10 "ie7_password_win.cc",
10 "ie7_password_win.h", 11 "ie7_password_win.h",
11 "keychain_password_mac.h", 12 "keychain_password_mac.h",
12 "keychain_password_mac.mm", 13 "keychain_password_mac.mm",
13 "os_crypt.h", 14 "os_crypt.h",
14 "os_crypt_mac.mm", 15 "os_crypt_mac.mm",
(...skipping 21 matching lines...) Expand all
36 "keychain_password_mac.mm", 37 "keychain_password_mac.mm",
37 "os_crypt_mac.mm", 38 "os_crypt_mac.mm",
38 ] 39 ]
39 set_sources_assignment_filter(sources_assignment_filter) 40 set_sources_assignment_filter(sources_assignment_filter)
40 } 41 }
41 42
42 if (is_win) { 43 if (is_win) {
43 libs = [ "crypt32.lib" ] 44 libs = [ "crypt32.lib" ]
44 } 45 }
45 46
46 if (is_desktop_linux && use_glib) { 47 if (is_desktop_linux && (use_glib || use_dbus)) {
47 sources -= [ "os_crypt_posix.cc" ] 48 sources -= [ "os_crypt_posix.cc" ]
48 sources += [ 49 sources += [
49 "key_storage_libsecret.cc",
50 "key_storage_libsecret.h",
51 "key_storage_linux.cc", 50 "key_storage_linux.cc",
52 "key_storage_linux.h", 51 "key_storage_linux.h",
53 "libsecret_util_linux.cc",
54 "libsecret_util_linux.h",
55 "os_crypt_linux.cc", 52 "os_crypt_linux.cc",
56 ] 53 ]
57 configs += [ "//build/config/linux:glib" ] 54 defines = []
58 deps += [ "//third_party/libsecret" ] 55
59 defines = [ "USE_LIBSECRET" ] 56 if (use_glib) {
57 sources += [
58 "key_storage_libsecret.cc",
59 "key_storage_libsecret.h",
60 "libsecret_util_linux.cc",
61 "libsecret_util_linux.h",
62 ]
63 configs += [ "//build/config/linux:glib" ]
64 deps += [ "//third_party/libsecret" ]
65 defines += [ "USE_LIBSECRET" ]
66 }
67 if (use_dbus) {
68 sources += [
69 "kwallet_dbus.cc",
70 "kwallet_dbus.h",
71 ]
72 deps += [ "//dbus" ]
73 defines += [ "USE_KWALLET" ]
74 }
60 } 75 }
61 } 76 }
62 77
63 source_set("test_support") { 78 source_set("test_support") {
64 testonly = true 79 testonly = true
65 sources = [ 80 sources = [
66 "os_crypt_mocker.cc", 81 "os_crypt_mocker.cc",
67 "os_crypt_mocker.h", 82 "os_crypt_mocker.h",
68 ] 83 ]
69 deps = [ 84 deps = [
70 ":os_crypt", 85 ":os_crypt",
71 "//base", 86 "//base",
72 "//testing/gtest", 87 "//testing/gtest",
73 ] 88 ]
74 if (is_desktop_linux && use_glib) { 89 if (is_desktop_linux && (use_glib || use_dbus)) {
75 sources += [ 90 sources += [
76 "os_crypt_mocker_linux.cc", 91 "os_crypt_mocker_linux.cc",
77 "os_crypt_mocker_linux.h", 92 "os_crypt_mocker_linux.h",
78 ] 93 ]
79 deps += [ "//third_party/libsecret" ] 94 deps += [ "//third_party/libsecret" ]
80 defines = [ "USE_LIBSECRET" ] 95 defines = [ "USE_LIBSECRET" ]
81 } 96 }
82 } 97 }
83 98
84 source_set("unit_tests") { 99 source_set("unit_tests") {
85 testonly = true 100 testonly = true
86 sources = [ 101 sources = [
87 "ie7_password_win_unittest.cc", 102 "ie7_password_win_unittest.cc",
88 "keychain_password_mac_unittest.mm", 103 "keychain_password_mac_unittest.mm",
89 "os_crypt_unittest.cc", 104 "os_crypt_unittest.cc",
90 ] 105 ]
91 deps = [ 106 deps = [
92 ":os_crypt", 107 ":os_crypt",
93 ":test_support", 108 ":test_support",
94 "//base", 109 "//base",
95 "//crypto", 110 "//crypto",
111 "//testing/gmock",
96 "//testing/gtest", 112 "//testing/gtest",
97 ] 113 ]
98 114
99 if (is_desktop_linux && use_glib) { 115 if (is_desktop_linux && (use_glib || use_dbus)) {
100 sources += [ 116 sources += [ "os_crypt_linux_unittest.cc" ]
101 "os_crypt_linux_unittest.cc", 117 defines = []
102 "os_crypt_util_linux_unittest.cc", 118
103 ] 119 if (use_glib) {
104 deps += [ "//third_party/libsecret" ] 120 sources += [ "os_crypt_util_linux_unittest.cc" ]
105 defines = [ "USE_LIBSECRET" ] 121 deps += [ "//third_party/libsecret" ]
122 defines += [ "USE_LIBSECRET" ]
123 }
124 if (use_dbus) {
125 sources += [ "kwallet_dbus_unittest.cc" ]
126 deps += [
127 "//dbus",
128 "//dbus:test_support",
129 ]
130 defines += [ "USE_KWALLET" ]
131 }
106 } 132 }
107 } 133 }
OLDNEW
« no previous file with comments | « components/os_crypt.gypi ('k') | components/os_crypt/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698