summaryrefslogtreecommitdiffstats
path: root/source.mk
blob: 83437823c5f2571f80e3acbed895c44c3ad8bae5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
upstream_commit = $$(printf '%s\n' '$(OPK_SOURCE_VERSION_UPSTREAM)' | \
	sed 's/^.*~git........\.\([0-9a-f]*\).*$$/\1/')
upstream_git_uri = git://git.sv.gnu.org/libreboot.git
source_archive = ../$(OPK_SOURCE)-$(OPK_SOURCE_VERSION_UPSTREAM).orig.tar.bz2

$(source_archive):
	git clone '$(upstream_git_uri)' libreboot/
	(cd libreboot/ && git checkout "$(upstream_commit)")
	mv libreboot/resources/utilities/ich9deblob/ ich9deblob/
	tar -cjf '$@' ich9deblob/
	rm -Rf src/
	mv ich9deblob/ src/
	rm -Rf libreboot/

source: $(source_archive)