Commit 8b728444 authored by Robbie McElrath's avatar Robbie McElrath Committed by Chromium LUCI CQ

Enable 'gn check' in cups_proxy and ipp_parser

This CL adds some missing dependencies to //chrome/services/cups_proxy,
and moves ipp_parser_service.* to //chrome/services/ipp_parser/public
because it needs to depend on code in the browser process, which targets
in //chrome/services/ipp_parser shouldn't.

Bug: 949535
Change-Id: Ia49760580de1dc6e8ff2e0c743fde0369d625084
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2583215Reviewed-by: default avatarLuum Habtemariam <luum@chromium.org>
Reviewed-by: default avatarErik Staab <estaab@chromium.org>
Commit-Queue: Robbie McElrath <rmcelrath@chromium.org>
Cr-Commit-Position: refs/heads/master@{#843271}
parent 4eabd682
...@@ -76,9 +76,6 @@ no_check_targets = [ ...@@ -76,9 +76,6 @@ no_check_targets = [
"//chrome/browser/storage_access_api:*", # 2 errors "//chrome/browser/storage_access_api:*", # 2 errors
"//chrome/browser/touch_to_fill/android:*", # 8 errors "//chrome/browser/touch_to_fill/android:*", # 8 errors
"//chrome/notification_helper:*", # 4 errors "//chrome/notification_helper:*", # 4 errors
"//chrome/services/cups_proxy/public/cpp:*", # 2 errors
"//chrome/services/cups_proxy:*", # 6 errors
"//chrome/services/ipp_parser:*", # 1 error
"//chrome/services/removable_storage_writer:*", # 1 error "//chrome/services/removable_storage_writer:*", # 1 error
"//chrome/services/util_win:*", # 1 error "//chrome/services/util_win:*", # 1 error
"//chrome/test:*", # 2682 errors "//chrome/test:*", # 2682 errors
......
...@@ -31,9 +31,13 @@ source_set("cups_proxy") { ...@@ -31,9 +31,13 @@ source_set("cups_proxy") {
"//base", "//base",
"//chrome/services/cups_proxy/public/cpp", "//chrome/services/cups_proxy/public/cpp",
"//chrome/services/cups_proxy/public/mojom", "//chrome/services/cups_proxy/public/mojom",
"//chrome/services/ipp_parser", "//chrome/services/ipp_parser/public/cpp",
"//chrome/services/ipp_parser/public/cpp/browser",
"//chromeos",
"//chromeos/dbus", "//chromeos/dbus",
"//chromeos/dbus/cups_proxy",
"//net", "//net",
"//net/traffic_annotation",
] ]
public_deps = [ "//printing" ] public_deps = [ "//printing" ]
...@@ -48,6 +52,8 @@ static_library("test_support") { ...@@ -48,6 +52,8 @@ static_library("test_support") {
"fake_cups_proxy_service_delegate.h", "fake_cups_proxy_service_delegate.h",
] ]
deps = [ "//chromeos" ]
public_deps = [ ":cups_proxy" ] public_deps = [ ":cups_proxy" ]
} }
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#include "chrome/services/cups_proxy/public/cpp/ipp_messages.h" #include "chrome/services/cups_proxy/public/cpp/ipp_messages.h"
#include "chrome/services/cups_proxy/public/cpp/type_conversions.h" #include "chrome/services/cups_proxy/public/cpp/type_conversions.h"
#include "chrome/services/cups_proxy/socket_manager.h" #include "chrome/services/cups_proxy/socket_manager.h"
#include "chrome/services/ipp_parser/ipp_parser_service.h" #include "chrome/services/ipp_parser/public/cpp/browser/ipp_parser_launcher.h"
#include "chrome/services/ipp_parser/public/cpp/ipp_converter.h" #include "chrome/services/ipp_parser/public/cpp/ipp_converter.h"
#include "mojo/public/cpp/bindings/receiver.h" #include "mojo/public/cpp/bindings/receiver.h"
#include "mojo/public/cpp/bindings/remote.h" #include "mojo/public/cpp/bindings/remote.h"
......
...@@ -18,7 +18,10 @@ source_set("cpp") { ...@@ -18,7 +18,10 @@ source_set("cpp") {
"type_conversions.h", "type_conversions.h",
] ]
deps = [ "//base" ] deps = [
"//base",
"//chromeos",
]
public_deps = [ public_deps = [
"//chrome/services/ipp_parser/public/cpp", "//chrome/services/ipp_parser/public/cpp",
...@@ -34,6 +37,7 @@ source_set("unit_tests") { ...@@ -34,6 +37,7 @@ source_set("unit_tests") {
deps = [ deps = [
":cpp", ":cpp",
"//base", "//base",
"//chromeos",
"//testing/gmock", "//testing/gmock",
"//testing/gtest", "//testing/gtest",
] ]
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
#include "net/http/http_response_headers.h" #include "net/http/http_response_headers.h"
#include "net/http/http_util.h" #include "net/http/http_util.h"
#include "net/socket/unix_domain_client_socket_posix.h" #include "net/socket/unix_domain_client_socket_posix.h"
#include "net/traffic_annotation/network_traffic_annotation_test_helper.h" #include "net/traffic_annotation/network_traffic_annotation.h"
namespace cups_proxy { namespace cups_proxy {
namespace { namespace {
...@@ -193,7 +193,7 @@ void SocketManagerImpl::Write() { ...@@ -193,7 +193,7 @@ void SocketManagerImpl::Write() {
int result = socket_->Write( int result = socket_->Write(
in_flight_->io_buffer.get(), in_flight_->io_buffer->BytesRemaining(), in_flight_->io_buffer.get(), in_flight_->io_buffer->BytesRemaining(),
base::BindOnce(&SocketManagerImpl::OnWrite, weak_factory_.GetWeakPtr()), base::BindOnce(&SocketManagerImpl::OnWrite, weak_factory_.GetWeakPtr()),
TRAFFIC_ANNOTATION_FOR_TESTS /* Unused NetworkAnnotation */); net::DefineNetworkTrafficAnnotation("unused", ""));
if (result != net::ERR_IO_PENDING) { if (result != net::ERR_IO_PENDING) {
return OnWrite(result); return OnWrite(result);
......
...@@ -9,23 +9,16 @@ import("//printing/buildflags/buildflags.gni") ...@@ -9,23 +9,16 @@ import("//printing/buildflags/buildflags.gni")
enable_service = use_cups && is_chromeos_ash enable_service = use_cups && is_chromeos_ash
source_set("ipp_parser") { source_set("ipp_parser") {
sources = [ sources = [ "ipp_parser.h" ]
"ipp_parser.h",
"ipp_parser_service.cc",
"ipp_parser_service.h",
]
deps = [ deps = [
"//base", "//base",
"//chrome:strings",
"//mojo/public/cpp/bindings",
"//net", "//net",
] ]
public_deps = [ public_deps = [
"//chrome/services/ipp_parser/public/mojom", "//chrome/services/ipp_parser/public/mojom",
"//mojo/public/mojom/base", "//mojo/public/mojom/base",
"//printing",
] ]
# We stub the implementation if libCUPS is not present. # We stub the implementation if libCUPS is not present.
......
# Copyright 2020 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/config/chromeos/ui_mode.gni")
import("//printing/buildflags/buildflags.gni")
if (use_cups) {
source_set("browser") {
sources = [
"ipp_parser_launcher.cc",
"ipp_parser_launcher.h",
]
deps = [
"//base",
"//chrome:strings",
"//chrome/services/ipp_parser/public/mojom",
"//content/public/browser",
]
configs += [ "//printing:cups" ]
}
}
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
#include "chrome/services/ipp_parser/ipp_parser_service.h" #include "chrome/services/ipp_parser/public/cpp/browser/ipp_parser_launcher.h"
#include "base/no_destructor.h" #include "base/no_destructor.h"
#include "chrome/grit/generated_resources.h" #include "chrome/grit/generated_resources.h"
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
#ifndef CHROME_SERVICES_IPP_PARSER_IPP_PARSER_SERVICE_H_ #ifndef CHROME_SERVICES_IPP_PARSER_PUBLIC_CPP_BROWSER_IPP_PARSER_LAUNCHER_H_
#define CHROME_SERVICES_IPP_PARSER_IPP_PARSER_SERVICE_H_ #define CHROME_SERVICES_IPP_PARSER_PUBLIC_CPP_BROWSER_IPP_PARSER_LAUNCHER_H_
#include "base/callback.h" #include "base/callback.h"
#include "chrome/services/ipp_parser/public/mojom/ipp_parser.mojom.h" #include "chrome/services/ipp_parser/public/mojom/ipp_parser.mojom.h"
...@@ -19,4 +19,4 @@ mojo::PendingRemote<mojom::IppParser> LaunchIppParser(); ...@@ -19,4 +19,4 @@ mojo::PendingRemote<mojom::IppParser> LaunchIppParser();
} // namespace ipp_parser } // namespace ipp_parser
#endif // CHROME_SERVICES_IPP_PARSER_IPP_PARSER_SERVICE_H_ #endif // CHROME_SERVICES_IPP_PARSER_PUBLIC_CPP_BROWSER_IPP_PARSER_LAUNCHER_H_
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment