summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2022-09-28 15:03:32 -0700
committerGitHub <noreply@github.com>2022-09-28 15:03:32 -0700
commit3dce6e08dd74c6dfbfb8f553eaf18200a6bf6f2a (patch)
tree54940c59f4af40704c2ea4b13bc4804305f21c26
parenteb5c6b93543ca1423117045dbbfee0b6f653d392 (diff)
Fix release CI script. (#2419)
* Fix release CI script. * Fix. * Fix. Co-authored-by: Yong He <yhe@nvidia.com>
-rw-r--r--.github/workflows/release-macos.yml17
-rw-r--r--.github/workflows/release-windows.yml1
-rw-r--r--extras/macos-sign.json6
-rw-r--r--github_build.sh2
-rw-r--r--github_macos_build.sh2
5 files changed, 17 insertions, 11 deletions
diff --git a/.github/workflows/release-macos.yml b/.github/workflows/release-macos.yml
index 663230f5f..75b70657f 100644
--- a/.github/workflows/release-macos.yml
+++ b/.github/workflows/release-macos.yml
@@ -65,14 +65,14 @@ jobs:
env:
IDENTITY_ID: d6ada82a113e4204aaad914e1013e9548ffd30d0
run: |
- /usr/bin/codesign --force --options runtime -s ${IDENTITY_ID} ./bin/macosx-x64/release/libslang.dylib -v
- /usr/bin/codesign --force --options runtime -s ${IDENTITY_ID} ./bin/macosx-x64/release/slangd -v
- /usr/bin/codesign --force --options runtime -s ${IDENTITY_ID} ./bin/macosx-x64/release/slangc -v
+ /usr/bin/codesign --force --options runtime -s ${IDENTITY_ID} ./bin/macosx-${{matrix.targetPlatform}}/release/libslang.dylib -v
+ /usr/bin/codesign --force --options runtime -s ${IDENTITY_ID} ./bin/macosx-${{matrix.targetPlatform}}/release/slangd -v
+ /usr/bin/codesign --force --options runtime -s ${IDENTITY_ID} ./bin/macosx-${{matrix.targetPlatform}}/release/slangc -v
- name: Package
id: package
run: |
export SLANG_OS_NAME=macos
- export SLANG_ARCH_NAME=`uname -p`
+ export SLANG_ARCH_NAME=${{matrix.targetPlatform}}
export TAG_NAME=`git describe --tags`
export SLANG_TAG=${TAG_NAME#v}
echo "tag:$TAG_NAME"
@@ -100,19 +100,20 @@ jobs:
env:
AC_PASSWORD: ${{secrets.APPLE_ID_PASSWORD}}
run: |
- cp ./bin/macosx-x64/release/libslang.dylib libslang.dylib
- cp ./bin/macosx-x64/release/slangd slangd
- cp ./bin/macosx-x64/release/slangc slangc
+ cp ./bin/macosx-${{matrix.targetPlatform}}/release/libslang.dylib libslang.dylib
+ cp ./bin/macosx-${{matrix.targetPlatform}}/release/slangd slangd
+ cp ./bin/macosx-${{matrix.targetPlatform}}/release/slangc slangc
7z a slang-macos-dist.zip libslang.dylib
7z a slang-macos-dist.zip slangd
7z a slang-macos-dist.zip slangc
+ cp slang-macos-dist.zip slang-macos-dist-${{matrix.targetPlatform}}.zip
timeout 1000 gon ./extras/macos-notarize.json
- name: UploadNotarizedBinary
if: always()
uses: softprops/action-gh-release@v1
with:
files: |
- slang-macos-dist.zip
+ slang-macos-dist-${{matrix.targetPlatform}}.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
diff --git a/.github/workflows/release-windows.yml b/.github/workflows/release-windows.yml
index 1b186b187..2ea80800d 100644
--- a/.github/workflows/release-windows.yml
+++ b/.github/workflows/release-windows.yml
@@ -28,6 +28,7 @@ jobs:
run: |
.\premake.bat vs2019 --arch=x64 --ignore-deps=slang-llvm,slang-glslang --no-progress=true
MSBuild.exe slang.sln -v:m -m -property:Configuration=Release -property:Platform=x64 -property:WindowsTargetPlatformVersion=10.0.19041.0
+ Remove-Item .\bin\* -Recurse -Force
.\premake.bat vs2019 --arch=${{matrix.platform}} --ignore-deps=slang-llvm,slang-glslang --no-progress=true --skip-source-generation=true --deploy-slang-llvm=false --deploy-slang-glslang=false
# Do the premake for the actual target, downloading dependencies if necessary
- name: premake
diff --git a/extras/macos-sign.json b/extras/macos-sign.json
index e645d35f9..db2bd8979 100644
--- a/extras/macos-sign.json
+++ b/extras/macos-sign.json
@@ -1,8 +1,8 @@
{
"source" : [
- "./bin/macosx-x64/release/libslang.dylib",
- "./bin/macosx-x64/release/slangc",
- "./bin/macosx-x64/release/slangd"
+ "./bin/macosx-*/release/libslang.dylib",
+ "./bin/macosx-*/release/slangc",
+ "./bin/macosx-*/release/slangd"
],
"bundle_id" : "shader-slang.slang",
"apple_id": {
diff --git a/github_build.sh b/github_build.sh
index bd07da2bb..e178b6cc9 100644
--- a/github_build.sh
+++ b/github_build.sh
@@ -19,6 +19,8 @@ if [[ "${ARCH}" != "${TARGETARCH}" ]]; then
# Build the configuration
make config=${CONFIGURATION}_${ARCH} -j`nproc`
+rm -rf ./bin
+
# Create the makefile
./premake5 gmake --cc=${CC} --enable-embed-stdlib=true --arch=${TARGETARCH} --deps=true --no-progress=true --skip-source-generation=true --deploy-slang-llvm=false --deploy-slang-glslang=false
diff --git a/github_macos_build.sh b/github_macos_build.sh
index 2fc9fce05..2683c2304 100644
--- a/github_macos_build.sh
+++ b/github_macos_build.sh
@@ -19,6 +19,8 @@ if [[ "${ARCH}" != "${TARGETARCH}" ]]; then
# Build the configuration
make config=${CONFIGURATION}_${ARCH} -j`sysctl -n hw.ncpu`
+rm -rf ./bin
+
# Create the makefile
./premake5 gmake --cc=${CC} --enable-xlib=false --enable-embed-stdlib=true --arch=${TARGETARCH} --deps=true --no-progress=true --skip-source-generation=true --deploy-slang-llvm=false --deploy-slang-glslang=false