Removing obsolete Chromoting docs
The CRD backend services have changed since these were originally written such that it is no longer possible to build a 3P version of the product. I'm removing these docs to prevent anyone from spending their time trying to get a 3P build or CRD working. BUG=b:181506121 Change-Id: Id881dc520ee891fe63c3e677efea0085a1f44881 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2970734 Auto-Submit: Joe Downing <joedow@chromium.org> Commit-Queue: Jamie Walch <jamiewalch@chromium.org> Reviewed-by: Jamie Walch <jamiewalch@chromium.org> Cr-Commit-Position: refs/heads/master@{#893871}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
5a27a59b9c
commit
72674b0624
@ -278,8 +278,6 @@ used when committed.
|
||||
how to debug Java and/or C/C++ code running on Android.
|
||||
* [Android Logging](android_logging.md) - How Chrome's logging API works with
|
||||
`android.util.Log` on Android, and usage guidelines.
|
||||
* [Chromoting Android Hacking](chromoting_android_hacking.md) - Viewing the
|
||||
logs and debugging the Chrome Remote Desktop Android client.
|
||||
* [Android Java Static Analysis](../build/android/docs/lint.md) - Catching
|
||||
Java related issues at compile time with the 'lint' tool.
|
||||
* [Java Code Coverage](../build/android/docs/coverage.md) - Collecting code
|
||||
@ -421,6 +419,5 @@ used when committed.
|
||||
* [Linux PID Namespace Support](linux/pid_namespace_support.md)
|
||||
* [Vanilla msysgit workflow](vanilla_msysgit_workflow.md) - A workflow for
|
||||
using mostly vanilla git on Windows.
|
||||
* [Old Chromoting Build Instructions](old_chromoting_build_instructions.md)
|
||||
* [Old Options](chrome_settings.md) - Pre-Material Design chrome://settings
|
||||
notes.
|
||||
|
@ -1,154 +0,0 @@
|
||||
# Chromoting Android Hacking
|
||||
|
||||
This guide, which is meant to accompany the
|
||||
[compilation guide](old_chromoting_build_instructions.md), explains the process of
|
||||
viewing the logs and debugging the CRD Android client. I'll assume you've
|
||||
already built the APK as described in the aforementioned guide, that you're in
|
||||
the `src/` directory, and that your binary is at
|
||||
`out/Release/apks/Chromoting.apk`. Additionally, you should have installed the
|
||||
app on at least one (still) connected device.
|
||||
|
||||
[TOC]
|
||||
|
||||
## Viewing logging output
|
||||
|
||||
In order to access LogCat and view the app's logging output, we need to launch
|
||||
the Android Device Monitor. Run `third_party/android_sdk/public/tools/monitor`
|
||||
and select the desired device under `Devices`. Using the app as normal will
|
||||
display log messages to the `LogCat` pane.
|
||||
|
||||
## Attaching debuggers for Java code
|
||||
|
||||
### Eclipse
|
||||
|
||||
1. Go to https://developer.android.com/sdk/index.html and click "Download the
|
||||
SDK ADT Bundle for Linux"
|
||||
1. Configure eclipse
|
||||
1. Select General > Workspace from the tree on the left.
|
||||
1. Uncheck Refresh workspace on startup (if present)
|
||||
1. Uncheck Refresh using native hooks or polling (if present)
|
||||
1. Disable build before launching
|
||||
1. Select Run/Debug > Launching
|
||||
1. Uncheck Build (if required) before launching
|
||||
1. Create a project
|
||||
1. Select File > New > Project... from the main menu.
|
||||
1. Choose Java/Java Project
|
||||
1. Eclipse should have generated .project and perhaps a .classpath file in
|
||||
your <project root>/src/ directory.
|
||||
1. Replace/Add the .classpath file with the content from Below. Remember
|
||||
that the path field should be the location of the chromium source
|
||||
relative to the current directory of your project.
|
||||
|
||||
```xml
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" path="net/test/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="net/android/java/src"/>
|
||||
<classpathentry kind="src" path="net/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="base/test/android/java/src"/>
|
||||
<classpathentry kind="src" path="base/test/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="base/android/jni_generator/java/src"/>
|
||||
<classpathentry kind="src" path="base/android/java/src"/>
|
||||
<classpathentry kind="src" path="base/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="components/cronet/android/java/src"/>
|
||||
<classpathentry kind="src" path="components/cronet/android/sample/src"/>
|
||||
<classpathentry kind="src" path="components/cronet/android/sample/javatests/src"/>
|
||||
<classpathentry kind="src" path="components/autofill/core/browser/android/java/src"/>
|
||||
<classpathentry kind="src" path="components/embedder_support/android/java/src"/>
|
||||
<classpathentry kind="src" path="components/dom_distiller/android/java/src"/>
|
||||
<classpathentry kind="src" path="components/navigation_interception/android/java/src"/>
|
||||
<classpathentry kind="src" path="ui/android/java/src"/>
|
||||
<classpathentry kind="src" path="media/base/android/java/src"/>
|
||||
<classpathentry kind="src" path="chrome/test/android/unit_tests_apk/src"/>
|
||||
<classpathentry kind="src" path="chrome/test/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="chrome/test/chromedriver/test/webview_shell/java/src"/>
|
||||
<classpathentry kind="src" path="chrome/common/extensions/docs/examples/extensions/irc/servlet/src"/>
|
||||
<classpathentry kind="src" path="chrome/android/java/src"/>
|
||||
<classpathentry kind="src" path="chrome/android/uiautomator_tests/src"/>
|
||||
<classpathentry kind="src" path="chrome/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="sync/test/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="sync/android/java/src"/>
|
||||
<classpathentry kind="src" path="sync/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="mojo/public/java/base/src"/>
|
||||
<classpathentry kind="src" path="mojo/public/java/bindings/src"/>
|
||||
<classpathentry kind="src" path="mojo/public/java/system/javatests/src"/>
|
||||
<classpathentry kind="src" path="mojo/public/java/system/src"/>
|
||||
<classpathentry kind="src" path="testing/android/java/src"/>
|
||||
<classpathentry kind="src" path="printing/android/java/src"/>
|
||||
<classpathentry kind="src" path="tools/binary_size/java/src"/>
|
||||
<classpathentry kind="src" path="tools/android/memconsumer/java/src"/>
|
||||
<classpathentry kind="src" path="remoting/android/java/src"/>
|
||||
<classpathentry kind="src" path="remoting/android/apk/src"/>
|
||||
<classpathentry kind="src" path="remoting/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/voice_engine/test/android/android_test/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/modules/video_capture/android/java/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/modules/video_render/android/java/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/modules/audio_device/test/android/audio_device_android_test/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/modules/audio_device/android/java/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/examples/android/media_demo/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/examples/android/opensl_loopback/src"/>
|
||||
<classpathentry kind="src" path="third_party/webrtc/video_engine/test/auto_test/android/src"/>
|
||||
<classpathentry kind="src" path="third_party/libjingle/source/talk/app/webrtc/java/src"/>
|
||||
<classpathentry kind="src" path="third_party/libjingle/source/talk/app/webrtc/javatests/src"/>
|
||||
<classpathentry kind="src" path="third_party/libjingle/source/talk/examples/android/src"/>
|
||||
<classpathentry kind="src" path="android_webview/java/src"/>
|
||||
<classpathentry kind="src" path="android_webview/test/shell/src"/>
|
||||
<classpathentry kind="src" path="android_webview/unittestjava/src"/>
|
||||
<classpathentry kind="src" path="android_webview/javatests/src"/>
|
||||
<classpathentry kind="src" path="chrome/test/android/browsertests_apk/src"/>
|
||||
<classpathentry kind="src" path="components/test/android/browsertests_apk/src"/>
|
||||
<classpathentry kind="src" path="content/public/test/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="content/public/android/java/src"/>
|
||||
<classpathentry kind="src" path="content/public/android/javatests/src"/>
|
||||
<classpathentry kind="src" path="content/shell/android/browsertests_apk/src"/>
|
||||
<classpathentry kind="src" path="content/shell/android/java/src"/>
|
||||
<classpathentry kind="src" path="content/shell/android/shell_apk/src"/>
|
||||
<classpathentry kind="src" path="content/shell/android/javatests/src"/>
|
||||
<classpathentry kind="lib" path="third_party/android_sdk/public/platforms/android-27/data/layoutlib.jar"/>
|
||||
<classpathentry kind="lib" path="third_party/android_sdk/public/platforms/android-27/android.jar"/>
|
||||
<classpathentry kind="output" path="out/bin"/>
|
||||
</classpath>
|
||||
```
|
||||
|
||||
1. Obtain the debug port
|
||||
1. Go to Window > Open Perspective > DDMS
|
||||
1. In order for the app org.chromium.chromoting to show up, you must build
|
||||
Debug instead of Retail
|
||||
1. Note down the port number, should be 8600 or 8700
|
||||
1. Setup a debug configuration
|
||||
1. Go to Window > Open Perspective > Debug
|
||||
1. Run > Debug > Configurations
|
||||
1. Select "Remote Java Application" and click "New"
|
||||
1. Put Host: localhost and Port: <the port from DDMS>
|
||||
1. Hit Debug
|
||||
1. Configure source path
|
||||
1. Right click on the Chromoting [Application](Remoting.md) and select Edit
|
||||
source Lookup Path
|
||||
1. Click "Add" and select File System Directory
|
||||
1. Select the location of your chromium checkout,
|
||||
e.g. <project root>/src/remoting/android
|
||||
1. Debugging
|
||||
1. To add a breakpoint, simply open the source file and hit Ctrl+Shift+B to
|
||||
toggle the breakpoint. Happy hacking.
|
||||
|
||||
### Command line debugger
|
||||
|
||||
With the Android Device Monitor open, look under `Devices`, expand the entry for
|
||||
the device on which you want to debug, and select the entry for
|
||||
`org.chromium.chromoting` (it must already be running). This forwards the JVM
|
||||
debugging connection to your local port 8700. In your shell, do `$ jdb -attach
|
||||
localhost:8700`.
|
||||
|
||||
## Attaching GDB to debug native code
|
||||
|
||||
The Chromium build system provides a convenience wrapper script that can be used
|
||||
to easily launch GDB. Run
|
||||
|
||||
```shell
|
||||
$ build/android/adb_gdb --package-name=org.chromium.chromoting \
|
||||
--activity=.Chromoting --start
|
||||
```
|
||||
|
||||
Note that if you have multiple devices connected, you must export
|
||||
`ANDROID_SERIAL` to select one; set it to the serial number of the desired
|
||||
device as output by `$ adb devices`.
|
@ -1,134 +0,0 @@
|
||||
# Chromoting Build Instructions
|
||||
|
||||
Chromoting, also known as
|
||||
[Chrome Remote Desktop](https://support.google.com/chrome/answer/1649523),
|
||||
allows one to remotely control a distant machine, all from within the Chromium
|
||||
browser. Its source code is located in the `remoting/` folder in the Chromium
|
||||
codebase. For the sake of brevity, we'll assume that you already have a
|
||||
pre-built copy of Chromium (or Chrome) installed on your development computer.
|
||||
|
||||
[TOC]
|
||||
|
||||
## Obtain API keys
|
||||
|
||||
Before you can compile the code, you must obtain an API key to allow it to
|
||||
access the federated Chrome Remote Desktop API.
|
||||
|
||||
1. Join the chromium-dev list, which can be found at
|
||||
https://groups.google.com/a/chromium.org/forum/#!forum/chromium-dev. (This
|
||||
step is required in order to gain access to the Chromoting API.)
|
||||
1. Visit the Google APIs console at https://code.google.com/apis/console.
|
||||
1. Use the `API Project` dropdown to create a new project with a name of
|
||||
your choice.
|
||||
1. Click on `APIs & Auth > APIs`.
|
||||
1. Search for `Chrome Remote Desktop API`.
|
||||
1. Click on the `Chrome Remote Desktop API` search result.
|
||||
1. Click on `Enable API`.
|
||||
1. Click on `APIs & Auth > Credentials`.
|
||||
1. Click on `Add Credentials`.
|
||||
1. Choose `OAuth 2.0 client ID`.
|
||||
1. Choose `Chrome App`.
|
||||
1. Under application id, enter `ljacajndfccfgnfohlgkdphmbnpkjflk`.
|
||||
|
||||
## Obtain Chromium code
|
||||
|
||||
If you've already checked out a copy of the browser's codebase, you can skip
|
||||
this section, although you'll still need to run `gclient runhooks` to ensure you
|
||||
build using the API keys you just generated.
|
||||
|
||||
1. [Install the build dependencies](linux/build_instructions_prerequisites.md).
|
||||
1. Install the depot\_tools utilities, a process that is documented at
|
||||
https://dev.chromium.org/developers/how-tos/install-depot-tools.
|
||||
1. Download the Chromium source code by running:
|
||||
`$ fetch chromium --nosvn=True`
|
||||
|
||||
## Build and install the Linux host service
|
||||
|
||||
If you want to remote into a (Debian-based) GNU/Linux host, follow these steps
|
||||
to compile and install the host service on that system. As of the time of
|
||||
writing, you must compile from source because no official binary package is
|
||||
being distributed.
|
||||
|
||||
1. Start in the `src/` directory that contains your checkout of the Chromium
|
||||
code.
|
||||
1. Build the Chromoting host binaries:
|
||||
|
||||
```shell
|
||||
$ autoninja -C out/Release remoting_me2me_host remoting_start_host \
|
||||
remoting_native_messaging_host remoting_native_messaging_manifests
|
||||
```
|
||||
|
||||
(`autoninja` is a wrapper that automatically provides optimal values for the
|
||||
arguments passed to `ninja`.)
|
||||
|
||||
1. When the build finishes, move into the installer directory:
|
||||
`$ cd remoting/host/installer/`
|
||||
1. Generate a DEB package for your system's package manager:
|
||||
`$ linux/build-deb.sh`
|
||||
1. Install the package on your system: `$ sudo dpkg -i *.deb`
|
||||
1. The next time you use the Chromoting extension from your browser, it should
|
||||
detect the presence of the host service and offer you the option to
|
||||
`Enable remote connections`.
|
||||
1. If the Web app doesn't properly detect the host process, you may need to
|
||||
create a symlink to help the plugin find the native messaging host:
|
||||
`$ sudo ln -s /etc/opt/chrome /etc/chromium`
|
||||
|
||||
(NB: If you compile the host service from source and expect to configure it
|
||||
using the browser extension, you must also compile the latter from source.
|
||||
Otherwise, the package signing keys will not match and the Web app's OAuth2
|
||||
token will not be valid within the host process.)
|
||||
|
||||
## Build and install the Chrome packaged app
|
||||
|
||||
The Web app is the Chromoting system's main user interface, and allows you to
|
||||
connect to existing hosts as well as set up the host process on the machine
|
||||
you're currently sitting at. Once built, it must be installed into your browser
|
||||
as an extension.
|
||||
|
||||
1. Start in the `src/` directory that contains your checkout of the Chromium
|
||||
code.
|
||||
1. Build the browser extension (Be sure to replace the substitutions denoted by
|
||||
angled braces.):
|
||||
|
||||
```shell
|
||||
$ GOOGLE_CLIENT_ID_REMOTING_IDENTITY_API=<client id> \
|
||||
autoninja -C out/Release remoting_webapp
|
||||
```
|
||||
|
||||
1. Install the extension into your Chromium (or Chrome) browser:
|
||||
1. Visit the settings page [chrome://extensions].
|
||||
1. If it is unchecked, tick the `Developer mode` box.
|
||||
1. Click `Load unpacked extension...`, then navigate to
|
||||
`out/Release/remoting/remoting.webapp.v2/` within your code checkout.
|
||||
1. Confirm the installation, open a new tab, and click the new app's
|
||||
Chromoting icon.
|
||||
1. Complete the account authorization step, signing into your Google
|
||||
account if you weren't already.
|
||||
|
||||
## Build and install the Android client
|
||||
|
||||
If you want to use your Android device to connect to your Chromoting hosts,
|
||||
follow these steps to install the client app on it. Note that this is in the
|
||||
very early stages of development. At the time of writing, you must compile from
|
||||
source because no official version is being distributed.
|
||||
|
||||
1. Follow all the instructions under the `Getting the code` and
|
||||
`Install prerequisites` sections of:
|
||||
https://www.chromium.org/developers/how-tos/android-build-instructions
|
||||
1. Move into the `src/` directory that contains your checkout of the Chromium
|
||||
code.
|
||||
1. Build the Android app: `$ autoninja -C out/Release remoting_apk`
|
||||
1. Connect your device and set up USB debugging:
|
||||
1. Plug your device in via USB.
|
||||
1. Open the Settings app and look for the `Developer options` choice.
|
||||
1. If there is no such entry, open `About phone`, tap `Build number`
|
||||
7 times, and look again.
|
||||
1. Under `Developer options`, toggle the main switch to `ON` and enable
|
||||
`USB debugging`.
|
||||
1. On your machine and still in the `src/` directory, run:
|
||||
`$ build/android/adb_install_apk.py --apk=out/Release/apks/Chromoting.apk`
|
||||
1. If your Android device prompts you to accept the host's key, do so.
|
||||
1. The app should now be listed as Chromoting in your app drawer.
|
||||
|
||||
See the [chromoting_android_hacking.md] guide for instructions on viewing the
|
||||
Android app's log and attaching a debugger.
|
Reference in New Issue
Block a user