Skip to content

Commit 4dc4fe1

Browse files
committed
Update binary compression steps to follow symlinks for actual files
By default, zip follows symbolic links and includes the actual files or directories they point to in the archive.
1 parent 93ef19b commit 4dc4fe1

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

.github/workflows/build_iwasm_release.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,15 +129,17 @@ jobs:
129129
- name: Compress the binary on Windows
130130
if: inputs.runner == 'windows-latest'
131131
run: |
132-
tar -czf iwasm${{ matrix.suffix }}-${{ inputs.ver_num }}-${{ inputs.runner }}.tar.gz iwasm.exe
132+
# Follow the symlink to the actual binary file
133+
tar --dereference -czf iwasm${{ matrix.suffix }}-${{ inputs.ver_num }}-${{ inputs.runner }}.tar.gz iwasm.exe
133134
Compress-Archive -Path iwasm.exe -DestinationPath iwasm${{ matrix.suffix }}-${{ inputs.ver_num }}-${{ inputs.runner }}.zip
134135
mv iwasm${{ matrix.suffix }}-${{ inputs.ver_num }}-${{ inputs.runner }}.* ../
135136
working-directory: ${{ inputs.cwd }}/build/Release
136137

137138
- name: compress the binary on non-Windows
138139
if: inputs.runner != 'windows-latest'
139140
run: |
140-
tar czf iwasm${{ matrix.suffix }}-${{ inputs.ver_num }}-${{ inputs.runner }}.tar.gz iwasm
141+
# Follow the symlink to the actual binary file
142+
tar --dereference -czf iwasm${{ matrix.suffix }}-${{ inputs.ver_num }}-${{ inputs.runner }}.tar.gz iwasm
141143
zip iwasm${{ matrix.suffix }}-${{ inputs.ver_num }}-${{ inputs.runner }}.zip iwasm
142144
working-directory: ${{ inputs.cwd }}/build
143145

0 commit comments

Comments
 (0)