summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2020-07-01 22:46:51 +0200
committerDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2020-08-28 17:28:29 +0200
commite4f91d6bd906558cb9f6ae32ac67cb32501d1f24 (patch)
treebb0b1da3502b214b9f702d3f97223f771aa619ce
parentb1d0b1b0d82978359e80c468cc2a89ae42850a80 (diff)
downloadmanifest-e4f91d6bd906558cb9f6ae32ac67cb32501d1f24.tar.gz
manifest-e4f91d6bd906558cb9f6ae32ac67cb32501d1f24.tar.bz2
manifest-e4f91d6bd906558cb9f6ae32ac67cb32501d1f24.zip
Use Replicant mirrors for AOSP repositories
We need to mirror AOSP repositories to make sure that we don't loose the source code. The git hosting infrastructure has not been adjusted yet to automatically redirect repositories like /device/generic/qemu to device_generic_qemu in /mirrors/AOSP/. The redirect is manual for now, which means that for each new repository that you add you must not forget to do the redirection in /etc/apache2/git-redirects/aosp-mirror.conf else it will not work. To make an automatic redirection we need to change the '/' in a '_', but also find where to stop the match. The URL itself doesn't have enough information to be able to do that correctly. With a simple rule like 'RewriteRule "^/mirrors/AOSP/(.*)/(.+)" "/mirrors/AOSP/$1_$2" [R]' device/generic/qemu/tree/ would be rewritten as device_generic_qemu_tree instead of device_generic_qemu/tree and using heuristics to workaround that is probably not a good idea as it would be way to fragile. Currently, the static list of redirect has been generated with the following command: ls -d *.git | sed 's#\.git$##' | \ awk '{save=$1 ; gsub("_", "/", $1); printf("Redirect /mirrors/AOSP/%s /mirrors/AOSP/%s\n", $1, save); }' So it should be possible to generate to convert that to a single set of regular expressions that relies on checking if specific directories do exist or not. However this is not that simple as we want to avoid potential bugs that only appear in corner case and that could take a lot of time to debug. For instance if the device_generic_qemu.git directory is matched in the file system, the regex should stop converting '/' in '_', however the regex needs to start to match from the right as we don't want to introduce bugs in the unlikely case where we have something like the following repositories (instead of eclipse-build-deps): - platform_prebuilts_eclipse - platform_prebuilts_eclipse_build_deps Another way would be to use inotify/fanotify scripts to generate the mapping automatically. Having something that works would enable people not to have to learn the details on how this system work, especially if they are not aware it exists and have to learn that during days of debugging without even having ssh access. Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
-rw-r--r--default.xml3
1 files changed, 1 insertions, 2 deletions
diff --git a/default.xml b/default.xml
index 010da40..202e66d 100644
--- a/default.xml
+++ b/default.xml
@@ -14,8 +14,7 @@
fetch="ssh://git@github.com" />
<remote name="aosp"
- fetch="https://android.googlesource.com"
- review="android-review.googlesource.com"
+ fetch="../../mirrors/AOSP"
revision="refs/tags/android-10.0.0_r37" />
<default revision="refs/heads/lineage-17.1"