Opened 4 months ago

Last modified 2 weeks ago

#26693 new task

Integrate Tor Browser for Android into tor-browser-build

Reported by: boklm Owned by: tbb-team
Priority: Very High Milestone:
Component: Applications/Tor Browser Version:
Severity: Normal Keywords: tbb-rbm, tbb-mobile, TBA-a2, TorBrowserTeam201811
Cc: sisbell Actual Points:
Parent ID: #5709 Points:
Reviewer: Sponsor: Sponsor8

Description

The Tor Browser Hacking Guide has some instructions for manually building Orfox:
https://trac.torproject.org/projects/tor/wiki/doc/TorBrowser/Hacking#BuildingOrfox

We need to integrate the build of Orfox and all components of Tor Browser for Android into tor-browser-build.

Child Tickets

TicketStatusOwnerSummaryComponent
#26695closedtbb-teamList components required to build Tor Browser for AndroidApplications/Tor Browser
#26696closedtbb-teamAdd definition for new platform in rbm.confApplications/Tor Browser
#26697closedtbb-teamAdd Android toolchainApplications/Tor Browser
#26974closedtor-gitadmCreate git repository user/sisbell/tor-browser-buildInternal Services/Service - git
#26975closedtbb-teamAdd Mobile Branding for Tor BrowserApplications/Tor Browser
#26976closedtbb-teamHardening Wrapper Removed in Debian StretchApplications/Tor Browser
#26977closedtbb-teamDecide which ABIs to support for AndroidApplications/Tor Browser
#27438closedtbb-teamAndroid Gradle Build DownloadsApplications/Tor Browser
#27439closedtbb-teamConfigure Rust compiler to target Android PlatformApplications/Tor Browser
#27440closedtbb-teamGCC Build of Android NDKApplications/Tor Browser
#27441closedtbb-teamUpdate Debian Image to use StretchApplications/Tor Browser
#27443closedtbb-teamUpdate Firefox RBM config and build for AndroidApplications/Tor Browser
#27977needs_reviewtbb-teamBuild Orbot with rbm/tor-browser-buildApplications/Tor Browser
#28144closedtbb-teamUpdate projects/tor-browser for AndroidApplications/Tor Browser
#28468closedtbb-teamModify Android toolchain to support OrbotApplications/Tor Browser
#28469closedtbb-teamFix unsupported libbacktrace in Rust 1.26Applications/Tor Browser
#28470closedtbb-teamAdd fetch gradle dependency script to common projectApplications/Tor Browser
#28472closedtbb-teamAdd Android Makefile RulesApplications/Tor Browser
#28476assignedboklmEnable android nightly buildsApplications/Tor Browser
#28483closedtbb-teamModify Android Toolchain API VersionApplications/Tor Browser

Change History (13)

comment:1 Changed 4 months ago by boklm

Parent ID: #5709

comment:2 Changed 4 months ago by gk

Priority: MediumHigh

Bumping prio.

comment:3 Changed 4 months ago by gk

Keywords: TorBrowserTeam201808 added; TorBrowserTeam201807 removed

Move our tickets to August.

comment:4 Changed 3 months ago by gk

FWIW: One thing which should be kept in mind as well is that the build process must not download random things and it them. I.e. the build itself is supposed to succeed without any network access. I mention this here because I found such network activity while looking at my build log:

24:36.86 /var/tmp/build/firefox-9c58e200f6eb/mach android assemble-app
24:37.33  0:00.31 /var/tmp/build/firefox-9c58e200f6eb/gradlew --console=plain geckoview:generateJNIWrappersForGeneratedOfficialWithGeckoBinariesNoMinApiRelease app:generateJNIWrappersForFennecOfficialWithoutGeckoBinariesNoMinApiPhotonDebug app:assembleOfficialWithoutGeckoBinariesNoMinApiPhotonDebug app:assembleOfficialWithoutGeckoBinariesNoMinApiPhotonDebugAndroidTest -x lint --continue
24:37.46 Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=utf-8
24:37.74 Downloading https://services.gradle.org/distributions/gradle-4.1-all.zip

comment:5 Changed 3 months ago by sisbell

I did a quick count of gradle dependencies (jars + poms). We are looking at 960 downloads we will need to handle.

comment:6 in reply to:  5 ; Changed 3 months ago by boklm

Replying to sisbell:

I did a quick count of gradle dependencies (jars + poms). We are looking at 960 downloads we will need to handle.

How do they handle this in the firefox repository? Do they have a list of dependencies somewhere?

comment:7 in reply to:  6 Changed 3 months ago by sisbell

Replying to boklm:

Replying to sisbell:

I did a quick count of gradle dependencies (jars + poms). We are looking at 960 downloads we will need to handle.

How do they handle this in the firefox repository? Do they have a list of dependencies somewhere?

They are using the sdkmanager which contains the direct dependencies (there are also transitive dependencies downloaded through the gradle process). I have a final count of 186 artifacts to download (after deduping).
We can do this through RBM but it will be a little ugly as we need to download and then copy all artifacts to correct folder structure under a repo directory.

Last edited 3 months ago by sisbell (previous) (diff)

comment:8 Changed 3 months ago by boklm

In build/docs/toolchains.rst they describe how they generate an archive containing the dependencies:
https://dxr.mozilla.org/mozilla-central/source/build/docs/toolchains.rst

However the process for creating this archive does not look very simple.

It also says "Gradle and the downloaded Maven dependencies can be both redistributed publicly" so I'm wondering if we could get a copy of that archive to use it.

comment:9 Changed 3 months ago by gk

Keywords: TorBrowserTeam201809 added; TorBrowserTeam201808 removed

Moving our tickets to September 2018

comment:10 Changed 7 weeks ago by gk

Keywords: TorBrowserTeam201810 added; TorBrowserTeam201809 removed

Moving tickets to October

comment:11 Changed 4 weeks ago by pili

Sponsor: Sponsor8

comment:12 Changed 2 weeks ago by gk

Keywords: TorBrowserTeam201811 added; TorBrowserTeam201810 removed

Moving our tickets to November.

comment:13 Changed 2 weeks ago by gk

Keywords: TBA-a2 added
Priority: HighVery High
Note: See TracTickets for help on using tickets.