Skip to content

Commit fd8a58c

Browse files
authored
split universal macos binary into two (#28)
1 parent 749fd51 commit fd8a58c

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

.github/workflows/build-darwin.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,18 +29,19 @@ jobs:
2929
- name: Build and Package for Darwin
3030
run: |
3131
make build
32-
mv ./build/opinitd ./build/opinitd.arm64
32+
pushd build
33+
tar -czf "$GITHUB_WORKSPACE"/opinitd_"$VERSION"_Darwin_aarch64.tar.gz ./opinitd
34+
rm ./opinitd; popd
3335
GOARCH=amd64 make build
34-
mv ./build/opinitd ./build/opinitd.amd64
35-
lipo -create -output ./build/opinitd ./build/opinitd.arm64 ./build/opinitd.amd64
3636
pushd build
37-
tar -czf "$GITHUB_WORKSPACE"/opinitd_"$VERSION"_Darwin.tar.gz ./opinitd
38-
rm ./opinitd.arm64 ./opinitd.amd64 ./opinitd; popd
37+
tar -czf "$GITHUB_WORKSPACE"/opinitd_"$VERSION"_Darwin_x86_64.tar.gz ./opinitd
38+
rm ./opinitd; popd
3939
4040
- name: Release
4141
uses: softprops/action-gh-release@v2
4242
with:
4343
files: |
44-
opinitd_${{ env.VERSION }}_Darwin.tar.gz
44+
opinitd_${{ env.VERSION }}_Darwin_x86_64.tar.gz
45+
opinitd_${{ env.VERSION }}_Darwin_aarch64.tar.gz
4546
env:
4647
VERSION: ${{ env.VERSION }}

0 commit comments

Comments
 (0)