From 638f79bcdca598e9a5bbecdff2c07844a3454580 Mon Sep 17 00:00:00 2001 From: LizJeong Date: Thu, 18 Jul 2024 12:04:47 +0900 Subject: [PATCH] Update build-linux-amd64.yml --- .github/workflows/build-linux-amd64.yml | 39 +++++++++---------------- 1 file changed, 14 insertions(+), 25 deletions(-) diff --git a/.github/workflows/build-linux-amd64.yml b/.github/workflows/build-linux-amd64.yml index 27f0697c..830a25c7 100644 --- a/.github/workflows/build-linux-amd64.yml +++ b/.github/workflows/build-linux-amd64.yml @@ -40,8 +40,6 @@ jobs: - name: Set environment variables run: | - L1_NETWORK_NAME="initiation-1" - echo "L1_NETWORK_NAME=${L1_NETWORK_NAME}" >> $GITHUB_ENV echo "GOARCH=${{ inputs.arch }}" >> $GITHUB_ENV echo "GOOS=linux" >> $GITHUB_ENV if [[ "${GITHUB_REF}" == refs/tags/* ]]; then @@ -57,36 +55,27 @@ jobs: else echo "ARCH_NAME=${{ inputs.arch }}" >> $GITHUB_ENV fi - - name: Print environment variables run: | echo "GOARCH=${GOARCH}" echo "GOOS=${GOOS}" echo "VERSION=${VERSION}" - echo "L1_NETWORK_NAME=${L1_NETWORK_NAME}" - - # - name: Build for Linux AMD64 - # run: | - # export GOARCH=${GOARCH} - # export GOOS=${GOOS} - # make build-linux-with-shared-library - # cd ./build - # mkdir -p initia_${VERSION} - # mv libmovevm.so initia_${VERSION}/libmovevm.${ARCH_NAME}.so - # mv libcompiler.so initia_${VERSION}/libcompiler.${ARCH_NAME}.so - # mv initiad initia_${VERSION}/ - # tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz initia_${VERSION} - - name: Build for Linux AMD64 run: | - cd ../initia \ - && make build \ - && cd ./build \ - && cp ~/go/pkg/mod/github.com/initia-labs/movevm@"$MOVEVM_VERSION"/api/libmovevm.dylib ./ \ - && cp ~/go/pkg/mod/github.com/initia-labs/movevm@"$MOVEVM_VERSION"/api/libcompiler.dylib ./ \ - && tar -czvf initia_"$VERSION"_Darwin_"$ARCH_NAME".tar.gz initiad libmovevm.dylib libcompiler.dylib \ - && mv ./initia_"$VERSION"_Darwin_"$ARCH_NAME".tar.gz $GITHUB_WORKSPACE/ \ - && rm -rf ./libmovevm.dylib ./libcompiler.dylib ./initiad + export GOARCH=${GOARCH} + export GOOS=${GOOS} + make build-linux-with-shared-library + cd ./build + mkdir -p initia_${VERSION} + mv libmovevm.so initia_${VERSION}/libmovevm.${ARCH_NAME}.so + mv libcompiler.so initia_${VERSION}/libcompiler.${ARCH_NAME}.so + mv initiad initia_${VERSION}/ + tar -czvf initia_${VERSION}_Linux_${ARCH_NAME}.tar.gz initia_${VERSION} + - name: Release + uses: softprops/action-gh-release@v1 + with: + files: | + ./build/initia_${{ env.VERSION }}_Linux_${{ env.ARCH_NAME }}.tar.gz - name: Release uses: softprops/action-gh-release@v1