soul-browser/sources/java/kotlin/UNumbersKt.java
KaKi87 550ddb0413
Decompile and recreate Soul Browser v1.4.85 with APK CI builds (#1)
* Decompile and recreate Soul Browser v1.4.85 with APK CI builds

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix CI build: include bundled google.jks and remove PR trigger

The apktool build failed in CI because app/unknown/.../google.jks was
excluded by the *.jks gitignore rule. Whitelist app-bundled JKS files
and commit the missing resource.

Also remove the redundant pull_request workflow trigger.

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Change package ID to com.github.kaki87.soulbrowser

Rename the application ID so the rebuilt APK can be installed
alongside the original Soul Browser from Google Play.

- Update AndroidManifest package, permissions, providers, and actions
- Update R class references in smali (com/github/kaki87/soulbrowser/R)
- Update shortcuts.xml targetPackage
- Rename app label to "Soul Rebuild" for easy identification

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix install compatibility: remove split APK metadata and bundle native libs

The rebuilt APK still declared requiredSplitTypes and Play Store split
metadata, causing Android to reject standalone installs as incompatible.

- Remove requiredSplitTypes and split-related manifest meta-data
- Merge native libs from all ABI splits with uncompressed storage
- Page-align before signing for extractNativeLibs=false
- Add .so to apktool doNotCompress list

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix install failure: use apksigner v2/v3 and bundle arm64 native libs

Target SDK 36 requires APK Signature Scheme v2+, but jarsigner only
produces v1 signatures, causing Android to reject the install.

- Sign with apksigner (v1+v2+v3) instead of jarsigner
- Add arm64-v8a native libraries from universal Soul Browser 1.4.79
- Set extractNativeLibs=true for reliable sideload installs
- Commit stable debug keystore for consistent signatures across builds

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Add committed debug keystore for consistent APK signatures

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix startup crash: use original classes2.dex desugar libraries

Apktool recompiles smali_classes2 into a broken classes2.dex, causing
ClassNotFoundException for j$.com.android.tools.r8.a at ML Kit init.

Inject the original classes2.dex (Java 8+ desugar libs) after apktool
build instead of using the recompiled version.

Co-authored-by: KaKi87 <KaKi87@pm.me>

* Fix missing drawable resources from density split APKs

The base APK is an app bundle module; density-specific drawables like
seek_thumb_nor_b live in config.xhdpi.apk and were missing after rebuild,
causing Resources$NotFoundException at runtime.

- Merge non-9-patch resources from split APKs before apktool build
- Sync public.xml IDs from R smali only when backing files exist
- Add 713 density-specific resource IDs to public.xml

Co-authored-by: KaKi87 <KaKi87@pm.me>

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
2026-08-10 16:07:14 +02:00

206 lines
12 KiB
Java

package kotlin;
import com.google.android.gms.ads.RequestConfiguration;
import kotlin.internal.InlineOnly;
import kotlin.jvm.JvmName;
@Metadata(d1 = {"\u0000&\n\u0000\n\u0002\u0010\b\n\u0002\u0018\u0002\n\u0002\b\u0010\n\u0002\u0018\u0002\n\u0002\b\n\n\u0002\u0018\u0002\n\u0002\b\n\n\u0002\u0018\u0002\n\u0002\b\u000b\u001a\u0014\u0010\u0000\u001a\u00020\u0001*\u00020\u0002H\u0087\\u0006\u0004\b\u0003\u0010\u0004\u001a\u0014\u0010\u0005\u001a\u00020\u0001*\u00020\u0002H\u0087\\u0006\u0004\b\u0006\u0010\u0004\u001a\u0014\u0010\u0007\u001a\u00020\u0001*\u00020\u0002H\u0087\\u0006\u0004\b\b\u0010\u0004\u001a\u0014\u0010\t\u001a\u00020\u0002*\u00020\u0002H\u0087\\u0006\u0004\b\n\u0010\u0004\u001a\u0014\u0010\u000b\u001a\u00020\u0002*\u00020\u0002H\u0087\\u0006\u0004\b\f\u0010\u0004\u001a\u001c\u0010\r\u001a\u00020\u0002*\u00020\u00022\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b\u000f\u0010\u0010\u001a\u001c\u0010\u0011\u001a\u00020\u0002*\u00020\u00022\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b\u0012\u0010\u0010\u001a\u0014\u0010\u0000\u001a\u00020\u0001*\u00020\u0013H\u0087\\u0006\u0004\b\u0014\u0010\u0015\u001a\u0014\u0010\u0005\u001a\u00020\u0001*\u00020\u0013H\u0087\\u0006\u0004\b\u0016\u0010\u0015\u001a\u0014\u0010\u0007\u001a\u00020\u0001*\u00020\u0013H\u0087\\u0006\u0004\b\u0017\u0010\u0015\u001a\u0014\u0010\t\u001a\u00020\u0013*\u00020\u0013H\u0087\\u0006\u0004\b\u0018\u0010\u0019\u001a\u0014\u0010\u000b\u001a\u00020\u0013*\u00020\u0013H\u0087\\u0006\u0004\b\u001a\u0010\u0019\u001a\u001c\u0010\r\u001a\u00020\u0013*\u00020\u00132\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b\u001b\u0010\u001c\u001a\u001c\u0010\u0011\u001a\u00020\u0013*\u00020\u00132\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b\u001d\u0010\u001c\u001a\u0014\u0010\u0000\u001a\u00020\u0001*\u00020\u001eH\u0087\\u0006\u0004\b\u001f\u0010 \u001a\u0014\u0010\u0005\u001a\u00020\u0001*\u00020\u001eH\u0087\\u0006\u0004\b!\u0010 \u001a\u0014\u0010\u0007\u001a\u00020\u0001*\u00020\u001eH\u0087\\u0006\u0004\b\"\u0010 \u001a\u0014\u0010\t\u001a\u00020\u001e*\u00020\u001eH\u0087\\u0006\u0004\b#\u0010$\u001a\u0014\u0010\u000b\u001a\u00020\u001e*\u00020\u001eH\u0087\\u0006\u0004\b%\u0010$\u001a\u001c\u0010\r\u001a\u00020\u001e*\u00020\u001e2\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b&\u0010'\u001a\u001c\u0010\u0011\u001a\u00020\u001e*\u00020\u001e2\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b(\u0010'\u001a\u0014\u0010\u0000\u001a\u00020\u0001*\u00020)H\u0087\\u0006\u0004\b*\u0010+\u001a\u0014\u0010\u0005\u001a\u00020\u0001*\u00020)H\u0087\\u0006\u0004\b,\u0010+\u001a\u0014\u0010\u0007\u001a\u00020\u0001*\u00020)H\u0087\\u0006\u0004\b-\u0010+\u001a\u0014\u0010\t\u001a\u00020)*\u00020)H\u0087\\u0006\u0004\b.\u0010/\u001a\u0014\u0010\u000b\u001a\u00020)*\u00020)H\u0087\\u0006\u0004\b0\u0010/\u001a\u001c\u0010\r\u001a\u00020)*\u00020)2\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b1\u00102\u001a\u001c\u0010\u0011\u001a\u00020)*\u00020)2\u0006\u0010\u000e\u001a\u00020\u0001H\u0087\\u0006\u0004\b3\u00102¨\u00064"}, d2 = {"countOneBits", RequestConfiguration.MAX_AD_CONTENT_RATING_UNSPECIFIED, "Lkotlin/UInt;", "countOneBits-WZ4Q5Ns", "(I)I", "countLeadingZeroBits", "countLeadingZeroBits-WZ4Q5Ns", "countTrailingZeroBits", "countTrailingZeroBits-WZ4Q5Ns", "takeHighestOneBit", "takeHighestOneBit-WZ4Q5Ns", "takeLowestOneBit", "takeLowestOneBit-WZ4Q5Ns", "rotateLeft", "bitCount", "rotateLeft-V7xB4Y4", "(II)I", "rotateRight", "rotateRight-V7xB4Y4", "Lkotlin/ULong;", "countOneBits-VKZWuLQ", "(J)I", "countLeadingZeroBits-VKZWuLQ", "countTrailingZeroBits-VKZWuLQ", "takeHighestOneBit-VKZWuLQ", "(J)J", "takeLowestOneBit-VKZWuLQ", "rotateLeft-JSWoG40", "(JI)J", "rotateRight-JSWoG40", "Lkotlin/UByte;", "countOneBits-7apg3OU", "(B)I", "countLeadingZeroBits-7apg3OU", "countTrailingZeroBits-7apg3OU", "takeHighestOneBit-7apg3OU", "(B)B", "takeLowestOneBit-7apg3OU", "rotateLeft-LxnNnR4", "(BI)B", "rotateRight-LxnNnR4", "Lkotlin/UShort;", "countOneBits-xj2QHRw", "(S)I", "countLeadingZeroBits-xj2QHRw", "countTrailingZeroBits-xj2QHRw", "takeHighestOneBit-xj2QHRw", "(S)S", "takeLowestOneBit-xj2QHRw", "rotateLeft-olVBNx4", "(SI)S", "rotateRight-olVBNx4", "kotlin-stdlib"}, k = 2, mv = {2, 2, 0}, xi = 48)
@JvmName(name = "UNumbersKt")
/* loaded from: classes3.dex */
public final class UNumbersKt {
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countLeadingZeroBits-7apg3OU, reason: not valid java name */
private static final int m276countLeadingZeroBits7apg3OU(byte b) {
return Integer.numberOfLeadingZeros(b & UByte.MAX_VALUE) - 24;
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countLeadingZeroBits-VKZWuLQ, reason: not valid java name */
private static final int m277countLeadingZeroBitsVKZWuLQ(long j) {
return Long.numberOfLeadingZeros(j);
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countLeadingZeroBits-WZ4Q5Ns, reason: not valid java name */
private static final int m278countLeadingZeroBitsWZ4Q5Ns(int i) {
return Integer.numberOfLeadingZeros(i);
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countLeadingZeroBits-xj2QHRw, reason: not valid java name */
private static final int m279countLeadingZeroBitsxj2QHRw(short s) {
return Integer.numberOfLeadingZeros(s & UShort.MAX_VALUE) - 16;
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countOneBits-7apg3OU, reason: not valid java name */
private static final int m280countOneBits7apg3OU(byte b) {
return Integer.bitCount(UInt.m125constructorimpl(b & UByte.MAX_VALUE));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countOneBits-VKZWuLQ, reason: not valid java name */
private static final int m281countOneBitsVKZWuLQ(long j) {
return Long.bitCount(j);
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countOneBits-WZ4Q5Ns, reason: not valid java name */
private static final int m282countOneBitsWZ4Q5Ns(int i) {
return Integer.bitCount(i);
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countOneBits-xj2QHRw, reason: not valid java name */
private static final int m283countOneBitsxj2QHRw(short s) {
return Integer.bitCount(UInt.m125constructorimpl(s & UShort.MAX_VALUE));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countTrailingZeroBits-7apg3OU, reason: not valid java name */
private static final int m284countTrailingZeroBits7apg3OU(byte b) {
return Integer.numberOfTrailingZeros(b | UByte.MIN_VALUE);
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countTrailingZeroBits-VKZWuLQ, reason: not valid java name */
private static final int m285countTrailingZeroBitsVKZWuLQ(long j) {
return Long.numberOfTrailingZeros(j);
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countTrailingZeroBits-WZ4Q5Ns, reason: not valid java name */
private static final int m286countTrailingZeroBitsWZ4Q5Ns(int i) {
return Integer.numberOfTrailingZeros(i);
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: countTrailingZeroBits-xj2QHRw, reason: not valid java name */
private static final int m287countTrailingZeroBitsxj2QHRw(short s) {
return Integer.numberOfTrailingZeros(s | UShort.MIN_VALUE);
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateLeft-JSWoG40, reason: not valid java name */
private static final long m288rotateLeftJSWoG40(long j, int i) {
return ULong.m204constructorimpl(Long.rotateLeft(j, i));
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateLeft-LxnNnR4, reason: not valid java name */
private static final byte m289rotateLeftLxnNnR4(byte b, int i) {
return UByte.m48constructorimpl(NumbersKt__NumbersKt.rotateLeft(b, i));
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateLeft-V7xB4Y4, reason: not valid java name */
private static final int m290rotateLeftV7xB4Y4(int i, int i2) {
return UInt.m125constructorimpl(Integer.rotateLeft(i, i2));
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateLeft-olVBNx4, reason: not valid java name */
private static final short m291rotateLeftolVBNx4(short s, int i) {
return UShort.m311constructorimpl(NumbersKt__NumbersKt.rotateLeft(s, i));
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateRight-JSWoG40, reason: not valid java name */
private static final long m292rotateRightJSWoG40(long j, int i) {
return ULong.m204constructorimpl(Long.rotateRight(j, i));
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateRight-LxnNnR4, reason: not valid java name */
private static final byte m293rotateRightLxnNnR4(byte b, int i) {
return UByte.m48constructorimpl(NumbersKt__NumbersKt.rotateRight(b, i));
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateRight-V7xB4Y4, reason: not valid java name */
private static final int m294rotateRightV7xB4Y4(int i, int i2) {
return UInt.m125constructorimpl(Integer.rotateRight(i, i2));
}
@SinceKotlin(version = "1.6")
@InlineOnly
/* renamed from: rotateRight-olVBNx4, reason: not valid java name */
private static final short m295rotateRightolVBNx4(short s, int i) {
return UShort.m311constructorimpl(NumbersKt__NumbersKt.rotateRight(s, i));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeHighestOneBit-7apg3OU, reason: not valid java name */
private static final byte m296takeHighestOneBit7apg3OU(byte b) {
return UByte.m48constructorimpl((byte) Integer.highestOneBit(b & UByte.MAX_VALUE));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeHighestOneBit-VKZWuLQ, reason: not valid java name */
private static final long m297takeHighestOneBitVKZWuLQ(long j) {
return ULong.m204constructorimpl(Long.highestOneBit(j));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeHighestOneBit-WZ4Q5Ns, reason: not valid java name */
private static final int m298takeHighestOneBitWZ4Q5Ns(int i) {
return UInt.m125constructorimpl(Integer.highestOneBit(i));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeHighestOneBit-xj2QHRw, reason: not valid java name */
private static final short m299takeHighestOneBitxj2QHRw(short s) {
return UShort.m311constructorimpl((short) Integer.highestOneBit(s & UShort.MAX_VALUE));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeLowestOneBit-7apg3OU, reason: not valid java name */
private static final byte m300takeLowestOneBit7apg3OU(byte b) {
return UByte.m48constructorimpl((byte) Integer.lowestOneBit(b & UByte.MAX_VALUE));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeLowestOneBit-VKZWuLQ, reason: not valid java name */
private static final long m301takeLowestOneBitVKZWuLQ(long j) {
return ULong.m204constructorimpl(Long.lowestOneBit(j));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeLowestOneBit-WZ4Q5Ns, reason: not valid java name */
private static final int m302takeLowestOneBitWZ4Q5Ns(int i) {
return UInt.m125constructorimpl(Integer.lowestOneBit(i));
}
@SinceKotlin(version = "1.5")
@InlineOnly
/* renamed from: takeLowestOneBit-xj2QHRw, reason: not valid java name */
private static final short m303takeLowestOneBitxj2QHRw(short s) {
return UShort.m311constructorimpl((short) Integer.lowestOneBit(s & UShort.MAX_VALUE));
}
}