Closed Bug 932637 Opened 12 years ago Closed 12 years ago

mach build-backend fails

Categories

(Firefox Build System :: General, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
mozilla28

People

(Reporter: bzbarsky, Assigned: gps)

Details

Attachments

(1 file)

After I got the "Build configuration changed" thing, I tried mach build-backend: ---------------------------------------------------------- $ ../mozilla/mach build-backend 0:01.08 c:\Users\bzbarsky\mozilla\vanilla\obj-firefox\config.status Error running mach: ['build-backend'] The error occurred in code that was called by the mach command. This is either a bug in the called code itself or in the way that mach is calling it. You should consider filing a bug for this issue. If filing a bug, please include the full output of mach, including this error message. The details of the failure are as follows: WindowsError: [Error 193] %1 is not a valid Win32 application File "c:/Users/bzbarsky/mozilla/vanilla/mozilla\python/mozbuild/mozbuild/mach_ commands.py", line 513, in build_backend pass_thru=True, ensure_exit_code=False) File "c:/Users/bzbarsky/mozilla/vanilla/mozilla\python/mozbuild\mozbuild\base. py", line 494, in _run_command_in_objdir return self.run_process(cwd=self.topobjdir, **args) File "c:/Users/bzbarsky/mozilla/vanilla/mozilla\python/mach\mach\mixin\process .py", line 121, in run_process status = subprocess.call(args, cwd=cwd, env=use_env) File "c:\mozilla-build\python\lib\subprocess.py", line 524, in call return Popen(*popenargs, **kwargs).wait() File "c:\mozilla-build\python\lib\subprocess.py", line 711, in __init__ errread, errwrite) File "c:\mozilla-build\python\lib\subprocess.py", line 948, in _execute_child startupinfo) ---------------------------------------------------------- Now what? :(
And note that mach build does work, but I was trying to avoid a full-tree rebuild, because I just wanted to quickly test something in one directory. Now I'm stuck with a multi-hour lag for something that would normally take 5 minutes. :(
> And note that mach build does work In the sense of running configure. It fails to actually like _build_ anything because it decides it thinks my C++ compiler can't create executables. Doing an actual pymake -f client.mk seems to work fine, though.
Try this (this is the easy workaround ; the right fix would be to call $python config.status): diff --git a/python/mozbuild/mozbuild/mach_commands.py b/python/mozbuild/mozbuild/mach_commands.py --- a/python/mozbuild/mozbuild/mach_commands.py +++ b/python/mozbuild/mozbuild/mach_commands.py @@ -505,17 +505,18 @@ class Build(MachCommandBase): @Command('build-backend', category='build', description='Generate a backend used to build the tree.') def build_backend(self): # When we support multiple build backends (Tup, Visual Studio, etc), # this command will be expanded to support choosing what to generate. config_status = os.path.join(self.topobjdir, 'config.status') return self._run_command_in_objdir(args=[config_status], - pass_thru=True, ensure_exit_code=False) + pass_thru=True, ensure_exit_code=False, + require_unix_environment=True) @CommandProvider class Warnings(MachCommandBase): """Provide commands for inspecting warnings.""" @property def database_path(self):
Or you can run config.status manually from the objdir.
(In reply to Boris Zbarsky [:bz] from comment #1) > And note that mach build does work, but I was trying to avoid a full-tree > rebuild, because I just wanted to quickly test something in one directory. > Now I'm stuck with a multi-hour lag for something that would normally take 5 > minutes. :( You can perform a partial tree build by running |mach build subdir| or |mach build .|
This should hopefully fix it. Long term, I'd like to provide a better API to config.status via mozbuild.*. Another day.
Attachment #824438 - Flags: review?(mh+mozilla)
Assignee: nobody → gps
bz: Please verify this fixes it for you. glandium: I'll likely be offline for ~12 hours. If you r+, feel free to land: I don't want people yelling too much.
Flags: needinfo?(bzbarsky)
Attachment #824438 - Flags: review?(mh+mozilla) → review+
Yes, that seems to fix the issue, thanks!
Flags: needinfo?(bzbarsky)
https://hg.mozilla.org/integration/mozilla-inbound/rev/84d1adc82b16 With permission from edmorley on a closed tree.
Flags: in-testsuite-
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla28
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: