summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README1
-rw-r--r--debian/changelog3
-rw-r--r--src/mozclient/lib/MozClient/VCS.pm10
3 files changed, 14 insertions, 0 deletions
diff --git a/README b/README
index 7b8f908..cd50382 100644
--- a/README
+++ b/README
@@ -38,6 +38,7 @@ Creates a source tarball from a VCS
A clean-up script, called "remove.binonly.sh", is called to remove all
binary-only files. It is applied to all projects before packing.
+Optionally, $(project)-remove.binonly.sh is also applied.
Traces of the cleaning are preserved inside that resulting tarball
in REMOVED+nobinonly.txt. If nothing has been removed, both the log and
the "+nobinonly" signature are dropped.
diff --git a/debian/changelog b/debian/changelog
index 7fe75d7..b08096d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -51,6 +51,9 @@ mozilla-devscripts (0.09) UNRELEASED; urgency=low
- update src/mozclient/lib/MozClient/VCS.pm
- update src/mozclient/mozclient.pl
- update README
+ + run an optional package specific clean-up script. It should be called
+ src/mozclient/${pkg_name}-remove.binonly.sh
+ - update src/mozclient/lib/MozClient/VCS.pm
* [ compare ]
+ Add build-tree/dist to the list of directories for compare1
diff --git a/src/mozclient/lib/MozClient/VCS.pm b/src/mozclient/lib/MozClient/VCS.pm
index bfb788b..9308c04 100644
--- a/src/mozclient/lib/MozClient/VCS.pm
+++ b/src/mozclient/lib/MozClient/VCS.pm
@@ -272,6 +272,16 @@ sub nobin_cleanup {
my $cmd = sprintf "sh %s > REMOVED+${nobinonly}.txt 2>&1",
$self->{'MOZCLIENT_EXCLUDE_SCRIPT'};
$self->run_shell($cmd);
+
+ # Run a package specific clean-up script, if any
+ my $pkg_script = $self->{'MOZCLIENT_EXCLUDE_SCRIPT'};
+ $pkg_script =~ m,/([^/]*)$,;
+ my $pkg = $self->{'MOZCLIENT_APPNAME'} . '-' . $1;
+ $pkg_script =~ s,(.*)/.*,$1/$pkg,;
+ $self->run_shell("sh $pkg_script >> REMOVED+${nobinonly}.txt 2>&1")
+ if -e $pkg_script;
+
+ # Remove the log if it's empty
$self->unlink("REMOVED+${nobinonly}.txt")
unless -s "REMOVED+${nobinonly}.txt";
$self->chdir("../..");