From c4722fe5aed96295837d9150b20ef8698c7a28db Mon Sep 17 00:00:00 2001 From: Rui Ueyama Date: Sun, 5 Mar 2023 14:36:21 +0800 Subject: [PATCH] Build Linux binaries on GitHub Actions --- .github/workflows/linux-packages.yml | 15 +++++++++++++++ dist.sh | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/linux-packages.yml diff --git a/.github/workflows/linux-packages.yml b/.github/workflows/linux-packages.yml new file mode 100644 index 0000000000..ee4fc916c6 --- /dev/null +++ b/.github/workflows/linux-packages.yml @@ -0,0 +1,15 @@ +name: linux-packages +on: + push: + branches: [ main ] +jobs: + build: + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v3 + - name: build + run: ./dist.sh x86_64 + - name: upload + uses: actions/upload-artifact@v3 + with: + path: mold-*-linux.tar.gz diff --git a/dist.sh b/dist.sh index 550f636207..bb33dbe362 100755 --- a/dist.sh +++ b/dist.sh @@ -27,7 +27,7 @@ version=$(sed -n 's/^project(mold VERSION \(.*\))/\1/p' $(dirname $0)/CMakeLists dest=mold-$version-$arch-linux set -e -x -docker run --platform linux/$arch -it --rm -v "$(pwd):/mold" \ +docker run --platform linux/$arch -i --rm -v "$(pwd):/mold" \ -e "OWNER=$(id -u):$(id -g)" rui314/mold-builder:latest \ bash -c "mkdir /tmp/build && cd /tmp/build &&