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

Side by Side Diff: cloud_print/virtual_driver/win/port_monitor/BUILD.gn

Issue 2590433003: Re-enable building both 32 and 64 bit version of the GCP port monitor. (Closed)
Patch Set: Fix some issues with 32/64 bit installation. Created 4 years 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
OLDNEW
1 # Copyright 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 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("//chrome/process_version_rc_template.gni") 5 import("//chrome/process_version_rc_template.gni")
6 6
7 assert(is_win) 7 assert(is_win)
8 8
9 group("port_monitor") { 9 group("port_monitor") {
10 public_deps = [ 10 public_deps = [
11 ":port_monitor_dll", 11 ":port_monitor_dll",
12 ] 12 ]
13 } 13 }
14 14
15 shared_library("port_monitor_dll") { 15 shared_library("port_monitor_dll") {
16 output_name = "gcp_portmon" 16 output_name = "gcp_portmon"
17 if (current_cpu == "x64") {
18 output_name = "gcp_portmon64"
19 }
17 20
18 sources = [ 21 sources = [
19 "port_monitor.def", 22 "port_monitor.def",
20 "port_monitor_dll.cc", 23 "port_monitor_dll.cc",
21 ] 24 ]
22 25
23 deps = [ 26 deps = [
24 ":lib", 27 ":lib",
25 ":resources", 28 ":resources",
26 "//base", 29 "//base",
27 "//chrome/common:constants", 30 "//chrome/common:constants",
28 "//chrome/common:version_header", 31 "//chrome/common:version_header",
29 "//cloud_print/common", 32 "//cloud_print/common",
30 "//cloud_print/virtual_driver/win", 33 "//cloud_print/virtual_driver/win",
31 ] 34 ]
32 35
33 libs = [ "userenv.lib" ] 36 libs = [ "userenv.lib" ]
34 } 37 }
35 38
39 group("copy_gcp_portmon_binaries") {
40 deps = [
41 ":copy_gcp_portmon_dll",
42 ]
43 # TODO(pastarmovj): Find some way to reference the pdb file for the 64bit dll
44 # simply using it in the sources directive causes gn to error when generating
45 # the build files.
46 }
47
48 if (current_cpu == "x64") {
49 copy("copy_gcp_portmon_dll") {
50 sources = [
51 "$root_out_dir/gcp_portmon64.dll",
52 ]
53 outputs = [
54 "$root_out_dir/gcp_portmon.dll",
55 ]
56 deps = [
57 ":port_monitor_dll",
58 ]
59 }
60 } else {
61 # Make sure that we have a copy of gcp_portmon64.dll in the root out
62 # directory.
63 copy("copy_gcp_portmon_dll") {
64 if (is_clang) {
65 gcp_portmon64_toolchain = "//build/toolchain/win:clang_x64"
66 } else {
67 gcp_portmon64_toolchain = "//build/toolchain/win:x64"
68 }
69 gcp_portmon64_label = ":port_monitor_dll($gcp_portmon64_toolchain)"
70
71 gcp_portmon64_out_dir = get_label_info(gcp_portmon64_label, "root_out_dir")
72 sources = [
73 "$gcp_portmon64_out_dir/gcp_portmon64.dll",
74 ]
75 outputs = [
76 "$root_out_dir/{{source_file_part}}",
77 ]
78 deps = [
79 gcp_portmon64_label,
80 ]
81 }
82 }
83
36 source_set("lib") { 84 source_set("lib") {
37 sources = [ 85 sources = [
38 "port_monitor.cc", 86 "port_monitor.cc",
39 "port_monitor.h", 87 "port_monitor.h",
40 ] 88 ]
41 89
42 deps = [ 90 deps = [
43 "//base", 91 "//base",
44 "//chrome/common:constants", 92 "//chrome/common:constants",
45 "//chrome/installer/launcher_support", 93 "//chrome/installer/launcher_support",
46 "//cloud_print/common", 94 "//cloud_print/common",
47 "//cloud_print/virtual_driver/win", 95 "//cloud_print/virtual_driver/win",
48 ] 96 ]
49 } 97 }
50 98
51 process_version_rc_template("resources") { 99 process_version_rc_template("resources") {
52 sources = [ 100 sources = [
53 "../gcp_portmon_dll.ver", 101 "../gcp_portmon_dll.ver",
54 ] 102 ]
55 103
56 # Note: target_gen_dir will be different for each toolchain so the output 104 # Note: target_gen_dir will be different for each toolchain so the output
57 # name doesn't need mangling. 105 # name doesn't need mangling.
58 output = "$target_gen_dir/gcp_portmon_dll.rc" 106 output = "$target_gen_dir/gcp_portmon_dll.rc"
59 } 107 }
OLDNEW
« no previous file with comments | « cloud_print/virtual_driver/win/install/setup.cc ('k') | cloud_print/virtual_driver/win/port_monitor/port_monitor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698