summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFabien Tassin <fta@sofaraway.org>2008-06-04 22:54:03 +0200
committerFabien Tassin <fta@sofaraway.org>2008-06-04 22:54:03 +0200
commit02042dbeca22afb1573dbe5a471ce8a66084edee (patch)
treead61eb870d22eaac181aeffd014975478f898ed1 /src
parentaf5cd7aa2fc97acf626c6bfcab4aa33b5d1ab440 (diff)
* [mozclient] add support for --conf-dir and remove the template
- rename src/mozclient.pl.in => src/mozclient.pl - update src/mozclient.pl - update src/Makefile
Diffstat (limited to 'src')
-rw-r--r--src/Makefile7
-rwxr-xr-xsrc/mozclient.pl (renamed from src/mozclient.pl.in)6
2 files changed, 3 insertions, 10 deletions
diff --git a/src/Makefile b/src/Makefile
index 52c47a6..0334ad8 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -36,7 +36,6 @@ subst_files = \
xulrunner-1.9.1.mk \
xulrunner-2.0.mk \
mozclient.mk \
- mozclient.pl \
compare.mk \
minefield-packager.mk \
$(NULL)
@@ -53,12 +52,6 @@ extra_dirs = \
minefield-packager/debian \
$(NULL)
-%.pl: %.pl.in
- cat $< | sed \
- -e "s|^\(my \$$mozclient_dir[[:space:]]*= '\)@DATADIR@\(';.*\)|\1$(DATADIR)/\2|" \
- > $@
- chmod 755 $@
-
%.mk: %.mk.in
cat $< | sed \
-e "s|^\(include\) \(.*\)\.in|\1 $(DATADIR)/\2|" \
diff --git a/src/mozclient.pl.in b/src/mozclient.pl
index 78e242a..ded3a46 100755
--- a/src/mozclient.pl.in
+++ b/src/mozclient.pl
@@ -28,9 +28,7 @@ package MozClient;
use Carp;
use strict;
-my $mozclient_dir = '@DATADIR@'; # Needs to be substituted
-
-chomp($mozclient_dir = `pwd`) if $mozclient_dir eq '@DATADIR@';
+my $mozclient_dir = "/usr/share/mozilla-devscripts";
my $pkg_conf_dir = "$mozclient_dir/mozclient";
my $patches_dir = "$pkg_conf_dir/patches";
my $work_dir = "mozclient-tmp";
@@ -559,6 +557,7 @@ sub help {
print <<EOF;
mozclient [-b branch] [-t tag] [-d YYYYMMDDtHHmm] project-name
mozclient [-l] project-name
+ --conf-dir|-c dir use dir as config directory (default: $mozclient_dir)
--list-tags|-l list VCS tags
--branch|-b branch checkout from a specific branch
--date|-d date checkout by date (YYYYMMDDtHHmm)
@@ -661,6 +660,7 @@ sub read_project_file {
# Main
my $opt = {};
GetOptions($opt,
+ 'conf-dir|c=s',
'debug|D+',
'list-tags|l',
'branch|b=s',