Bug 978587 - Make GeckoView package org.mozilla.gecko; don't include org.mozilla.gecko.R. r=blassey

This builds a new Java JAR containing only org.mozilla.gecko.R.  This
new JAR file is included in Fennec, but not included in
geckoview_library.  (Usually ant, gradle, or Eclipse arranges to produce
org.mozilla.gecko.R but not include it in the classes.jar output as part
of a library project.  This mimics that.)

Changing the GeckoView package to org.mozilla.gecko declares to
consuming applications that they should produce org.mozilla.gecko.R,
replacing what was removed above (but with correct resource IDs).
This commit is contained in:
Nick Alexander 2014-03-05 08:57:09 -08:00
Родитель 089da55967
Коммит 2f7f4f0753
4 изменённых файлов: 14 добавлений и 3 удалений

Просмотреть файл

@ -61,6 +61,7 @@ GARBAGE_DIRS += classes db jars res sync services generated
JAVA_CLASSPATH = $(ANDROID_SDK)/android.jar
ALL_JARS = \
gecko-R.jar \
gecko-browser.jar \
gecko-mozglue.jar \
gecko-util.jar \

Просмотреть файл

@ -10,6 +10,13 @@ include('android-services.mozbuild')
thirdparty_source_dir = TOPSRCDIR + '/mobile/android/thirdparty/'
resjar = add_java_jar('gecko-R')
resjar.sources = []
resjar.generated_sources += [
'org/mozilla/gecko/R.java',
]
resjar.javac_flags += ['-Xlint:all']
mgjar = add_java_jar('gecko-mozglue')
mgjar.sources += [
'mozglue/ByteBufferInputStream.java',
@ -80,6 +87,7 @@ if CONFIG['MOZ_WEBRTC']:
audio_root + 'WebRTCAudioDevice.java',
]
wrjar.extra_jars = [
'gecko-R.jar',
'gecko-browser.jar',
'gecko-util.jar',
'gecko-mozglue.jar',
@ -398,7 +406,6 @@ gbjar.generated_sources += [ android_package_dir + f for f in [
] ]
gbjar.generated_sources += [
'org/mozilla/gecko/AppConstants.java',
'org/mozilla/gecko/R.java',
'org/mozilla/gecko/SysInfo.java',
'org/mozilla/gecko/widget/GeckoEditText.java',
'org/mozilla/gecko/widget/GeckoImageButton.java',
@ -415,6 +422,7 @@ if CONFIG['MOZ_CRASHREPORTER']:
gbjar.sources += sync_java_files
gbjar.generated_sources += sync_generated_java_files
gbjar.extra_jars = [
'gecko-R.jar',
'gecko-mozglue.jar',
'gecko-util.jar',
'squareup-picasso.jar',

Просмотреть файл

@ -1,5 +1,5 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.mozilla.geckoview"
package="org.mozilla.gecko"
android:versionCode="1"
android:versionName="1.0" >

Просмотреть файл

@ -44,8 +44,10 @@ package: $(properties_deps) FORCE
# Make empty directories to fit an Android project structure
$(MKDIR) -p bin gen libs/$(ANDROID_CPU_ARCH) src
# Copy the JARs
# Copy the JARs, except for the jar containing org.mozilla.gecko.R.
# org.mozilla.gecko.R will be provided by the embedding application.
cp $(DEPTH)/mobile/android/base/*.jar libs/
$(RM) libs/gecko-R.jar
# Copy the SOs
cp $(_ABS_DIST)/bin/libmozglue.so $(_ABS_DIST)/bin/lib/libplugin-container.so libs/$(ANDROID_CPU_ARCH)/