Radix cross Linux 3pp sources

RcL sources – is a tree of Third Party and Radix source tarballs

423 Commits   0 Branches   0 Tags
author: kx <kx@radix.pro> 2023-11-06 11:55:51 +0300 committer: kx <kx@radix.pro> 2023-11-06 11:55:51 +0300 commit: 65ec48ee4c286fbc12dd6b4034245e760e659597 parent: 8fadba50228a3b20ea0457427ccab75fe06cc9f7
Commit Summary:
StarFive: u-boot
Diffstat:
2 files changed, 55 insertions, 0 deletions
diff --git a/U-Boot/Makefile b/U-Boot/Makefile
index 1daa836..2d5612d 100644
--- a/U-Boot/Makefile
+++ b/U-Boot/Makefile
@@ -5,6 +5,7 @@
 #
 
 SUBDIRS := ATF         \
+           StarFive    \
            denx        \
            rkbin
 
diff --git a/U-Boot/StarFive/Makefile b/U-Boot/StarFive/Makefile
new file mode 100644
index 0000000..97356d3
--- /dev/null
+++ b/U-Boot/StarFive/Makefile
@@ -0,0 +1,68 @@
+#
+# Project Home:
+# ============
+#   https://github.com/starfive-tech/u-boot.git
+#
+# Git Mirror:
+# ==========
+#   https://git.radix.pro/starfive-tech/u-boot.git
+#
+
+url        = https://github.com/starfive-tech
+
+repo_name  = u-boot
+
+#
+# List of tags to be extracted (branch JH7110_VisionFive2_devel):
+# ====================================================================
+#
+#                                               hash | version     | tag
+#            ----------------------------------------+-------------+---------
+revisions  = 84c81d3d0254adb8ae88d5e0633bf01c12436898:2021.10-3.8.2:VF2_6.1_v3.8.2
+
+git_repo   = .git_clone
+
+pkgname    = u-boot
+suffix     = tar.xz
+
+versions   = $(foreach tag, $(revisions), $(shell echo $(tag) | cut -f 2 -d ':'))
+tarballs   = $(addsuffix .$(suffix), $(addprefix $(pkgname)-, $(versions)))
+sha1s      = $(addsuffix .sha1sum, $(tarballs))
+
+TARGETS = repository_clean
+
+all: $(TARGETS)
+
+.PHONY: downloads_clean repository_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)
+	@for revision in $(revisions) ; do \
+	  hash=`echo $$revision | cut -f 1 -d ':'` ; \
+	  version=`echo $$revision | cut -f 2 -d ':'` ; \
+	  if [ ! -f $(pkgname)-$$version.$(suffix) ]; then \
+	    echo -e "\n======= Creating '$(pkgname)-$$version.$(suffix)' snapshot =======" ; \
+	    ( cd $(repo_name) && \
+	      git archive --format=tar --prefix=$(pkgname)-$$version/ $$hash | \
+	      xz >../$(pkgname)-$$version.$(suffix) ) ; \
+	  fi ; \
+	done
+
+$(sha1s): %.$(suffix).sha1sum : %.$(suffix)
+	@for tarball in $< ; do \
+	  echo -e "\n======= Calculation the '$$tarball' sha1sum =======" ; \
+	  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)