From 690de72a02b67a832ff81d25ea3e87bfcc99767b Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Wed, 01 May 2019 23:03:47 -0400 Subject: source.mk: New file --- diff --git a/build b/build index 5813b2c..90c4b5d 100755 --- a/build +++ b/build @@ -1,5 +1,7 @@ #! /usr/bin/make -f +include ../source.mk + nop: @: diff --git a/control b/control index 90be2cd..7d44844 100644 --- a/control +++ b/control @@ -1,3 +1,3 @@ Maintainer: Warren McDonald -Build-Depends: opkhelper-3.0, libgmp-dev +Build-Depends: gpg, dirmngr, opkhelper-3.0, libgmp-dev Homepage: http://www.mpfr.org/ diff --git a/source.mk b/source.mk new file mode 100644 index 0000000..7930244 --- /dev/null +++ b/source.mk @@ -0,0 +1,23 @@ +upstream_archive = $(OPK_SOURCE)-$(OPK_SOURCE_VERSION_UPSTREAM).tar.xz +upstream_url = http://ftp.gnu.org/pub/gnu/$(OPK_SOURCE)/$(upstream_archive) +source_archive = ../$(OPK_SOURCE)-$(OPK_SOURCE_VERSION_UPSTREAM).orig.tar.xz + +gpg = GNUPGHOME=gnupghome/ gpg --no-default-keyring --keyring ../keyring.gpg +keys = \ + '07F3 DBBE CC1A 3960 5078 094D 980C 1976 98C3 739D' + +$(source_archive): + wget -c '$(upstream_url)' '$(upstream_url).sig' + install -m 0700 -d gnupghome/ + [ -e ../keyring.gpg ] || \ + $(gpg) --keyserver hkp://pool.sks-keyservers.net \ + --recv-keys $(keys); \ + rm -f ../keyring.gpg~; \ + if ! $(gpg) --verify '$(upstream_archive).sig'; then \ + rm -Rf gnupghome/; \ + exit 1; \ + fi + rm -Rf gnupghome/ + mv '$(upstream_archive)' '$(source_archive)' + +source: $(source_archive) -- cgit v0.9.1