[Treble-Enabled Device Development A/AB ROMS] ValQuev:
Thank you for your job.

I'm facing an issue : I'm on Huawei Mate 10 Pro running LOS 15.1 with magisk 15.4 (SafetyNet test pass).

I have tried to put HwCamera2.apk on the /system/priv-app/HwCamera2 folder and reboot.

The app crashes with the following logs

03-07 13:47:24.755 879 1709 I ActivityManager: START u0 {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.huawei.camera/com.huawei.camera bnds=[640,288][839,602]} from uid 10092

03-07 13:47:24.817 879 1709 I ActivityManager: Start proc 5511:com.huawei.camera/u0a122 for activity com.huawei.camera/com.huawei.camera

03-07 13:47:25.002 5511 5511 E AndroidRuntime: Process: com.huawei.camera, PID: 5511

03-07 13:47:25.002 5511 5511 E AndroidRuntime: java.lang.RuntimeException: Unable to instantiate application com.huawei.camera2.controller.CameraApplication: java.lang.ClassNotFoundException: Didn't find class "com.huawei.camera2.controller.CameraApplication" on path: DexPathList[[zip file "/system/priv-app/HwCamera2/HwCamera2.apk"],nativeLibraryDirectories=[/system/priv-app/HwCamera2/lib/arm64, /system/lib64, /vendor/lib64, /system/lib64, /vendor/lib64]]

03-07 13:47:25.002 5511 5511 E AndroidRuntime: Caused by: java.lang.ClassNotFoundException: Didn't find class "com.huawei.camera2.controller.CameraApplication" on path: DexPathList[[zip file "/system/priv-app/HwCamera2/HwCamera2.apk"],nativeLibraryDirectories=[/system/priv-app/HwCamera2/lib/arm64, /system/lib64, /vendor/lib64, /system/lib64, /vendor/lib64]]

03-07 13:47:25.007 879 892 W ActivityManager: Force finishing activity com.huawei.camera/com.huawei.camera

03-07 13:47:25.014 879 897 I ActivityManager: Showing crash dialog for package com.huawei.camera u0

03-07 13:47:25.510 879 896 W ActivityManager: Activity pause timeout for ActivityRecord{caa59fb u0 com.huawei.camera/com.huawei.camera t611 f}

03-07 13:47:35.809 879 896 W ActivityManager: Activity destroy timeout for ActivityRecord{caa59fb u0 com.huawei.camera/com.huawei.camera t611 f}

03-07 13:48:25.530 879 892 I ActivityManager: Killing 5511:com.huawei.camera/u0a122 (adj 900): crash

03-07 13:48:25.536 564 1299 E BufferQueueProducer: [Application Error: com.huawei.camera#0] disconnect: not connected (req=1)

M

So I have retried but this time, with a signed APK by ZipSigner. After a reboot, the camera app still crashes but this time, I have another logs :

03-07 13:55:18.491 882 1707 I ActivityManager: START u0 {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.huawei.camera/com.huawei.camera bnds=[640,288][839,602]} from uid 10092

03-07 13:55:18.552 882 1707 I ActivityManager: Start proc 6336:com.huawei.camera/u0a122 for activity com.huawei.camera/com.huawei.camera

03-07 13:55:18.648 6336 6336 E osgi NCAM_AppUtil:	at com.huawei.camera2.utils.AppUtil.isSupportRog(AppUtil.java:572)

03-07 13:55:18.648 6336 6336 E osgi NCAM_AppUtil:	at com.huawei.camera2.utils.AppUtil.initialize(AppUtil.java:137)

03-07 13:55:18.648 6336 6336 E osgi NCAM_AppUtil:	at com.huawei.camera2.controller.CameraApplication.onCreate(CameraApplication.java:65)

03-07 13:55:18.665 6336 6336 E AndroidRuntime: Process: com.huawei.camera, PID: 6336

03-07 13:55:18.665 6336 6336 E AndroidRuntime:	at com.huawei.camera2.postprocess.PostCamera2.<clinit>(PostCamera2.java:83)

03-07 13:55:18.665 6336 6336 E AndroidRuntime:	at com.huawei.camera2.postprocess.PostCamera2.isSupported(PostCamera2.java:234)

03-07 13:55:18.665 6336 6336 E AndroidRuntime:	at com.huawei.camera2.controller.CameraApplication.onCreate(CameraApplication.java:81)

03-07 13:55:18.670 882 1088 W ActivityManager: Force finishing activity com.huawei.camera/com.huawei.camera

03-07 13:55:18.676 882 899 I ActivityManager: Showing crash dialog for package com.huawei.camera u0

03-07 13:55:19.173 882 898 W ActivityManager: Activity pause timeout for ActivityRecord{207eb53 u0 com.huawei.camera/com.huawei.camera t620 f}

So what can I do to make it run without crashes at launch please ?

Thanks in advance.

-----------------------------------------------------------------------

EDIT : file permission is set to 644