@@ -178,11 +178,13 @@ static const char *const kSystemLibDir = "/system/lib64/";
178
178
static const char *const kOdmLibDir = " /odm/lib64/" ;
179
179
static const char *const kVendorLibDir = " /vendor/lib64/" ;
180
180
static const char *const kApexLibDir = " /apex/com.android.runtime/lib64/" ;
181
+ static const char *const kApexArtNsLibDir = " /apex/com.android.art/lib64/" ;
181
182
#else
182
183
static const char *const kSystemLibDir = " /system/lib/" ;
183
184
static const char *const kOdmLibDir = " /odm/lib/" ;
184
185
static const char *const kVendorLibDir = " /vendor/lib/" ;
185
186
static const char *const kApexLibDir = " /apex/com.android.runtime/lib/" ;
187
+ static const char *const kApexArtNsLibDir = " /apex/com.android.art/lib/" ;
186
188
#endif
187
189
188
190
static void *fake_dlopen (const char *filename, int flags) {
@@ -199,7 +201,7 @@ static void *fake_dlopen(const char *filename, int flags) {
199
201
return handle;
200
202
}
201
203
202
- // apex
204
+ // apex in ns com.android.runtime
203
205
memset (buf, 0 , sizeof (buf));
204
206
strcpy (buf, kApexLibDir );
205
207
strcat (buf, filename);
@@ -208,6 +210,15 @@ static void *fake_dlopen(const char *filename, int flags) {
208
210
return handle;
209
211
}
210
212
213
+ // apex in ns com.android.art
214
+ memset (buf, 0 , sizeof (buf));
215
+ strcpy (buf, kApexArtNsLibDir );
216
+ strcat (buf, filename);
217
+ handle = fake_dlopen_with_path (buf, flags);
218
+ if (handle) {
219
+ return handle;
220
+ }
221
+
211
222
// odm
212
223
memset (buf, 0 , sizeof (buf));
213
224
strcpy (buf, kOdmLibDir );
0 commit comments