From e6670cd29716c61fc96118a94c2edadf3e375a3b Mon Sep 17 00:00:00 2001 From: Anjan Nath Date: Thu, 28 Jul 2022 18:55:44 +0530 Subject: pkginstaller: add makefile target to notarize the built pkg [NO NEW TESTS NEEDED] Signed-off-by: Anjan Nath --- contrib/pkginstaller/Makefile | 7 +++++++ contrib/pkginstaller/README.md | 3 +++ 2 files changed, 10 insertions(+) diff --git a/contrib/pkginstaller/Makefile b/contrib/pkginstaller/Makefile index 984365ccb..7863a237b 100644 --- a/contrib/pkginstaller/Makefile +++ b/contrib/pkginstaller/Makefile @@ -9,6 +9,7 @@ QEMU_RELEASE_URL ?= https://github.com/containers/podman-machine-qemu/releases/d PACKAGE_DIR ?= out/packaging TMP_DOWNLOAD ?= tmp-download PACKAGE_ROOT ?= root +PKG_NAME := podman-installer-macos-$(ARCH).pkg default: pkginstaller @@ -46,6 +47,12 @@ package_root: get_gvproxy get_qemu pkginstaller: packagedir cd $(PACKAGE_DIR) && ./package.sh .. +_notarize: pkginstaller + xcrun notarytool submit --apple-id $(NOTARIZE_USERNAME) --password $(NOTARIZE_PASSWORD) --team-id=$(NOTARIZE_TEAM) -f json --wait out/$(PKG_NAME) + +notarize: _notarize + xcrun stapler staple out/$(PKG_NAME) + .PHONY: clean clean: rm -rf $(TMP_DOWNLOAD) $(PACKAGE_ROOT) $(PACKAGE_DIR) Distribution welcome.html diff --git a/contrib/pkginstaller/README.md b/contrib/pkginstaller/README.md index 37c59ce04..1951d4eab 100644 --- a/contrib/pkginstaller/README.md +++ b/contrib/pkginstaller/README.md @@ -5,6 +5,9 @@ $ make ARCH= NO_CODESIGN=1 pkginstaller # or to create signed pkg $ make ARCH= CODESIGN_IDENTITY= PRODUCTSIGN_IDENTITY= pkginstaller + +# or to prepare a signed and notarized pkg for release +$ make ARCH= CODESIGN_IDENTITY= PRODUCTSIGN_IDENTITY= NOTARIZE_USERNAME= NOTARIZE_PASSWORD= NOTARIZE_TEAM= notarize ``` The generated pkg will be written to `out/podman-macos-installer-*.pkg`. -- cgit v1.2.3-54-g00ecf