Closed Bug 1220887 Opened 9 years ago Closed 9 years ago

Don't require |mach gradle-install| for srcdir Gradle builds

Categories

(Firefox Build System :: Android Studio and Gradle Integration, defect)

defect
Not set
normal

Tracking

(firefox45 fixed)

RESOLVED FIXED
Tracking Status
firefox45 --- fixed

People

(Reporter: nalexander, Assigned: nalexander)

References

Details

Attachments

(1 file)

Bug 1176133 tracks removing |mach gradle-install| entirely. This tracks folding a minimal version of the symlinking into the srcdir settings.gradle file itself. This is possible 'cuz settings.gradle executes very early in the IDE import project sequence: before Gradle project evaluation time, and thus before any Gradle task is executed.
Bug 1220887 - Make 'base' Gradle project in the srcdir. r?sebastian This is the last Gradle project that isn't in the srcdir. Since base/ doesn't have the correct package prefix directory structure, we still need to symlink, but we only need one link. This effectively deprecates |mach gradle-install|. This should improve the robustness of our Gradle configuration, ensuring that we always have projects to import. Since settings.gradle executes very early in the IDE import project sequence: before Gradle project evaluation time, and thus before any Gradle task is executed, we should always see a complete project. (It was possible to see incomplete Gradle configurations if |mach gradle-install| hadn't been run at just the right time.)
Attachment #8682639 - Flags: review?(s.kaspari)
Attachment #8682639 - Flags: review?(s.kaspari) → review+
Comment on attachment 8682639 [details] MozReview Request: Bug 1220887 - Make 'base' Gradle project in the srcdir. r?sebastian https://reviewboard.mozilla.org/r/24119/#review21835 I still needed to run |mach gradle-install| because I saw the following error without. Is this expected at this stage? > FAILURE: Build failed with an exception. > > * What went wrong: > A problem occurred configuring project ':app'. > > Failed to notify project evaluation listener. > > Cannot evaluate module base : Configuration with name 'default' not found. > > Task with name 'spoonDebugAndroidTest' not found in project ':app'. > > * Try: > Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
Blocks: 1222120
(In reply to Sebastian Kaspari (:sebastian) from comment #2) > Comment on attachment 8682639 [details] > MozReview Request: Bug 1220887 - Make 'base' Gradle project in the srcdir. > r?sebastian > > https://reviewboard.mozilla.org/r/24119/#review21835 > > I still needed to run |mach gradle-install| because I saw the following > error without. Is this expected at this stage? > > > FAILURE: Build failed with an exception. > > > > * What went wrong: > > A problem occurred configuring project ':app'. > > > Failed to notify project evaluation listener. > > > Cannot evaluate module base : Configuration with name 'default' not found. > > > Task with name 'spoonDebugAndroidTest' not found in project ':app'. > > > > * Try: > > Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. This is not expected. I clobbered and after |mach build && mach artifact-install && mach package|, I could |./gradlew app:assembleDebug| without issues. I could also import the topsrcdir into IJ no trouble. I think you're seeing remnants of the old configuration and symlinks. We'll see!
Assignee: nobody → nalexander
Status: NEW → ASSIGNED
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
Component: Build Config → Build Config & IDE Support
Product: Core → Firefox for Android
Target Milestone: mozilla45 → ---
Product: Firefox for Android → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: