diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 696eea1fab89..7b97fdbb580d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -218,6 +218,7 @@ jobs: - name: Verify native libraries in APK run: | APK="${{ steps.find_apk.outputs.apk_path }}" + SUBMOD="submodules/osu-framework/osu.Framework.Android/arm64-v8a" echo "Checking APK for required native libraries..." NATIVE_LIBS=$(unzip -l "$APK" | grep "lib/arm64-v8a/.*\.so" || true) @@ -243,6 +244,24 @@ jobs: echo "" echo "All required native libraries present ✓" + # Verify the BASS libraries are the Android-built versions, not the Linux desktop + # ones from the NativeLibs NuGet package. The Android libbass.so links against + # libOpenSLES.so (Android audio API); the Linux one links against libc.so.6. + echo "" + echo "Verifying native library ABI compatibility..." + TMPDIR=$(mktemp -d) + unzip -q -o "$APK" "lib/arm64-v8a/libbass.so" -d "$TMPDIR" + if readelf -d "$TMPDIR/lib/arm64-v8a/libbass.so" | grep -q "libOpenSLES.so"; then + echo "✅ libbass.so is the correct Android build (links libOpenSLES.so)" + else + echo "::error::libbass.so in APK is NOT the Android build — it appears to be the Linux desktop version from ppy.osu.Framework.NativeLibs NuGet. The app will crash with DllNotFoundException." + echo "::error::Ensure ppy.osu.Framework.NativeLibs has ExcludeAssets=native in osu.Android.props." + readelf -d "$TMPDIR/lib/arm64-v8a/libbass.so" | grep NEEDED || true + rm -rf "$TMPDIR" + exit 1 + fi + rm -rf "$TMPDIR" + - name: Upload APK artifact uses: actions/upload-artifact@v7 with: diff --git a/osu.Android.props b/osu.Android.props index 316f80e192ef..682277e1b8db 100644 --- a/osu.Android.props +++ b/osu.Android.props @@ -86,6 +86,18 @@ + + +