Skip to content

Merge branch 'master' into monero-v0.18.3.4 #178

Merge branch 'master' into monero-v0.18.3.4

Merge branch 'master' into monero-v0.18.3.4 #178

Workflow file for this run

name: Build xmruw
on: [push]
permissions:
issues: write
pull-requests: write
jobs:
android:
strategy:
matrix:
coin: [monero, wownero]
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: |
sudo apt update
sudo apt install -y build-essential pkg-config autoconf libtool ccache make cmake gcc g++ git curl lbzip2 libtinfo5 gperf unzip python-is-python3 jq
- uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: recursive
- name: Patch sources
run: |
git config --global --add safe.directory '*'
git config --global user.email "[email protected]"
git config --global user.name "CI mrcyjanek.net"
./apply_patches.sh ${{ matrix.coin }}
- name: ${{ matrix.coin }}/aarch64-linux-android
run: ./build_single.sh ${{ matrix.coin }} aarch64-linux-android -j$(nproc)
- name: clone xmruw
run: |
git clone https://github.com/mrcyjanek/unnamed_monero_wallet
cd unnamed_monero_wallet
cp -a .fvm* ..
- uses: kuhnroyal/flutter-fvm-config-action@v2
id: fvm-config-action
- uses: subosito/flutter-action@v2
with:
flutter-version: ${{ steps.fvm-config-action.outputs.FLUTTER_VERSION }}
channel: ${{ steps.fvm-config-action.outputs.FLUTTER_CHANNEL }}
- uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '17'
- name: build xmruw (${{ matrix.coin }})
run: |
cd unnamed_monero_wallet
if [[ "${{ matrix.coin }}" == "monero" ]]; then ./codegen.sh -DCOIN_MONERO -DLIBSTEALTH_DISABLED; fi
if [[ "${{ matrix.coin }}" == "wownero" ]]; then ./codegen.sh -DCOIN_WOWNERO -DLIBSTEALTH_DISABLED; fi
flutter pub get
make version
./build_changelog.sh
cp ../release/${{ matrix.coin }}/aarch64-linux-android_libwallet2_api_c.so.xz android/app/src/main/jniLibs/arm64-v8a/lib${{ matrix.coin }}_libwallet2_api_c.so.xz
unxz -f android/app/src/main/jniLibs/arm64-v8a/*.xz
flutter build apk --debug --flavor clean_${{ matrix.coin }}
- name: Upload APK
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.coin }} xmruw apk
path: unnamed_monero_wallet/build/app/outputs/flutter-apk/*.apk
- uses: actions/github-script@v7
continue-on-error: true
id: get_issue_number
with:
script: |
if (context.issue.number) {
// Return issue number if present
return context.issue.number;
} else {
// Otherwise return issue number from commit
return (
await github.rest.repos.listPullRequestsAssociatedWithCommit({
commit_sha: context.sha,
owner: context.repo.owner,
repo: context.repo.repo,
})
).data[0].number;
}
result-encoding: string
- name: Find Comment
continue-on-error: true
uses: peter-evans/find-comment@v3
id: fc
with:
issue-number: ${{steps.get_issue_number.outputs.result}}
comment-author: 'github-actions[bot]'
body-includes: download xmruw
- name: Update comment
continue-on-error: true
if: steps.fc.outcome == 'success'
uses: peter-evans/create-or-update-comment@v4
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{steps.get_issue_number.outputs.result}}
body: |
[download xmruw #${{github.run_id}}](https://nightly.link/MrCyjaneK/monero_c/actions/runs/${{github.run_id}})
edit-mode: replace
- name: Create comment
continue-on-error: true
if: steps.fc.outcome == 'failure'
uses: peter-evans/create-or-update-comment@v4
with:
issue-number: ${{steps.get_issue_number.outputs.result}}
body: |
[download xmruw #${{github.run_id}}](https://nightly.link/MrCyjaneK/monero_c/actions/runs/${{github.run_id}}) (this link will update whenever you push)