File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -9,3 +9,5 @@ if [ $retval -ne 0 ]; then
99 echo " ninja FAILED with error code $retval "
1010 exit $retval
1111fi
12+ open -W --stdout $( tty) --stderr $( tty) " ./Debug/PHP Desktop.app"
13+ # ./Debug/PHP\ Desktop.app/Contents/MacOS/PHP\ Desktop
Original file line number Diff line number Diff line change 1212
1313#include " include/base/cef_logging.h"
1414#include " include/wrapper/cef_helpers.h"
15+ #import " include/wrapper/cef_library_loader.h"
1516
1617#include < cstdlib>
1718#include < iostream>
@@ -56,6 +57,13 @@ void create_browser()
5657}
5758
5859int main (int argc, char **argv) {
60+ // Load the CEF framework library at runtime instead of linking directly
61+ // as required by the macOS sandbox implementation.
62+ CefScopedLibraryLoader library_loader;
63+ if (!library_loader.LoadInMain ()) {
64+ return 1 ;
65+ }
66+
5967 // Passing ENV variables to PHP using the --cgi-environment
6068 // command line arg passed to app.
6169 if (argv) {
@@ -72,11 +80,6 @@ int main(int argc, char **argv) {
7280 }
7381 }
7482
75- // Create a copy of |argv| on Linux because Chromium mangles the value
76- // internally (see CEF issue #620).
77- CefScopedArgArray scoped_arg_array (argc, argv);
78- char ** argv_copy = scoped_arg_array.array ();
79-
8083 // Provide CEF with command-line arguments.
8184 CefMainArgs main_args (argc, argv);
8285 CefRefPtr<CefCommandLine> cmdline = CefCommandLine::CreateCommandLine ();
You can’t perform that action at this time.
0 commit comments