Bug 680636 - Execute nsinstall.py as Python module under PyMake; r=khuey
☠☠ backed out by 408b90991d17 ☠ ☠
authorGregory Szorc <gps@mozilla.com>
Mon, 22 Aug 2011 19:32:51 +0100
changeset 76709 e10579e136f1859c067da16eeb0b46f23bb775e6
parent 76708 bf17068db7de8833b2cff42886f505f683ce1ce1
child 76710 f2d73e22ea287d8c146afc1dde8f27aae711443c
push id340
push userclegnitto@mozilla.com
push dateTue, 08 Nov 2011 22:56:33 +0000
treeherdermozilla-beta@f745dc151615 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskhuey
bugs680636
milestone9.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 680636 - Execute nsinstall.py as Python module under PyMake; r=khuey
config/config.mk
config/nsinstall.py
js/src/config/config.mk
js/src/config/nsinstall.py
--- a/config/config.mk
+++ b/config/config.mk
@@ -667,26 +667,29 @@ GARBAGE		+= $(DEPENDENCIES) $(MKDEPENDEN
 
 ifeq ($(OS_ARCH),Darwin)
 ifndef NSDISTMODE
 NSDISTMODE=absolute_symlink
 endif
 PWD := $(CURDIR)
 endif
 
+ifdef .PYMAKE
+NSINSTALL = %nsinstall nsinstall
+else
 ifdef NSINSTALL_BIN
 NSINSTALL = $(NSINSTALL_BIN)
 else
 ifeq (OS2,$(CROSS_COMPILE)$(OS_ARCH))
 NSINSTALL = $(MOZ_TOOLS_DIR)/nsinstall
 else
 NSINSTALL = $(CONFIG_TOOLS)/nsinstall$(HOST_BIN_SUFFIX)
 endif # OS2
 endif # NSINSTALL_BIN
-
+endif # .PYMAKE
 
 ifeq (,$(CROSS_COMPILE)$(filter-out WINNT OS2, $(OS_ARCH)))
 INSTALL		= $(NSINSTALL)
 else
 
 # This isn't laid out as conditional directives so that NSDISTMODE can be
 # target-specific.
 INSTALL         = $(if $(filter copy, $(NSDISTMODE)), $(NSINSTALL) -t, $(if $(filter absolute_symlink, $(NSDISTMODE)), $(NSINSTALL) -L $(PWD), $(NSINSTALL) -R))
--- a/config/nsinstall.py
+++ b/config/nsinstall.py
@@ -96,17 +96,17 @@ def nsinstall(argv):
     if len(args) != 1:
       return 1
     if os.path.exists(args[0]):
       if not os.path.isdir(args[0]):
         sys.stderr.write('nsinstall: ' + args[0] + ' is not a directory\n')
         sys.exit(1)
       if options.m:
         os.chmod(args[0], options.m)
-      sys.exit()
+      return 0
     if options.m:
       os.makedirs(args[0], options.m)
     else:
       os.makedirs(args[0])
     return 0
 
   # nsinstall arg1 [...] directory
   if len(args) < 2:
--- a/js/src/config/config.mk
+++ b/js/src/config/config.mk
@@ -667,26 +667,29 @@ GARBAGE		+= $(DEPENDENCIES) $(MKDEPENDEN
 
 ifeq ($(OS_ARCH),Darwin)
 ifndef NSDISTMODE
 NSDISTMODE=absolute_symlink
 endif
 PWD := $(CURDIR)
 endif
 
+ifdef .PYMAKE
+NSINSTALL = %nsinstall nsinstall
+else
 ifdef NSINSTALL_BIN
 NSINSTALL = $(NSINSTALL_BIN)
 else
 ifeq (OS2,$(CROSS_COMPILE)$(OS_ARCH))
 NSINSTALL = $(MOZ_TOOLS_DIR)/nsinstall
 else
 NSINSTALL = $(CONFIG_TOOLS)/nsinstall$(HOST_BIN_SUFFIX)
 endif # OS2
 endif # NSINSTALL_BIN
-
+endif # .PYMAKE
 
 ifeq (,$(CROSS_COMPILE)$(filter-out WINNT OS2, $(OS_ARCH)))
 INSTALL		= $(NSINSTALL)
 else
 
 # This isn't laid out as conditional directives so that NSDISTMODE can be
 # target-specific.
 INSTALL         = $(if $(filter copy, $(NSDISTMODE)), $(NSINSTALL) -t, $(if $(filter absolute_symlink, $(NSDISTMODE)), $(NSINSTALL) -L $(PWD), $(NSINSTALL) -R))
--- a/js/src/config/nsinstall.py
+++ b/js/src/config/nsinstall.py
@@ -96,17 +96,17 @@ def nsinstall(argv):
     if len(args) != 1:
       return 1
     if os.path.exists(args[0]):
       if not os.path.isdir(args[0]):
         sys.stderr.write('nsinstall: ' + args[0] + ' is not a directory\n')
         sys.exit(1)
       if options.m:
         os.chmod(args[0], options.m)
-      sys.exit()
+      return 0
     if options.m:
       os.makedirs(args[0], options.m)
     else:
       os.makedirs(args[0])
     return 0
 
   # nsinstall arg1 [...] directory
   if len(args) < 2: