Skip to content

Commit

Permalink
Disabling macOS, Windows, and ARM in release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
kenshaw committed Jan 2, 2025
1 parent c0d0266 commit 5bdd98e
Showing 1 changed file with 149 additions and 149 deletions.
298 changes: 149 additions & 149 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,163 +12,163 @@ jobs:
strategy:
fail-fast: false
matrix:
arch: [amd64, arm, arm64]
arch: [amd64]
steps:
- name: Install build dependencies
run: |
sudo apt-get -qq update
sudo apt-get install -y \
build-essential \
qemu-user \
gcc-arm-linux-gnueabihf \
g++-arm-linux-gnueabihf \
gcc-aarch64-linux-gnu \
g++-aarch64-linux-gnu \
libstdc++6-armhf-cross \
libstdc++6-arm64-cross \
libc6-dev-armhf-cross \
libc6-dev-arm64-cross \
file \
libvips \
libvips-dev \
libfftw3-dev \
libopenexr-dev \
libgsf-1-dev \
libglib2.0-dev \
liborc-dev \
libopenslide-dev \
libmatio-dev \
libwebp-dev \
libjpeg-turbo8-dev \
libexpat1-dev \
libexif-dev \
libtiff5-dev \
libcfitsio-dev \
libpoppler-glib-dev \
librsvg2-dev \
libpango1.0-dev \
libopenjp2-7-dev \
liblcms2-dev \
libimagequant-dev
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
- name: Build ${{ matrix.arch }}
run: |
./build.sh -v $VER -a ${{ matrix.arch }}
- name: Build ${{ matrix.arch }} (static)
if: matrix.arch != 'arm'
run: |
./build.sh -v $VER -a ${{ matrix.arch }} -s
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: dist-linux-${{ matrix.arch }}
path: build/linux/**/*
if-no-files-found: error

build_for_macos:
name: Build for macOS
runs-on: macos-latest
strategy:
matrix:
arch: [amd64, arm64]
steps:
- name: Install build dependencies
run: |
brew install coreutils gnu-tar vips
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
- name: Build ${{ matrix.arch }}
run: |
./build.sh -v $VER -a ${{ matrix.arch }}
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: dist-darwin-${{ matrix.arch }}
path: build/darwin/**/*
if-no-files-found: error

build_for_macos_universal:
name: Build for macOS (universal)
needs:
- build_for_macos
runs-on: macos-latest
steps:
- name: Install build dependencies
run: |
brew install coreutils gnu-tar vips
- name: Download artifacts
uses: actions/download-artifact@v4
- name: Build universal
run: |
export WORKDIR=$PWD/build/darwin/universal/$VER
mkdir -p $WORKDIR
gtar -jxvf dist-darwin-amd64/*/*/*.tar.bz2 -C $WORKDIR $APP
gtar -jxvf dist-darwin-amd64/*/*/*.tar.bz2 -C $WORKDIR LICENSE
mv $WORKDIR/$APP $WORKDIR/$APP-amd64
gtar -jxvf dist-darwin-arm64/*/*/*.tar.bz2 -C $WORKDIR $APP
mv $WORKDIR/$APP $WORKDIR/$APP-arm64
file $WORKDIR/$APP-{amd64,arm64}
lipo -create -output $WORKDIR/$APP $WORKDIR/$APP-amd64 $WORKDIR/$APP-arm64
chmod +x $WORKDIR/$APP
file $WORKDIR/$APP
rm $WORKDIR/$APP-{amd64,arm64}
sudo /usr/sbin/purge
- name: Install build dependencies
run: |
sudo apt-get -qq update
sudo apt-get install -y \
build-essential \
qemu-user \
gcc-arm-linux-gnueabihf \
g++-arm-linux-gnueabihf \
gcc-aarch64-linux-gnu \
g++-aarch64-linux-gnu \
libstdc++6-armhf-cross \
libstdc++6-arm64-cross \
libc6-dev-armhf-cross \
libc6-dev-arm64-cross \
file \
libvips \
libvips-dev \
libfftw3-dev \
libopenexr-dev \
libgsf-1-dev \
libglib2.0-dev \
liborc-dev \
libopenslide-dev \
libmatio-dev \
libwebp-dev \
libjpeg-turbo8-dev \
libexpat1-dev \
libexif-dev \
libtiff5-dev \
libcfitsio-dev \
libpoppler-glib-dev \
librsvg2-dev \
libpango1.0-dev \
libopenjp2-7-dev \
liblcms2-dev \
libimagequant-dev
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: ${{ env.GO_VERSION }}
- name: Build ${{ matrix.arch }}
run: |
./build.sh -v $VER -a ${{ matrix.arch }}
# - name: Build ${{ matrix.arch }} (static)
# if: matrix.arch != 'arm'
# run: |
# ./build.sh -v $VER -a ${{ matrix.arch }} -s
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: dist-linux-${{ matrix.arch }}
path: build/linux/**/*
if-no-files-found: error

gtar -C $WORKDIR -cjf $WORKDIR/$APP-${VER#v}-darwin-universal.tar.bz2 $APP LICENSE
ls -alh $WORKDIR/*
sha256sum $WORKDIR/*
- name: Archive artifacts
uses: actions/upload-artifact@v4
with:
name: dist-darwin-universal
path: build/darwin/**/*
if-no-files-found: error
# build_for_macos:
# name: Build for macOS
# runs-on: macos-latest
# strategy:
# matrix:
# arch: [amd64, arm64]
# steps:
# - name: Install build dependencies
# run: |
# brew install coreutils gnu-tar vips
# - name: Checkout
# uses: actions/checkout@v4
# - name: Setup Go
# uses: actions/setup-go@v5
# with:
# go-version: ${{ env.GO_VERSION }}
# - name: Build ${{ matrix.arch }}
# run: |
# ./build.sh -v $VER -a ${{ matrix.arch }}
# - name: Archive artifacts
# uses: actions/upload-artifact@v4
# with:
# name: dist-darwin-${{ matrix.arch }}
# path: build/darwin/**/*
# if-no-files-found: error
#
# build_for_macos_universal:
# name: Build for macOS (universal)
# needs:
# - build_for_macos
# runs-on: macos-latest
# steps:
# - name: Install build dependencies
# run: |
# brew install coreutils gnu-tar vips
# - name: Download artifacts
# uses: actions/download-artifact@v4
# - name: Build universal
# run: |
# export WORKDIR=$PWD/build/darwin/universal/$VER
# mkdir -p $WORKDIR
#
# gtar -jxvf dist-darwin-amd64/*/*/*.tar.bz2 -C $WORKDIR $APP
# gtar -jxvf dist-darwin-amd64/*/*/*.tar.bz2 -C $WORKDIR LICENSE
# mv $WORKDIR/$APP $WORKDIR/$APP-amd64
#
# gtar -jxvf dist-darwin-arm64/*/*/*.tar.bz2 -C $WORKDIR $APP
# mv $WORKDIR/$APP $WORKDIR/$APP-arm64
#
# file $WORKDIR/$APP-{amd64,arm64}
#
# lipo -create -output $WORKDIR/$APP $WORKDIR/$APP-amd64 $WORKDIR/$APP-arm64
# chmod +x $WORKDIR/$APP
# file $WORKDIR/$APP
#
# rm $WORKDIR/$APP-{amd64,arm64}
#
# sudo /usr/sbin/purge
#
# gtar -C $WORKDIR -cjf $WORKDIR/$APP-${VER#v}-darwin-universal.tar.bz2 $APP LICENSE
# ls -alh $WORKDIR/*
# sha256sum $WORKDIR/*
# - name: Archive artifacts
# uses: actions/upload-artifact@v4
# with:
# name: dist-darwin-universal
# path: build/darwin/**/*
# if-no-files-found: error

# build_for_windows:
# name: Build for Windows
# runs-on: windows-latest
# steps:
# - name: Install build dependencies
# run: choco install zip
# - name: Checkout
# uses: actions/checkout@v4
# - name: Setup Go
# uses: actions/setup-go@v5
# with:
# go-version: ${{ env.GO_VERSION }}
# - name: Build amd64
# shell: bash
# run: |
# ./build.sh -v $VER
# - name: Archive artifacts
# uses: actions/upload-artifact@v4
# with:
# name: dist-windows
# path: build/windows/**/*
# if-no-files-found: error
# build_for_windows:
# name: Build for Windows
# runs-on: windows-latest
# steps:
# - name: Install build dependencies
# run: choco install zip
# - name: Checkout
# uses: actions/checkout@v4
# - name: Setup Go
# uses: actions/setup-go@v5
# with:
# go-version: ${{ env.GO_VERSION }}
# - name: Build amd64
# shell: bash
# run: |
# ./build.sh -v $VER
# - name: Archive artifacts
# uses: actions/upload-artifact@v4
# with:
# name: dist-windows
# path: build/windows/**/*
# if-no-files-found: error

release:
name: Draft Release
needs:
- build_for_linux
- build_for_macos
- build_for_macos_universal
# - build_for_windows
# - build_for_macos
# - build_for_macos_universal
# - build_for_windows
runs-on: ubuntu-latest
steps:
- name: Download artifacts
Expand Down

0 comments on commit 5bdd98e

Please sign in to comment.