summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick McDermott <patrick.mcdermott@libiquity.com>2019-06-24 19:57:43 (EDT)
committer Patrick McDermott <patrick.mcdermott@libiquity.com>2019-06-24 19:57:43 (EDT)
commitcafd58a117ff1dc550629b8c0142f2402ae70601 (patch)
tree0ea112b6c59592753dcc44f22a95355ed8c5ebe3
parentfcca5bf324f9f0ff8283590b57b19eca0a816926 (diff)
source.mk: Handle ABI version in OPK_SOURCE
-rw-r--r--source.mk11
1 files changed, 6 insertions, 5 deletions
diff --git a/source.mk b/source.mk
index f7457bf..22a8b21 100644
--- a/source.mk
+++ b/source.mk
@@ -1,5 +1,6 @@
-upstream_archive = $(OPK_SOURCE)-$(OPK_SOURCE_VERSION_UPSTREAM).tar.gz
-upstream_url = http://ftp.gnu.org/pub/gnu/$(OPK_SOURCE)/$(upstream_archive)
+source = $$(printf '%s\n' '$(OPK_SOURCE)' | sed 's/[.].*//')
+upstream_archive = $(source)-$(OPK_SOURCE_VERSION_UPSTREAM).tar.gz
+upstream_url = http://ftp.gnu.org/pub/gnu/$(source)/$(upstream_archive)
source_archive = ../$(OPK_SOURCE)-$(OPK_SOURCE_VERSION_UPSTREAM).orig.tar.gz
gpg = GNUPGHOME=gnupghome/ gpg --no-default-keyring --keyring ../keyring.gpg
@@ -7,17 +8,17 @@ keys = \
'7C01 35FB 088A AF6C 66C6 50B9 BB58 69F0 64EA 74AB'
$(source_archive):
- wget -c '$(upstream_url)' '$(upstream_url).sig'
+ 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 \
+ if ! $(gpg) --verify "$(upstream_archive).sig"; then \
rm -Rf gnupghome/; \
exit 1; \
fi
rm -Rf gnupghome/
- mv '$(upstream_archive)' '$(source_archive)'
+ mv "$(upstream_archive)" '$(source_archive)'
source: $(source_archive)