From 53b0da18ba034fa2bce45398a10ffe14c15dabb0 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Sat, 30 Mar 2013 19:43:01 -0400 Subject: build: Add targets to download and pack sources. --- diff --git a/build b/build index afadb90..bdbbafe 100755 --- a/build +++ b/build @@ -120,3 +120,9 @@ clean-locales: clean: clean-libc clean-locales rm -f configure build rm -Rf *.data + +# POSIX.1-2008: +# If the pathname does not begin with a '/' it shall be treated as relative to +# the current working directory of the process, not relative to the directory +# containing the makefile. +include ../source.mk diff --git a/source.mk b/source.mk new file mode 100644 index 0000000..35964b5 --- /dev/null +++ b/source.mk @@ -0,0 +1,18 @@ +UPSTREAM_SVN_BRANCH = eglibc-$$(printf '%s\n' '$(OPK_SOURCE_VERSION_UPSTREAM)' \ + | sed 's/^\([0-9][0-9]*\)\.\([0-9][0-9]*\)~.*$$/\1_\2/') +UPSTREAM_SVN_URI = svn://svn.eglibc.org/branches/$(UPSTREAM_SVN_BRANCH) +UPSTREAM_SVN_REV = $$(printf '%s\n' '$(OPK_SOURCE_VERSION_UPSTREAM)' | \ + sed 's/^[0-9][0-9]*\.[0-9][0-9]*~r\([0-9][0-9]*\).*$$/\1/') +SOURCE = eglibc-$(OPK_SOURCE_VERSION_UPSTREAM) +SOURCE_ARCHIVE = ../$(SOURCE).orig.tar.bz2 + +$(SOURCE): + svn export -r "$(UPSTREAM_SVN_REV)" "$(UPSTREAM_SVN_URI)" \ + 'eglibc-$(OPK_SOURCE_VERSION_UPSTREAM)' + rm -Rf '$(SOURCE)/libc/manual' + +$(SOURCE_ARCHIVE): $(SOURCE) + tar -cjf '$(SOURCE_ARCHIVE)' '$(SOURCE)' + rm -Rf '$(SOURCE)' + +source: $(SOURCE_ARCHIVE) -- cgit v0.9.1