Bug-Tizen: TC-1873/related
Change-Id: Iaf3adaf39dd83e22dc1a1fb609931b74aa7412b0
Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
--- /dev/null
+#! /bin/sh
+# @author: Philippe Coval <mailto:philippe.coval@eurogiciel.fr>
+# @description: manage git submodules with git-build-package-rpm
+
+set -x
+set -e
+
+cat .gitmodules || return 1
+
+
+git submodule status | awk '{ print $2 }' | while read dir ; do
+ name=$(basename "$dir" )
+ echo "name="
+ echo "dir=$dir"
+ git submodule init
+ git submodule update
+
+ tar cjvf "./packaging/${name}.tar.bz2" "${dir}"
+
+ cat<<EOF
+# Please add "SourceN: $name.tar.bz2" and "%setup -q -a N" to "packaging/*.spec"
+EOF
+
+done
+