aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorVasilis Tsiligiannis <b_tsiligiannis@silverton.gr>2012-12-21 15:04:24 +0000
committerVasilis Tsiligiannis <b_tsiligiannis@silverton.gr>2012-12-21 15:04:24 +0000
commit9da818bb9b48d58eb9ca06500ad73ac3aa05e081 (patch)
tree974c18f372b0cae4ba91d8aea405b5a585b06efe /tools
parent290d51f3a99d10f77cd70fe58df67df73221803b (diff)
downloadupstream-9da818bb9b48d58eb9ca06500ad73ac3aa05e081.tar.gz
upstream-9da818bb9b48d58eb9ca06500ad73ac3aa05e081.tar.bz2
upstream-9da818bb9b48d58eb9ca06500ad73ac3aa05e081.zip
AA: backport: "[tools] ipkg-utils: Force gnu format for tar (#12496)"
[backport r34261] git-svn-id: svn://svn.openwrt.org/openwrt/branches/attitude_adjustment@34827 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'tools')
-rw-r--r--tools/ipkg-utils/patches/200-force_gnu_format.patch27
1 files changed, 27 insertions, 0 deletions
diff --git a/tools/ipkg-utils/patches/200-force_gnu_format.patch b/tools/ipkg-utils/patches/200-force_gnu_format.patch
new file mode 100644
index 0000000000..f363acbc0d
--- /dev/null
+++ b/tools/ipkg-utils/patches/200-force_gnu_format.patch
@@ -0,0 +1,27 @@
+--- a/ipkg-build
++++ b/ipkg-build
+@@ -250,13 +250,13 @@ mkdir $tmp_dir
+
+ echo $CONTROL > $tmp_dir/tarX
+ # Preserve permissions (-p) when creating data.tar.gz as non-root user
+-( cd $pkg_dir && $TAR $ogargs -X $tmp_dir/tarX -czpf $tmp_dir/data.tar.gz . )
++( cd $pkg_dir && $TAR $ogargs -X $tmp_dir/tarX --format=gnu -czpf $tmp_dir/data.tar.gz . )
+
+ installed_size=`stat -c "%s" $tmp_dir/data.tar.gz`
+ sed -i -e "s/^Installed-Size: .*/Installed-Size: $installed_size/" \
+ $pkg_dir/$CONTROL/control
+
+-( cd $pkg_dir/$CONTROL && $TAR $ogargs -czf $tmp_dir/control.tar.gz . )
++( cd $pkg_dir/$CONTROL && $TAR $ogargs --format=gnu -czf $tmp_dir/control.tar.gz . )
+ rm $tmp_dir/tarX
+
+ echo "2.0" > $tmp_dir/debian-binary
+@@ -266,7 +266,7 @@ rm -f $pkg_file
+ if [ "$outer" = "ar" ] ; then
+ ( cd $tmp_dir && ar -crf $pkg_file ./debian-binary ./data.tar.gz ./control.tar.gz )
+ else
+- ( cd $tmp_dir && $TAR -zcf $pkg_file ./debian-binary ./data.tar.gz ./control.tar.gz )
++ ( cd $tmp_dir && $TAR --format=gnu -zcf $pkg_file ./debian-binary ./data.tar.gz ./control.tar.gz )
+ fi
+
+ rm $tmp_dir/debian-binary $tmp_dir/data.tar.gz $tmp_dir/control.tar.gz