Closed
Bug 1494326
Opened 6 years ago
Closed 6 years ago
Provide a mach run option to launch the browser using the macOS open(1) command
Categories
(Firefox Build System :: Mach Core, enhancement)
Tracking
(firefox64 fixed)
RESOLVED
FIXED
mozilla64
Tracking | Status | |
---|---|---|
firefox64 | --- | fixed |
People
(Reporter: haik, Assigned: haik)
References
Details
Attachments
(1 file)
macOS includes the open(1) command which can be used to launch an application from the command line as if it was launched via the Finder. i.e., the application is spawned directly by the launchd process instead of via the shell parent process chain. One use I've found for this relates to the new macOS 10.14 Mojave device permission dialogs for the camera/mic. When launched via "mach run", the dialog is displayed as '"Terminal" would like to access the camera." (I consider that a macOS limitation and not a Firefox bug.) When launching with the open command, the dialog is displayed correctly. I don't know of other uses at this time and understand if this is considered too low value to be worth integrating. Launching with the open command can be done manually with the following command depending on $OBJ_DIR and $REPO_DIR. $ open ${OBJ_DIR}/dist/Nightly.app --args -no-remote -foreground -profile ${REPO_DIR}/obj-opt.noindex/tmp/profile-default
Assignee | ||
Comment 1•6 years ago
|
||
Comment 2•6 years ago
|
||
Would it be harmful to make this the default behavior for `mach run` on macOS when you're not using `--debug` or anything like that? Does the change in parent process make it hard to wait for the browser to exit and handle its stdout?
Comment 3•6 years ago
|
||
While only tangentially build related, I don't have strong opinions on this so I'm punting this over to the build review queue. I do echo ted's sentiment though. It doesn't seem something worth creating a command line flag for (why not just do the best thing for the given scenario?) There's also the ~/.mozbuild/machrc config file which can be used to set this either instead of or in addition to the cli.
Assignee | ||
Comment 4•6 years ago
|
||
(In reply to Ted Mielczarek [:ted] [:ted.mielczarek] from comment #2) > Would it be harmful to make this the default behavior for `mach run` on > macOS when you're not using `--debug` or anything like that? Does the change > in parent process make it hard to wait for the browser to exit and handle > its stdout? Yes, it does it make it more difficult to handle the browser's stdout. stdout/stderr is not sent to the terminal when opened with the open command. I would prefer it not be the default because I think having stdout/stderr is useful for debugging and most of the time want to see that.
Comment 5•6 years ago
|
||
Comment on attachment 9012182 [details] Bug 1494326 - Provide a mach run option to launch the browser using the macOS open(1) command r=nfroyd Nathan Froyd [:froydnj] has approved the revision.
Attachment #9012182 -
Flags: review+
Assignee | ||
Updated•6 years ago
|
Assignee: nobody → haftandilian
Updated•6 years ago
|
Attachment #9012182 -
Attachment description: Bug 1494326 - Provide a mach run option to launch the browser using the macOS open(1) command r?ahal → Bug 1494326 - Provide a mach run option to launch the browser using the macOS open(1) command r=nfroyd
Pushed by haftandilian@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/6617886468a2 Provide a mach run option to launch the browser using the macOS open(1) command r=froydnj
Comment 7•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/6617886468a2
Status: NEW → RESOLVED
Closed: 6 years ago
status-firefox64:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
You need to log in
before you can comment on or make changes to this bug.
Description
•