Closed
Bug 1042382
Opened 10 years ago
Closed 10 years ago
Allow for build-time specification of supported SDK ranges for the built application
Categories
(Firefox Build System :: Android Studio and Gradle Integration, defect)
Firefox Build System
Android Studio and Gradle Integration
All
Android
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla34
People
(Reporter: rnewman, Assigned: rnewman)
References
Details
Attachments
(2 files, 2 obsolete files)
(deleted),
patch
|
mfinkle
:
review+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
glandium
:
review+
|
Details | Diff | Splinter Review |
Splitting out from Bug 1039789.
This bug is for the specific work of allowing min/max to be specified during build, spitting out the right constants and manifest entries accordingly.
Assignee | ||
Comment 1•10 years ago
|
||
Nick deferred to you on how to do the enable flags. See Bug 1039789.
Attachment #8460624 -
Flags: review?(mh+mozilla)
Assignee | ||
Updated•10 years ago
|
Assignee: nobody → rnewman
Status: NEW → ASSIGNED
Assignee | ||
Comment 2•10 years ago
|
||
Should be a rubber-stamp.
Attachment #8460625 -
Flags: review?(mark.finkle)
Updated•10 years ago
|
Attachment #8460625 -
Flags: review?(mark.finkle) → review+
Comment 3•10 years ago
|
||
Comment on attachment 8460624 [details] [diff] [review]
Part 1: configure.in changes to allow Android SDK ranges to be specified. v1
Review of attachment 8460624 [details] [diff] [review]:
-----------------------------------------------------------------
::: configure.in
@@ +4864,5 @@
> +fi
> +if test -n "$MOZ_ANDROID_MAX_SDK_VERSION"; then
> + AC_DEFINE_UNQUOTED(MOZ_ANDROID_MAX_SDK_VERSION, $MOZ_ANDROID_MAX_SDK_VERSION)
> +fi
> +
That should go in build/autoconf/android.m4, and check that ANDROID_TARGET_SDK is less than or equal to MOZ_ANDROID_MIN_SDK_VERSION.
Attachment #8460624 -
Flags: review?(mh+mozilla) → review-
Comment 4•10 years ago
|
||
Re the irc discussion, let's say I'm fine with this if and only if you make sure the build path on the build slave is going to be the exact same one for all those configurations.
Comment 5•10 years ago
|
||
Mmmm well, even that is a pita to get right. Meh. Whatever. Let's waste build resources.
Assignee | ||
Comment 6•10 years ago
|
||
(In reply to Mike Hommey [:glandium] from comment #3)
> and check that
> ANDROID_TARGET_SDK is less than or equal to MOZ_ANDROID_MIN_SDK_VERSION.
The reverse, as far as I know. The min SDK version must be less than the target SDK, but that's almost a truism.
The target SDK is usually the highest SDK version that the app has been successfully built with -- e.g., SDK 19.
The minimum SDK version is the lowest Android release that is allowed to install the app -- ours defaults to 9.
The maximum SDK version is used to select from a family of APKs. This usually isn't present, but might be 9, or 13, or 15.
The valid sanity checks here would be:
maximum SDK, if present <= target SDK
minimum SDK <= target SDK
minimum SDK <= maximum SDK, if present
Relevant docs:
http://developer.android.com/guide/topics/manifest/uses-sdk-element.html
Comment 7•10 years ago
|
||
Ah yes, I was thinking $android_min_api_level (which is $1 in MOZ_ANDROID_SDK)
Assignee | ||
Comment 8•10 years ago
|
||
Moved to android.m4, added basic sanity checking for range:
Setting max less than min:
0:02.28 configure: error: --with-android-max-sdk must be at least the value of --with-android-min-sdk.
Setting --with-android-min-sdk=6:
0:01.66 configure: error: --with-android-min-sdk must be at least 9.
Attachment #8461249 -
Flags: review?(mh+mozilla)
Assignee | ||
Updated•10 years ago
|
Attachment #8460624 -
Attachment is obsolete: true
Comment 9•10 years ago
|
||
Comment on attachment 8461249 [details] [diff] [review]
Part 1: configure.in changes to allow Android SDK ranges to be specified. v2
Review of attachment 8461249 [details] [diff] [review]:
-----------------------------------------------------------------
MOZ_ANDROID_VERSION is the NDK platform version, and you're adding it to MOZ_ANDROID_NDK instead of MOZ_ANDROID_SDK
Attachment #8461249 -
Flags: review?(mh+mozilla) → review-
Assignee | ||
Comment 10•10 years ago
|
||
Moved to correct section, used $1 instead of MIN_ANDROID_VERSION, added an additional check that min < target. Tested.
Attachment #8461310 -
Flags: review?(mh+mozilla)
Assignee | ||
Updated•10 years ago
|
Attachment #8461249 -
Attachment is obsolete: true
Updated•10 years ago
|
Attachment #8461310 -
Flags: review?(mh+mozilla) → review+
Assignee | ||
Comment 11•10 years ago
|
||
Assignee | ||
Comment 12•10 years ago
|
||
Assignee | ||
Comment 13•10 years ago
|
||
Assignee | ||
Comment 14•10 years ago
|
||
Comment 15•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/626b749ccb28
https://hg.mozilla.org/mozilla-central/rev/153a8b79e121
https://hg.mozilla.org/mozilla-central/rev/b2ce4cf640ef
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 34
Updated•5 years ago
|
Product: Firefox for Android → Firefox Build System
Target Milestone: Firefox 34 → mozilla34
You need to log in
before you can comment on or make changes to this bug.
Description
•