[packages/depot_tools] up to fresh snapshot (20131210, git aeab41a)
glen
glen at pld-linux.org
Wed Dec 11 21:27:59 CET 2013
commit e9bf62fa143ad94e9330403c53895f436a8b5489
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Wed Dec 11 22:17:33 2013 +0200
up to fresh snapshot (20131210, git aeab41a)
old one did not recognize --platform argument to download_from_google_storage tool
depot_tools.spec | 26 ++++++++++++++------------
get-source.sh | 35 +++++++++++++++++++++++++++++++++++
2 files changed, 49 insertions(+), 12 deletions(-)
---
diff --git a/depot_tools.spec b/depot_tools.spec
index 823c76c..b28ea74 100644
--- a/depot_tools.spec
+++ b/depot_tools.spec
@@ -1,16 +1,17 @@
-%define snap 20130619
-%define rel 0.10
+%define subver 20131210
+%define rel 0.11
Summary: A package of scripts called used to manage checkouts and code reviews
Name: depot_tools
Version: 0.1
-Release: 0.%{snap}.%{rel}
+Release: 0.%{subver}.%{rel}
License: BSD
Group: Development/Tools
-Source0: https://src.chromium.org/svn/trunk/tools/depot_tools.zip?/%{name}-svn%{snap}.zip
-# Source0-md5: 6cf6483d6da8d15848cbaa8857aae3ae
-Patch0: adjust-path.patch
+Source0: %{name}-%{subver}-aeab41a.tar.xz
+# Source0-md5: 5dd469c8ec03d03d48b7db886475bbfa
+Patch0: adjust-path.patch
URL: http://dev.chromium.org/developers/how-tos/depottools
-BuildRequires: unzip
+BuildRequires: tar >= 1:1.22
+BuildRequires: xz
Requires: python
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -43,9 +44,7 @@ development process. It contains the following utilities:
- zsh-goodies: Completion for zsh users.
%prep
-%setup -qc
-mv depot_tools/* .
-rm -r depot_tools
+%setup -qn %{name}-%{subver}
%patch0 -p1
cat > py-wrap.sh <<'EOF'
@@ -67,8 +66,10 @@ rm create-ntfs-junction.c
rm -r testing_support
rm -r tests
-# other junk
+# other irrelevant junk
rm -r bootstrap
+rm .gitignore
+rm OWNERS WATCHLISTS
%install
rm -rf $RPM_BUILD_ROOT
@@ -76,7 +77,6 @@ install -d $RPM_BUILD_ROOT{%{_datadir}/%{name},%{_bindir}}
cp -a . $RPM_BUILD_ROOT%{_datadir}/%{name}
# already in %doc
rm $RPM_BUILD_ROOT%{_datadir}/%{name}/{LICENSE,README*}
-rm $RPM_BUILD_ROOT%{_datadir}/%{name}/{OWNERS,WATCHLISTS}
for a in gclient gcl git-cl fetch; do
ln -s %{_datadir}/%{name}/py-wrap.sh $RPM_BUILD_ROOT%{_bindir}/$a
@@ -112,8 +112,10 @@ rm -rf $RPM_BUILD_ROOT
%attr(755,root,root) %{_datadir}/%{name}/git-crup
%attr(755,root,root) %{_datadir}/%{name}/git-gs
%attr(755,root,root) %{_datadir}/%{name}/git-lkgr
+%attr(755,root,root) %{_datadir}/%{name}/git-number
%attr(755,root,root) %{_datadir}/%{name}/git-runhooks
%attr(755,root,root) %{_datadir}/%{name}/git-try
+%attr(755,root,root) %{_datadir}/%{name}/gn
%attr(755,root,root) %{_datadir}/%{name}/hammer
%attr(755,root,root) %{_datadir}/%{name}/py-wrap.sh
%attr(755,root,root) %{_datadir}/%{name}/pylint
diff --git a/get-source.sh b/get-source.sh
new file mode 100755
index 0000000..11bd2c7
--- /dev/null
+++ b/get-source.sh
@@ -0,0 +1,35 @@
+#!/bin/sh
+# Make snapshot of depot_tools
+# Author: Elan Ruusamäe <glen at pld-linux.org>
+set -e
+
+repo_url=https://chromium.googlesource.com/chromium/tools/depot_tools.git
+package=depot_tools
+specfile=$package.spec
+
+export GIT_DIR=$package.git
+
+if [ ! -d $GIT_DIR ]; then
+ install -d $GIT_DIR
+ git init --bare
+ git remote add origin $repo_url
+ git fetch --depth 1 origin refs/heads/master:refs/remotes/origin/master
+else
+ git fetch origin refs/heads/master:refs/remotes/origin/master
+fi
+
+git update-ref HEAD refs/remotes/origin/master
+
+githash=$(git rev-parse --short HEAD)
+gitdate=$(git log -1 --date=short --pretty='format:%cd' HEAD | tr -d -)
+prefix=$package-$gitdate
+archive=$prefix-$githash.tar.xz
+
+if [ -f $archive ]; then
+ echo "Tarball $archive already exists at $githash"
+ exit 0
+fi
+
+git -c tar.tar.xz.command="xz -9c" archive $githash --prefix $prefix/ -o $archive
+
+../dropin $archive
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/depot_tools.git/commitdiff/e9bf62fa143ad94e9330403c53895f436a8b5489
More information about the pld-cvs-commit
mailing list