Bug 937984: Allow client.py to pull NSPR and NSS from a user-specified repo, r=kaie
authorBrian Smith <brian@briansmith.org>
Sun, 17 Nov 2013 13:48:30 -0800
changeset 155081 cb06029a7f433858176ef17c6493ff4182bb0678
parent 155080 53dffb3da44637c3aff3db9634f712f1f0985834
child 155082 35c1e12a077246bb7d4e59a219f3a83a992a6999
push id25662
push useremorley@mozilla.com
push dateMon, 18 Nov 2013 10:53:03 +0000
treeherdermozilla-central@59f6274ce8f1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskaie
bugs937984
milestone28.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 937984: Allow client.py to pull NSPR and NSS from a user-specified repo, r=kaie
client.py
--- a/client.py
+++ b/client.py
@@ -126,35 +126,41 @@ o.add_option("--skip-mozilla", dest="ski
              help="Obsolete")
 
 o.add_option("--cvs", dest="cvs", default=os.environ.get('CVS', 'cvs'),
              help="The location of the cvs binary")
 o.add_option("--cvsroot", dest="cvsroot",
              help="The CVSROOT for libffi (default : %s)" % CVSROOT_LIBFFI)
 o.add_option("--hg", dest="hg", default=os.environ.get('HG', 'hg'),
              help="The location of the hg binary")
+o.add_option("--repo", dest="repo",
+             help="the repo to update from (default: upstream repo)")
 
 try:
     options, args = o.parse_args()
     action = args[0]
 except IndexError:
     o.print_help()
     sys.exit(2)
 
 if action in ('checkout', 'co'):
     print >>sys.stderr, "Warning: client.py checkout is obsolete."
     pass
 elif action in ('update_nspr'):
     tag, = args[1:]
     depfile = "nsprpub/config/prdepend.h"
-    update_nspr_or_nss(tag, depfile, 'nsprpub', 'https://hg.mozilla.org/projects/nspr')
+    if not options.repo:
+        options.repo = 'https://hg.mozilla.org/projects/nspr'
+    update_nspr_or_nss(tag, depfile, 'nsprpub', options.repo)
 elif action in ('update_nss'):
     tag, = args[1:]
     depfile = "security/nss/coreconf/coreconf.dep"
-    update_nspr_or_nss(tag, depfile, 'security/nss', 'https://hg.mozilla.org/projects/nss')
+    if not options.repo:
+	    options.repo = 'https://hg.mozilla.org/projects/nss'
+    update_nspr_or_nss(tag, depfile, 'security/nss', options.repo)
 elif action in ('update_libffi'):
     tag, = args[1:]
     if not options.cvsroot:
         options.cvsroot = CVSROOT_LIBFFI
     do_cvs_export(LIBFFI_DIRS, tag, options.cvsroot, options.cvs)
 elif action in ('update_webidlparser'):
     tag, = args[1:]
     do_hg_replace(WEBIDLPARSER_DIR, WEBIDLPARSER_REPO, tag, WEBIDLPARSER_EXCLUSIONS, options.hg)