mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-05-13 16:37:27 +00:00
Move parsing of macos-launch-services-cmdline into native code
Avoids expensive re-exec and simplifies various things. Much faster for single instance usage.
This commit is contained in:
parent
639ad3e8a6
commit
7bd7709685
10 changed files with 186 additions and 107 deletions
2
setup.py
2
setup.py
|
|
@ -1345,7 +1345,7 @@ def build_launcher(args: Options, launcher_dir: str = '.', bundle_type: str = 's
|
|||
objects = []
|
||||
cppflags.append('-DKITTY_CLI_BOOL_OPTIONS=" ' + ' '.join(kitty_cli_boolean_options()) + ' "')
|
||||
cppflags.append('-DKITTY_VERSION="' + '.'.join(map(str, version)) + '"')
|
||||
for src in ('kitty/launcher/main.c', 'kitty/launcher/single-instance.c'):
|
||||
for src in ('kitty/launcher/main.c', 'kitty/launcher/single-instance.c', 'kitty/launcher/cmdline.c'):
|
||||
obj = os.path.join(build_dir, src.replace('/', '-').replace('.c', '.o'))
|
||||
objects.append(obj)
|
||||
cmd = env.cc + cppflags + cflags + ['-c', src, '-o', obj]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue