Problem with import Chromium android source to Android Studio

737 views
Skip to first unread message

Hsing-Wang Liao

unread,
May 22, 2017, 10:14:07 PM5/22/17
to Chromium-dev
Hi, I want to import Chromium Android source to Android Studio.


I find there is a build.gradle file in out/Release/gradle/chrome/android/chrome_public_apk

so I copy all source files and gen files to my own project.



I think I have copied all needed files. And that's build successful.

But crash on my own device: Chrome failed during startup with an unexpected error.

05-23 10:08:50.873 21692-21692/? I/art: Late-enabling -Xcheck:jni
05-23 10:08:50.903 21692-21692/? I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:50.903 21692-21692/? I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:50.903 21692-21692/? E/Parcel: Reading a NULL string not supported here.
05-23 10:08:50.903 21692-21692/? I/Security_Hook: getAppPcManger cta=false;
05-23 10:08:51.843 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:51.843 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:51.843 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:51.843 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:51.963 21692-21692/org.chromium.chrome I/InstantRun: starting instant run server: is main process
05-23 10:08:51.993 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:52.303 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:52.303 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:52.403 21692-21692/org.chromium.chrome W/art: Before Android 4.1, method android.graphics.PorterDuffColorFilter android.support.graphics.drawable.VectorDrawableCompat.updateTintFilter(android.graphics.PorterDuffColorFilter, android.content.res.ColorStateList, android.graphics.PorterDuff$Mode) would have incorrectly overridden the package-private method in android.graphics.drawable.Drawable
05-23 10:08:52.693 21692-21692/org.chromium.chrome D/wangcy9: setStatusIcon occur wrong theme!
05-23 10:08:52.953 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:53.233 21692-21692/org.chromium.chrome D/wangcy9-font: default_File_font_path/system/fonts/LenovoFont.ttf
05-23 10:08:53.233 21692-21692/org.chromium.chrome D/wangcy9-font: curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:53.373 21692-21692/org.chromium.chrome D/wangcy9-font: default_File_font_path/system/fonts/LenovoFont.ttf
05-23 10:08:53.373 21692-21692/org.chromium.chrome D/wangcy9-font: curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:53.443 21692-21692/org.chromium.chrome D/wangcy9-font: default_File_font_path/system/fonts/LenovoFont.ttf
05-23 10:08:53.443 21692-21692/org.chromium.chrome D/wangcy9-font: curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:53.523 21692-21692/org.chromium.chrome D/wangcy9: setStatusIcon occur wrong theme!
05-23 10:08:53.603 21692-21730/org.chromium.chrome I/cr_LibraryLoader: Using linker: org.chromium.base.library_loader.LegacyLinker
05-23 10:08:53.613 21692-21730/org.chromium.chrome I/cr_LibraryLoader: Loading chrome
05-23 10:08:53.713 21692-21731/org.chromium.chrome W/cr_tabmodel: Starting to fetch tab list.
05-23 10:08:53.713 21692-21731/org.chromium.chrome E/cr_tabmodel: State file does not exist.
05-23 10:08:53.733 21692-21730/org.chromium.chrome I/cr_LibraryLoader: Time to load native libraries: 143 ms (timestamps 840-983)
05-23 10:08:53.733 21692-21730/org.chromium.chrome I/chromium: [INFO:library_loader_hooks.cc(140)] Chromium logging enabled: level = 0, default verbosity = 0
05-23 10:08:53.733 21692-21730/org.chromium.chrome I/cr_LibraryLoader: Expected native library version number "58.0.3029.110", actual native library version number "58.0.3029.110"
05-23 10:08:53.773 21692-21730/org.chromium.chrome W/cr_ChildProcLauncher: Create a new ChildConnectionAllocator with package name = org.chromium.chrome, inSandbox = true
05-23 10:08:53.793 21692-21730/org.chromium.chrome D/cr_ChildProcLauncher: [ChildProcessLauncher.java:105] Allocator allocated a connection, sandbox: true, slot: 0
05-23 10:08:53.833 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:53.833 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:53.843 21692-21740/org.chromium.chrome D/OpenGLRenderer: Render dirty regions requested: true
05-23 10:08:53.843 21692-21692/org.chromium.chrome D/Atlas: Validating map...
05-23 10:08:53.843 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.843 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.843 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.843 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.843 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.843 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.853 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
....
05-23 10:08:53.903 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.903 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.903 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.903 21692-21692/org.chromium.chrome W/Atlas: Pointer 0x0, not in getPreloadedDrawables?
05-23 10:08:53.903 21692-21692/org.chromium.chrome I/Timeline: Timeline: Activity_launch_request id:org.chromium.chrome time:34911159
05-23 10:08:53.903 21692-21692/org.chromium.chrome E/Parcel: Reading a NULL string not supported here.
05-23 10:08:53.933 21692-21692/org.chromium.chrome D/ViewRootImpl: loadSystemProperties PersistDebugEvent: false RoDebugEvent: false
05-23 10:08:53.963 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:53.983 21692-21740/org.chromium.chrome I/Adreno-EGL: <qeglDrvAPI_eglInitialize:410>: EGL 1.4 QUALCOMM build:  ()
                                                                 OpenGL ES Shader Compiler Version: E031.25.03.06
                                                                 Build Date: 03/12/15 Thu
                                                                 Local Branch: 
                                                                 Remote Branch: 
                                                                 Local Patches: 
                                                                 Reconstruct Branch: 
05-23 10:08:53.983 21692-21740/org.chromium.chrome I/OpenGLRenderer: Initialized EGL, version 1.4
05-23 10:08:53.993 21692-21740/org.chromium.chrome D/OpenGLRenderer: Enabling debug mode 0
05-23 10:08:54.083 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.083 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.143 21692-21692/org.chromium.chrome D/wangcy9: setStatusIcon occur wrong theme!
05-23 10:08:54.163 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.163 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.193 21692-21692/org.chromium.chrome I/cr_BrowserStartup: Initializing chromium process, singleProcess=false
05-23 10:08:54.403 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.403 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.403 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.403 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.413 21692-21692/org.chromium.chrome D/ViewRootImpl: loadSystemProperties PersistDebugEvent: false RoDebugEvent: false
05-23 10:08:54.453 21692-21692/org.chromium.chrome D/cr_BuildInfo: [BuildInfo.java:74] GMS package is not found.
                                                                   android.content.pm.PackageManager$NameNotFoundException: com.google.android.gms
                                                                       at android.app.ApplicationPackageManager.getPackageInfo(ApplicationPackageManager.java:125)
                                                                       at org.chromium.base.BuildInfo.getGMSVersionCode(BuildInfo.java:71)
                                                                       at org.chromium.content.browser.BrowserStartupController.nativeSetCommandLineFlags(Native Method)
                                                                       at org.chromium.content.browser.BrowserStartupController.access$600(BrowserStartupController.java:40)
                                                                       at org.chromium.content.browser.BrowserStartupController$4.run(BrowserStartupController.java:318)
                                                                       at android.os.Handler.handleCallback(Handler.java:739)
                                                                       at android.os.Handler.dispatchMessage(Handler.java:95)
                                                                       at android.os.Looper.loop(Looper.java:135)
                                                                       at android.app.ActivityThread.main(ActivityThread.java:5281)
                                                                       at java.lang.reflect.Method.invoke(Native Method)
                                                                       at java.lang.reflect.Method.invoke(Method.java:372)
                                                                       at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:902)
                                                                       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:697)
                                                                       at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:102)
05-23 10:08:54.503 21692-21692/org.chromium.chrome W/chromium: [WARNING:resource_bundle_android.cc(100)] locale_file_path.empty() for locale 
05-23 10:08:54.583 21692-21692/org.chromium.chrome D/wangcy9: setStatusIcon occur wrong theme!
05-23 10:08:54.673 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.673 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.683 21692-21692/org.chromium.chrome D/wangcy9: setStatusIcon occur wrong theme!
05-23 10:08:54.703 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.703 21692-21692/org.chromium.chrome I/Configuration: Configuration getConfigurationFromSysProp name= persist.sys.font_scale value=
05-23 10:08:54.713 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.713 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.713 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.713 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.713 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.743 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.743 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.743 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.743 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.743 21692-21692/org.chromium.chrome D/FontThemeManager: FontThemeManager createThemeFont typefacetype=2, curfontpath=/system/fonts/LenovoFont.ttf
05-23 10:08:54.773 21692-21692/org.chromium.chrome D/ViewRootImpl: loadSystemProperties PersistDebugEvent: false RoDebugEvent: false
05-23 10:08:54.773 21692-21692/org.chromium.chrome D/ViewRootImpl: loadSystemProperties PersistDebugEvent: false RoDebugEvent: false
05-23 10:08:54.833 21692-21692/org.chromium.chrome I/Timeline: Timeline: Activity_idle id: android.os.BinderProxy@220827f5 time:34912088
05-23 10:08:54.833 21692-21692/org.chromium.chrome I/Timeline: Timeline: Activity_idle id: android.os.BinderProxy@2c3699b8 time:34912089

Can any body help me?

Hsing-Wang Liao

unread,
May 23, 2017, 12:32:30 AM5/23/17
to Chromium-dev
Fixed by add webapk1.dex, everything works good now.

Thanks!

Hsing-Wang Liao

unread,
May 23, 2017, 4:09:33 AM5/23/17
to Chromium-dev
Still have some problem:

05-23 15:58:09.297 8249-8365/org.chromium.chrome W/cr_tabmodel: Starting to fetch tab list.
05-23 15:58:09.297 8249-8365/org.chromium.chrome E/cr_tabmodel: State file does not exist.
...
05-23 15:58:09.347 8249-8359/org.chromium.chrome I/cr_LibraryLoader: Time to load native libraries: 168 ms (timestamps 7953-8121)
05-23 15:58:16.987 8249-8249/org.chromium.chrome D/cr_invalidation: [DelayedInvalidationsController.java:57] No pending invalidations.
05-23 15:58:17.007 8249-8582/org.chromium.chrome V/cr_omaha: [OmahaBase.java:137] Disabled.  Ignoring intent.
05-23 15:58:21.877 8249-8249/org.chromium.chrome W/cr_ChildProcessConnect: onServiceDisconnected (crash or killed by oom): pid=8397
05-23 15:58:21.877 8249-8249/org.chromium.chrome D/cr_ChildProcLauncher: [ChildProcessLauncher.java:828] stopping child connection: pid=8397
05-23 15:58:21.887 8249-8249/org.chromium.chrome D/cr_ChildProcLauncher: [ChildProcessLauncher.java:125] Allocator freed a connection, sandbox: false, slot: 0
05-23 15:58:30.197 8249-8249/org.chromium.chrome A/chromium: [FATAL:compositor_impl_android.cc(625)] Timed out waiting for GPU channel.
05-23 15:58:30.477 8249-8249/org.chromium.chrome W/google-breakpad: ### ### ### ### ### ### ### ### ### ### ### ### ###
05-23 15:58:30.477 8249-8249/org.chromium.chrome W/google-breakpad: Chrome build fingerprint:
05-23 15:58:30.477 8249-8249/org.chromium.chrome W/google-breakpad: 1.0
05-23 15:58:30.477 8249-8249/org.chromium.chrome W/google-breakpad: 1
05-23 15:58:30.477 8249-8249/org.chromium.chrome W/google-breakpad: ### ### ### ### ### ### ### ### ### ### ### ### ###
05-23 15:58:30.487 8249-8249/org.chromium.chrome A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 8249 (chromium.chrome)

1. E/cr_tabmodel: State file does not exist.
2.A/chromium: [FATAL:compositor_impl_android.cc(625)] Timed out waiting for GPU channel.

Anita Woodruff

unread,
May 23, 2017, 9:03:56 AM5/23/17
to kuo...@gmail.com, Chromium-dev, agr...@chromium.org
+agr...@chromium.org 

I don't think it's necessary to copy any files anywhere, just import the project from the out directory where it's generated directly, as per the instructions.


--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-dev/9da99ec7-172f-45c4-9f84-ea190a855db6%40chromium.org.
Reply all
Reply to author
Forward
0 new messages