build: use powershell to create zip file on windows

This commit is contained in:
Paul-Christian Volkmer 2024-06-07 11:32:30 +02:00
parent 2b94618f9f
commit 665e728040

View File

@ -16,7 +16,8 @@ win-package: win-binary-x86_64
cp target/x86_64-pc-windows-gnu/release/$(PROG_NAME).exe $(PROG_NAME)/ cp target/x86_64-pc-windows-gnu/release/$(PROG_NAME).exe $(PROG_NAME)/
cp README.md $(PROG_NAME)/ cp README.md $(PROG_NAME)/
cp LICENSE $(PROG_NAME)/ cp LICENSE $(PROG_NAME)/
zip $(PROG_NAME)-$(TAG)_win64.zip $(PROG_NAME)/* # first try (linux) zip command, then powershell sub command to create ZIP file
zip $(PROG_NAME)-$(TAG)_win64.zip $(PROG_NAME)/* || powershell Compress-ARCHIVE $(PROG_NAME) $(PROG_NAME)-$(TAG)_win64.zip
rm -rf $(PROG_NAME) || true rm -rf $(PROG_NAME) || true
.PHONY: linux-package .PHONY: linux-package