summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkx <kx@radix.pro>2024-01-16 14:03:30 +0300
committerkx <kx@radix.pro>2024-01-16 14:03:30 +0300
commit5634c38b53f685ff4e67b810c06334213999dc34 (patch)
tree7e7a3cb93c80388078c3918f567a82ff1b0295d2
parent9ec0bbd85bd2ebb443489d974d647927227ed36b (diff)
downloadsources-5634c38b53f685ff4e67b810c06334213999dc34.tar.xz
transmission: download release instead of snapshot
-rw-r--r--packages/x/transmission/Makefile41
1 files changed, 12 insertions, 29 deletions
diff --git a/packages/x/transmission/Makefile b/packages/x/transmission/Makefile
index 2b5c04a..34eca14 100644
--- a/packages/x/transmission/Makefile
+++ b/packages/x/transmission/Makefile
@@ -7,53 +7,36 @@
# =====
# git clone https://github.com/transmission/transmission.git
#
+# Releases:
+# ========
+# https://github.com/transmission/transmission/releases
+#
-url = https://github.com/transmission
+url = https://github.com/transmission/transmission/releases/download
-repo_name = transmission
pkg_name = transmission
suffix = tar.xz
versions = 4.0.5
-git_repo = .git_clone
tarballs = $(addsuffix .tar.xz, $(addprefix $(pkg_name)-, $(versions)))
sha1s = $(addsuffix .sha1sum, $(tarballs))
-TARGETS = repository_clean
-
-
-all: $(TARGETS)
+all: $(tarballs) $(sha1s)
-.PHONY: downloads_clean repository_clean
+.PHONY: downloads_clean
-$(git_repo):
- @echo -e "\n======= Clone $(repo_name).git repository =======\n"
- @rm -rf $(repo_name)
- @git clone $(url)/$(repo_name).git $(repo_name)
- @touch $@
-
-$(tarballs): $(git_repo)
+$(tarballs):
+ @echo -e "\n======= Downloading source tarballs =======\n"
@for version in $(versions) ; do \
- tag=`echo $$version` ; \
- if [ ! -f $(repo_name)-$$version.$(suffix) ]; then \
- echo -e "\n======= Creating '$(repo_name)-$$version.$(suffix)' snapshot =======" ; \
- ( cd $(repo_name) && \
- git archive --format=tar --prefix=$(pkg_name)-$$version/ $$tag | \
- xz >../$(pkg_name)-$$version.$(suffix) ) ; \
- fi ; \
+ wget -N $(url)/$${version}/$(pkg_name)-$${version}.$(suffix) ; \
done
-$(sha1s): %.tar.xz.sha1sum : %.tar.xz
+$(sha1s): %.$(suffix).sha1sum : %.$(suffix)
@for tarball in $< ; do \
- echo -e "\n======= Calculation the '$$tarball' sha1sum =======" ; \
+ echo -e "\n======= Calculation the '$$tarball' sha1sum =======\n" ; \
sha1sum --binary $$tarball > $$tarball.sha1sum ; \
done
-repository_clean: $(sha1s)
- @echo -e "\n======= Remove cloned $(repo_name).git repository =======\n"
- @rm -rf $(git_repo) $(repo_name)
-
downloads_clean:
@rm -rf $(tarballs) $(sha1s)
- @rm -rf $(git_repo) $(repo_name)