Issue with ProGuard
Getting this error on build after applying proguard.
This is the command I run: redex -o faster.apk input.apk -P proguard-project.txt
Its working fine when I don't use proguard
Unimplemented command (skipping): -adaptclassstrings at line 225 Unimplemented command (skipping): -renamesourcefileattribute at line 226 Unimplemented command (skipping): -renamesourcefileattribute at line 231 libredex/Transform.cpp:316: MethodItemEntry *(anonymous namespace)::get_target(MethodItemEntry *, const addr_mei_t &): assertion `addr_to_mei.count(target) != 0' failed. Invalid opcode target 000000100x7fce35eda600 0000003b in get_target if-eqz v4
0 redex-all 0x00000001011628ea _Z11assert_failPKcS0_jS0_S0_z + 218
1 redex-all 0x00000001011ec9e3 _ZN12_GLOBAL__N_1L10get_targetEP15MethodItemEntryRKNSt3__113unordered_mapIjS1_NS2_4hashIjEENS2_8equal_toIjEENS2_9allocatorINS2_4pairIKjS1_EEEEEE + 275
2 redex-all 0x00000001011e46f5 _ZN15MethodTransform7balloonEP7DexCode + 517
3 redex-all 0x00000001011e4486 _ZN15MethodTransformC2EPK7DexCode + 70
4 redex-all 0x000000010116b0d9 _ZN7DexCode7balloonEv + 41
5 redex-all 0x00000001011f77d2 _ZN9WorkQueue13worker_threadEPv + 82
6 libsystem_pthread.dylib 0x00007fffc77edabb _pthread_body + 180
7 libsystem_pthread.dylib 0x00007fffc77eda07 _pthread_body + 0
8 libsystem_pthread.dylib 0x00007fffc77ed231 thread_start + 13
libc++abi.dylib: terminating with uncaught exception of type std::runtime_error: Redex assertion failure
0 redex-all 0x00000001011627d4 _Z23crash_backtrace_handleri + 52
1 libsystem_platform.dylib 0x00007fffc77e3bba _sigtramp + 26
2 ??? 0x00000004d02b1240 0x0 + 20672352832
3 libsystem_c.dylib 0x00007fffc766b440 abort + 129
4 libc++abi.dylib 0x00007fffc61cd85a __cxa_bad_cast + 0
5 libc++abi.dylib 0x00007fffc61f2c37 _ZL25default_terminate_handlerv + 243
6 libobjc.A.dylib 0x00007fffc6cfbf33 _ZL15_objc_terminatev + 124
7 libc++abi.dylib 0x00007fffc61efd69 _ZSt11__terminatePFvvE + 8
8 libc++abi.dylib 0x00007fffc61ef7de _ZN10__cxxabiv1L22exception_cleanup_funcE19_Unwind_Reason_CodeP17_Unwind_Exception + 0
9 redex-all 0x000000010116292b _Z11assert_failPKcS0_jS0_S0_z + 283
10 redex-all 0x00000001011ec9e3 _ZN12_GLOBAL__N_1L10get_targetEP15MethodItemEntryRKNSt3__113unordered_mapIjS1_NS2_4hashIjEENS2_8equal_toIjEENS2_9allocatorINS2_4pairIKjS1_EEEEEE + 275
11 redex-all 0x00000001011e46f5 _ZN15MethodTransform7balloonEP7DexCode + 517
12 redex-all 0x00000001011e4486 _ZN15MethodTransformC2EPK7DexCode + 70
13 redex-all 0x000000010116b0d9 _ZN7DexCode7balloonEv + 41
14 redex-all 0x00000001011f77d2 _ZN9WorkQueue13worker_threadEPv + 82
15 libsystem_pthread.dylib 0x00007fffc77edabb _pthread_body + 180
16 libsystem_pthread.dylib 0x00007fffc77eda07 _pthread_body + 0
17 libsystem_pthread.dylib 0x00007fffc77ed231 thread_start + 13
Traceback (most recent call last):
File "/tmp/redex.ZM1nnr/redex.py", line 545, in
Could you retry with the latest git master? We improved our code base significantly recently. If you still see a crash, we'd like to take a look at. Please share your apk in Dropbox or so if you're able to share it.
I pulled in the latest code from master. But still can't seem to get it working.
This is the error log :
libredex/Transform.cpp:316: MethodItemEntry *(anonymous namespace)::get_target(MethodItemEntry *, const addr_mei_t &): assertion `addr_to_mei.count(target) != 0' failed. Invalid opcode target 000000100x7fa096420cc0 0000003b in get_target if-eqz v4
0 redex-all 0x00000001013918ea _Z11assert_failPKcS0_jS0_S0_z + 218
1 redex-all 0x000000010141b9e3 _ZN12_GLOBAL__N_1L10get_targetEP15MethodItemEntryRKNSt3__113unordered_mapIjS1_NS2_4hashIjEENS2_8equal_toIjEENS2_9allocatorINS2_4pairIKjS1_EEEEEE + 275
2 redex-all 0x00000001014136f5 _ZN15MethodTransform7balloonEP7DexCode + 517
3 redex-all 0x0000000101413486 _ZN15MethodTransformC2EPK7DexCode + 70
4 redex-all 0x000000010139a0d9 _ZN7DexCode7balloonEv + 41
5 redex-all 0x00000001014267d2 _ZN9WorkQueue13worker_threadEPv + 82
6 libsystem_pthread.dylib 0x00007fffc77edabb _pthread_body + 180
7 libsystem_pthread.dylib 0x00007fffc77eda07 _pthread_body + 0
8 libsystem_pthread.dylib 0x00007fffc77ed231 thread_start + 13
libc++abi.dylib: terminating with uncaught exception of type std::runtime_error: Redex assertion failure
0 redex-all 0x00000001013917d4 _Z23crash_backtrace_handleri + 52
1 libsystem_platform.dylib 0x00007fffc77e3bba _sigtramp + 26
2 ??? 0x00000004d02b1240 0x0 + 20672352832
3 libsystem_c.dylib 0x00007fffc766b440 abort + 129
4 libc++abi.dylib 0x00007fffc61cd85a __cxa_bad_cast + 0
5 libc++abi.dylib 0x00007fffc61f2c37 _ZL25default_terminate_handlerv + 243
6 libobjc.A.dylib 0x00007fffc6cfbf33 _ZL15_objc_terminatev + 124
7 libc++abi.dylib 0x00007fffc61efd69 _ZSt11__terminatePFvvE + 8
8 libc++abi.dylib 0x00007fffc61ef7de _ZN10__cxxabiv1L22exception_cleanup_funcE19_Unwind_Reason_CodeP17_Unwind_Exception + 0
9 redex-all 0x000000010139192b _Z11assert_failPKcS0_jS0_S0_z + 283
10 redex-all 0x000000010141b9e3 _ZN12_GLOBAL__N_1L10get_targetEP15MethodItemEntryRKNSt3__113unordered_mapIjS1_NS2_4hashIjEENS2_8equal_toIjEENS2_9allocatorINS2_4pairIKjS1_EEEEEE + 275
11 redex-all 0x00000001014136f5 _ZN15MethodTransform7balloonEP7DexCode + 517
12 redex-all 0x0000000101413486 _ZN15MethodTransformC2EPK7DexCode + 70
13 redex-all 0x000000010139a0d9 _ZN7DexCode7balloonEv + 41
14 redex-all 0x00000001014267d2 _ZN9WorkQueue13worker_threadEPv + 82
15 libsystem_pthread.dylib 0x00007fffc77edabb _pthread_body + 180
16 libsystem_pthread.dylib 0x00007fffc77eda07 _pthread_body + 0
17 libsystem_pthread.dylib 0x00007fffc77ed231 thread_start + 13
Traceback (most recent call last):
File "/tmp/redex.vBb1ie/redex.py", line 545, in
@int3 This looks similar to things you've been working on recently
Same assertion failure as #126
Are you using Kotlin? If so, you should try rebasing to a commit after ab25dcf164164bf52b206a934137c8588ceff6b4 in which Kotlin assertion failures were fixed
@justinjhendrick not using Kotlin.
Okay, if this reproduces on the latest master, could you send me the apk and config file(s) you're using? I'll try to reproduce it on my side.
Closing due to inactivity. Feel free to reopen with new information.