cs gracket: fix handling of X11 flags and -singleInstance

X11 flags and -singlreInstance were being filtered from the command
line but not propagated to the `racket/gui`.
This commit is contained in:
Matthew Flatt 2020-08-05 18:01:21 -06:00
parent adabeeb249
commit 6317669f51
3 changed files with 3 additions and 4 deletions

View File

@ -26,7 +26,7 @@ char *check_for_another = "yes, please check for another";
#if defined(WIN32)
static void pre_filter_cmdline_arguments(int *argc, char ***argv) { }
#elif defined(OS_X)
#elif defined(OS_X) && !defined(RACKET_XONX)
# define wx_mac
#else
# define wx_xt

View File

@ -443,8 +443,6 @@ static int bytes_main(int argc, char **argv,
racket_boot_t racket_boot_p;
long boot_rsrc_offset = 0;
#endif
do_pre_filter_cmdline_arguments(&argc, &argv);
if (argc) {
argc--;
@ -600,6 +598,7 @@ static int x11_arg_count = 0;
static char *x11_args = "0";
int main(int argc, char **argv) {
do_pre_filter_cmdline_arguments(&argc, &argv);
return bytes_main(argc, argv, x11_arg_count, x11_args);
}
#endif

View File

@ -127,7 +127,7 @@
(unsafe-register-process-global (string->bytes/utf-8 "PLT_X11_ARGUMENT_COUNT")
(ptr-add #f wm-is-gracket-or-x11-arg-count))
(unsafe-register-process-global (string->bytes/utf-8 "PLT_X11_ARGUMENTS")
(ptr-add #f (#%string->number gracket-guid-or-x11-args 16))))))
(ptr-add #f (#%string->number (substring gracket-guid-or-x11-args 2) 16))))))
(define compiled-file-paths
(list (cond