Build #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
workflow_dispatch: | |
branches: | |
- '**' | |
jobs: | |
build: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@main | |
with: | |
submodules: true | |
- name: Free up some space | |
run: | | |
sudo apt purge --allow-remove-essential --auto-remove \ | |
'*apache2*' \ | |
'*docker*' \ | |
'*dotnet*' \ | |
'*firefox*' \ | |
'*google*' \ | |
'*gstreamer*' \ | |
'*jdk*' \ | |
'*nginx*' \ | |
'*php*' \ | |
'*ruby*' \ | |
'*wayland*' \ | |
'auto*' \ | |
'azure-cli' \ | |
'bind9*' \ | |
'binutils*' \ | |
'build-essential' \ | |
'clang*' \ | |
'container*' \ | |
'fonts*' \ | |
'gcc-9' \ | |
'gcc-10' \ | |
'gcc-11' \ | |
'gcc-12' \ | |
'gh' \ | |
'glib*' \ | |
'libmono*' \ | |
'lld*' \ | |
'llvm*' \ | |
'mercurial*' \ | |
'mysql*' \ | |
'postgresql*' \ | |
'powershell' \ | |
'vim*' \ | |
'x11*' \ | |
'xdg*' > '/dev/null' | |
sudo rm --recursive --force \ | |
"${HOME}/.cargo" \ | |
"${HOME}/.rustup" \ | |
"${HOME}/linuxbrew" \ | |
'/etc/cni/net.d' \ | |
'/etc/docker' \ | |
'/etc/mono' \ | |
'/etc/mysql' \ | |
'/lib/tmpfiles.d' \ | |
'/opt/'* \ | |
'/opt/az' \ | |
'/usr/lib/heroku' \ | |
'/usr/lib/mono' \ | |
'/usr/libexec/docker' \ | |
'/usr/local/lib/android' \ | |
'/usr/local/lib/android' \ | |
'/usr/local/share/man' \ | |
'/usr/local/share/vcpkg' \ | |
'/usr/share/fonts' \ | |
'/usr/share/icons' \ | |
'/usr/share/java' \ | |
'/usr/share/php' \ | |
'/usr/share/swift' \ | |
'/var/lib/apache2' \ | |
'/var/lib/gems' \ | |
'/var/log' | |
- name: Install required dependencies | |
run: | | |
sudo apt install cmake golang-go libuv1 make ninja-build yasm openjdk-11-jdk-headless | |
update-java-alternatives --set java-1.11.0-openjdk-amd64 | |
- name: Setup API keys | |
run: | | |
echo -e 'APP_ID = 105810\nAPP_HASH = 3e7a52498eec003c5896a330e5d29397' > API_KEYS | |
echo -e 'APP_ID = 105810\nAPP_HASH = 3e7a52498eec003c5896a330e5d29397' > ./TMessagesProj/API_KEYS | |
echo -e 'APP_ID = 105810\nAPP_HASH = 3e7a52498eec003c5896a330e5d29397' > ./TMessagesProj_App/API_KEYS | |
- name: Setup Android cross-compiler | |
uses: nttld/setup-ndk@main | |
id: setup-ndk | |
with: | |
ndk-version: r21e | |
- name: Post setup settings for Android cross-compiler | |
run: | | |
echo 'NDK=${{ steps.setup-ndk.outputs.ndk-path }}' >> "${GITHUB_ENV}" | |
- name: Setup upterm session | |
if: false | |
uses: lhotari/action-upterm@v1 | |
- name: Build shit | |
working-directory: ./TMessagesProj/jni | |
run: | | |
./build_libvpx_clang.sh | |
./build_ffmpeg_clang.sh | |
./patch_ffmpeg.sh | |
./patch_boringssl.sh | |
NINJA_PATH='/usr/bin/ninja' ./build_boringssl.sh | |
- name: Build with Gradle | |
run: | | |
bash gradlew assembleAfatRelease | |
find . |