mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-19 15:04:50 +02:00
10
setup.py
10
setup.py
@@ -145,6 +145,7 @@ class Options:
|
|||||||
prefix: str = './linux-package'
|
prefix: str = './linux-package'
|
||||||
dir_for_static_binaries: str = 'build/static'
|
dir_for_static_binaries: str = 'build/static'
|
||||||
skip_code_generation: bool = False
|
skip_code_generation: bool = False
|
||||||
|
skip_building_kitten: bool = False
|
||||||
clean_for_cross_compile: bool = False
|
clean_for_cross_compile: bool = False
|
||||||
python_compiler_flags: str = ''
|
python_compiler_flags: str = ''
|
||||||
python_linker_flags: str = ''
|
python_linker_flags: str = ''
|
||||||
@@ -959,6 +960,9 @@ def build_static_kittens(
|
|||||||
args: Options, launcher_dir: str, destination_dir: str = '', for_freeze: bool = False,
|
args: Options, launcher_dir: str, destination_dir: str = '', for_freeze: bool = False,
|
||||||
for_platform: Optional[Tuple[str, str]] = None
|
for_platform: Optional[Tuple[str, str]] = None
|
||||||
) -> str:
|
) -> str:
|
||||||
|
if args.skip_building_kitten:
|
||||||
|
print('Skipping building of the kitten binary because of a command line option. Build is incomplete', file=sys.stderr)
|
||||||
|
return
|
||||||
sys.stdout.flush()
|
sys.stdout.flush()
|
||||||
sys.stderr.flush()
|
sys.stderr.flush()
|
||||||
go = shutil.which('go')
|
go = shutil.which('go')
|
||||||
@@ -1653,6 +1657,12 @@ def option_parser() -> argparse.ArgumentParser: # {{{
|
|||||||
help='Do not create the *_generated.* source files. This is useful if they'
|
help='Do not create the *_generated.* source files. This is useful if they'
|
||||||
' have already been generated by a previous build, for example during a two-stage cross compilation.'
|
' have already been generated by a previous build, for example during a two-stage cross compilation.'
|
||||||
)
|
)
|
||||||
|
p.add_argument(
|
||||||
|
'--skip-building-kitten',
|
||||||
|
default=Options.skip_building_kitten,
|
||||||
|
action='store_true',
|
||||||
|
help='Do not build the kitten binary. Useful if you want to build it separately.'
|
||||||
|
)
|
||||||
p.add_argument(
|
p.add_argument(
|
||||||
'--clean-for-cross-compile',
|
'--clean-for-cross-compile',
|
||||||
default=Options.clean_for_cross_compile,
|
default=Options.clean_for_cross_compile,
|
||||||
|
|||||||
Reference in New Issue
Block a user