Closed Bug 702724 Opened 8 years ago Closed 8 years ago

Avoid compiler error when JDK version >= 7

Categories

(Firefox for Android :: General, defect, trivial)

x86
Linux
defect
Not set
trivial

Tracking

()

RESOLVED FIXED

People

(Reporter: mkohler, Assigned: mkohler)

Details

Attachments

(2 files)

Attached patch Patch v1Splinter Review
When building with JDK7 you get the following error:

make[6]: Entering directory `/media/Data/development/mozilla/birch/fennec-obj/build/mobile/sutagent/android'
javac: target release 1.5 conflicts with default source release 1.7
make[6]: *** [classes.dex] Error 2
make[6]: Leaving directory `/media/Data/development/mozilla/birch/fennec-obj/build/mobile/sutagent/android'
make[5]: *** [tools] Error 2
make[5]: Leaving directory `/media/Data/development/mozilla/birch/fennec-obj/build'
make[4]: *** [tools_tier_base] Error 2
make[4]: Leaving directory `/media/Data/development/mozilla/birch/fennec-obj'
make[3]: *** [tier_base] Error 2
make[3]: Leaving directory `/media/Data/development/mozilla/birch/fennec-obj'
make[2]: *** [default] Error 2
make[2]: Leaving directory `/media/Data/development/mozilla/birch/fennec-obj'
make[1]: *** [realbuild] Error 2
make[1]: Leaving directory `/media/Data/development/mozilla/birch'
make: *** [build] Error 2
Assignee: nobody → michaelkohler
Attachment #574646 - Attachment description: This patch specifies "--source $(JAVA_VERSION)" in the javac flags. → Patch v1
Attachment #574646 - Attachment is patch: true
Attachment #574646 - Flags: review?(kgupta)
Comment on attachment 574646 [details] [diff] [review]
Patch v1

The change itself is fine, but you should upload patches as printed via "hg export", so that it includes a commit message.
Attachment #574646 - Flags: review?(kgupta) → review+
Also note that this error doesn't happen with JDK 6, because Java 1.6 source can be compiled into 1.5 bytecode, whereas that may not be possible with 1.7 source.
Summary: Avoid compiler error when JDK version > 5 → Avoid compiler error when JDK version >= 7
Status: NEW → ASSIGNED
Let me know if you want me to land the patch.
http://hg.mozilla.org/projects/birch/rev/245b412faf41
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.