 Chromium Code Reviews
 Chromium Code Reviews Issue 1930773005:
  Update running Chromium trybots on Skia CLs docs.  (Closed) 
  Base URL: https://skia.googlesource.com/skia.git@master
    
  
    Issue 1930773005:
  Update running Chromium trybots on Skia CLs docs.  (Closed) 
  Base URL: https://skia.googlesource.com/skia.git@master| OLD | NEW | 
|---|---|
| 1 Multiple repo Chromium trybots | 1 Multiple repo Chromium trybots | 
| 2 ============================== | 2 ============================== | 
| 3 | 3 | 
| 4 When a proposed Skia change will require a change in Chromium or Blink it is | 4 When a proposed Skia change will require a change in Chromium or Blink it is | 
| 5 often helpful to locally create the Chromium and Blink changes and test with the | 5 often helpful to locally create the Chromium and Blink changes and test with the | 
| 6 proposed Skia change. This often happens with Skia API changes and changes | 6 proposed Skia change. This often happens with Skia API changes and changes | 
| 7 which affect Blink layout tests. While simple to do locally, this explains how | 7 which affect Blink layout tests. While simple to do locally, this explains how | 
| 8 to do so on the Chromium trybots. | 8 to do so on the Chromium trybots. | 
| 9 | 9 | 
| 10 The basic idea is to make your Chromium and Blink change in the usual way, but | 10 Skia only changes | 
| 11 then pull in other changes by modifying the \<chromium>/src/DEPS file. | 11 ----------------- | 
| 12 If the Skia patch is already in Rietveld and there are no associated Chromium | |
| 13 changes, then it is possible to just run the Chromium trybots. This will apply | |
| 14 the Skia patch and run the bot. | |
| 12 | 15 | 
| 13 | 16 Skia and Chromium changes | 
| 14 Rietveld | 17 ------------------------- | 
| 15 -------- | 18 If the Skia patch is already in Rietveld and there are associated Chromium | 
| 16 If the the patch to be applied is to a project already in Chromium (like Skia) | 19 changes, then in the Chromium CL add the following to | 
| 17 and the patch is already in Rietveld, then add the following to | |
| 18 \<chromium>/src/DEPS in the 'hooks' array just before the 'gyp' hook. | 20 \<chromium>/src/DEPS in the 'hooks' array just before the 'gyp' hook. | 
| 19 | 21 | 
| 20 { | 22 { | 
| 21 'name': 'apply_custom_patch', | 23 'name': 'apply_custom_patch', | 
| 22 'pattern': '.', | 24 'pattern': '.', | 
| 23 'action': ['apply_issue', | 25 'action': ['apply_issue', | 
| 
tandrii(chromium)
2016/04/29 12:50:19
hey, that's a neat hack!
 | |
| 24 '--root_dir', 'src/third_party/skia', | 26 '--root_dir', 'src/third_party/skia', | 
| 25 '--issue', '1873923002', | 27 '--issue', '1873923002', | 
| 26 '--patchset', '160001', | 28 '--patchset', '160001', | 
| 27 '--server', 'https://codereview.chromium.org', | 29 '--server', 'https://codereview.chromium.org', | 
| 28 '--force', | 30 '--force', | 
| 29 '--ignore_deps', | 31 '--ignore_deps', | 
| 30 '-v', | 32 '-v', | 
| 31 '-v', | 33 '-v', | 
| 32 '--no-auth', | 34 '--no-auth', | 
| 33 '--blacklist', 'DEPS' | 35 '--blacklist', 'DEPS' | 
| 34 ], | 36 ], | 
| 35 }, | 37 }, | 
| 36 | 38 | 
| 37 Modify the 'issue' and 'patchset' to the appropriate values. | 39 Modify the 'issue' and 'patchset' to the appropriate values. | 
| 38 If this is for a project other than Skia, update the 'root_dir' and 'server'. | 40 If this is for a project other than Skia, update the 'root_dir' and 'server'. | 
| 39 Note that this can be used multiple times to apply multiple issues. | 41 Note that this can be used multiple times to apply multiple issues. | 
| 40 | 42 | 
| 41 To find the patchset number in Rietveld use the URL of the '[raw]' (old UI) or | 43 To find the patchset number in Rietveld use the URL of the '[raw]' (old UI) or | 
| 42 'Raw Patch' (new UI) link on the desired patch. The last segment of this URL | 44 'Raw Patch' (new UI) link on the desired patch. The last segment of this URL | 
| 43 has the form 'issue\<issue>_\<patchset>.diff'. | 45 has the form 'issue\<issue>_\<patchset>.diff'. | 
| 44 | 46 | 
| 45 An example of this being used can be seen at | 47 An example of this being used can be seen at | 
| 46 https://crrev.com/1877673002/#ps120001 . | 48 https://crrev.com/1877673002/#ps120001 . | 
| 47 | 49 | 
| 48 Finally, run the post-sync hooks again to update the Skia source code | 50 To test locally, run `gclient runhooks` to update the Skia source code. | 
| 49 | |
| 50 $ gclient runhooks | |
| 51 | |
| 52 Note that if your local skia patch in `third_party/skia` isn't clean (e.g., you | 51 Note that if your local skia patch in `third_party/skia` isn't clean (e.g., you | 
| 53 already applied some patch to it), then `gclient runhooks` won't successfully | 52 already applied some patch to it), then `gclient runhooks` won't successfully | 
| 54 run. In that case, run `git reset --hard` inside `third_party/skia` before | 53 run. In that case, run `git reset --hard` inside `third_party/skia` before | 
| 55 `gclient runhooks`. | 54 `gclient runhooks`. | 
| 56 | 55 | 
| 57 External changes not in rietveld | 56 Arbitrary changes | 
| 58 -------------------------------- | 57 ----------------- | 
| 59 If the patch is to files where the above is not possible, then it is still | 58 If the patch is to files where the above is not possible, then it is still | 
| 60 possible to patch the files manually by adding the following to | 59 possible to patch the files manually by adding the following to | 
| 61 \<chromium>/src/DEPS in the 'hooks' array just before the 'gyp' hook. | 60 \<chromium>/src/DEPS in the 'hooks' array just before the 'gyp' hook. | 
| 62 | 61 | 
| 63 { | 62 { | 
| 64 'name': 'apply_custom_patch', | 63 'name': 'apply_custom_patch', | 
| 65 'pattern': '.', | 64 'pattern': '.', | 
| 66 'action': ['python', | 65 'action': ['python', | 
| 67 '-c', 'from distutils.dir_util import copy_tree; copy_tree("s rc/patch/", "src/");' | 66 '-c', 'from distutils.dir_util import copy_tree; copy_tree("s rc/patch/", "src/");' | 
| 68 ], | 67 ], | 
| 69 }, | 68 }, | 
| 70 | 69 | 
| 71 Then, copy all 'out of tree' files into \<chromium>/src/patch/, using the same | 70 Then, copy all 'out of tree' files into \<chromium>/src/patch/, using the same | 
| 72 directory structure used by Chromium. When 'gclient runhooks' is run, the files | 71 directory structure used by Chromium. When 'gclient runhooks' is run, the files | 
| 73 in \<chromium>/src/patch/ will be copied to and overwrite corresponding files in | 72 in \<chromium>/src/patch/ will be copied to and overwrite corresponding files in | 
| 74 \<chromium>/src/. For example, if changing \<skia>/include/core/SkPath.h, place | 73 \<chromium>/src/. For example, if changing \<skia>/include/core/SkPath.h, place | 
| 75 a copy of the modified SkPath.h at | 74 a copy of the modified SkPath.h at | 
| 76 \<chromium>/src/patch/third_party/skia/include/core/SkPath.h. | 75 \<chromium>/src/patch/third_party/skia/include/core/SkPath.h. | 
| 77 | 76 | 
| 78 An example of this being used can be seen at | 77 An example of this being used can be seen at | 
| 79 https://crrev.com/1866773002/#ps20001 . | 78 https://crrev.com/1866773002/#ps20001 . | 
| 80 | 79 | 
| 81 | 80 | 
| 82 Try the patch | 81 Try the patch | 
| 83 ------------- | 82 ------------- | 
| 84 After committing these \<chromium>/src/DEPS and \<chromium>/src/patch/ changes | 83 After committing a \<chromium>/src/DEPS or \<chromium>/src/patch/ change | 
| 85 locally, 'git cl upload' can be used in the usual way. Be sure to add | 84 locally, 'git cl upload' can be used in the usual way. Be sure to add | 
| 86 'COMMIT=false' to the issue description to avoid accidentally checking it in. | 85 'COMMIT=false' to the issue description to avoid accidentally checking it in. | 
| OLD | NEW |