summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Pashev <pashev.igor@gmail.com>2015-10-09 21:16:36 +0300
committerIgor Pashev <pashev.igor@gmail.com>2015-10-09 21:16:36 +0300
commit488a041f665c74a60de82997c4880f19a100c5c0 (patch)
tree4d469d7d7675a938581b966a9d9efd5723ac4983
parent0ebc4a72ff4cf8ce8510c697360da7053161350b (diff)
downloaddh-illumos-488a041f665c74a60de82997c4880f19a100c5c0.tar.gz
dh_illumos_gate --create-orig is really smart
-rwxr-xr-xdh_illumos_gate15
1 files changed, 8 insertions, 7 deletions
diff --git a/dh_illumos_gate b/dh_illumos_gate
index d336861..5e81879 100755
--- a/dh_illumos_gate
+++ b/dh_illumos_gate
@@ -62,7 +62,8 @@ make any changes in there instead of the current directory.
=item B<--create-orig>
-Create I<.orig> tarball.
+Create I<.orig> tarball out of the listed files and directories.
+Note that part of path before F<usr/src> will be stripped.
=back
@@ -92,9 +93,9 @@ then add F<usr/src/uts/common/sys/>
dh_illumos_gate -- --wildcards-match-slash usr/src/uts/*.h
-=item Create source tarball out of F<usr/src/cmd> excluding F<*.mf> files
+=item Create source tarball out of F<usr/src/cmd> excluding F<*.xml> files
- dh_illumos_gate --create-orig usr/src/cmd -X*.mf
+ dh_illumos_gate --create-orig [path/to/]usr/src/cmd -X*.xml
=back
@@ -149,11 +150,11 @@ if ( $dh{CREATE_ORIG} ) {
my $source = $changelog->{'Source'};
my $source_version = $version =~ s!^(.*)-[^-]+$!$1!r;
my $tarball = "$cwd/../${source}_${source_version}.orig.tar.xz";
- my $base = "$source-$source_version";
+ my $transform = "s,.*usr/src,$source-$source_version/usr/src,";
doit(
- 'tar', '-c', '-J', '--owner',
- '0', '--group', '0', '--mode',
- 'u=rwX,go=rX', '--transform', "s,^,$base/,", '-f',
+ 'tar', '-c', '-J', '--owner',
+ '0', '--group', '0', '--mode',
+ 'u=rwX,go=rX', '--transform', $transform, '-f',
$tarball, @tar_X, @ARGV
);
exit;